Skip to content

Commit 68b5f67

Browse files
committed
Fix for hal_flash_write to use incremented data pointer for page.
1 parent 0a0e8f6 commit 68b5f67

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

hal/hifive1.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -452,6 +452,7 @@ int RAMFUNCTION hal_flash_write(uint32_t address, const uint8_t *data, int len)
452452
fespi_sw_setdir(FESPI_DIR_RX);
453453
fespi_wait_txwm();
454454
page++;
455+
data += FLASH_PAGE_SIZE;
455456
off = 0;
456457
}
457458
fespi_wait_flash_writing();

0 commit comments

Comments
 (0)