summaryrefslogtreecommitdiffstats
path: root/spi.c
diff options
context:
space:
mode:
Diffstat (limited to 'spi.c')
-rw-r--r--spi.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/spi.c b/spi.c
index 7a17b24..86ffe69 100644
--- a/spi.c
+++ b/spi.c
@@ -972,7 +972,7 @@ int spi_chip_write_1(struct flashchip *flash, uint8_t *buf)
spi_disable_blockprotect();
/* Erase first */
printf("Erasing flash before programming... ");
- if (flash->erase(flash)) {
+ if (erase_flash(flash)) {
fprintf(stderr, "ERASE FAILED!\n");
return -1;
}
@@ -1021,7 +1021,7 @@ int spi_aai_write(struct flashchip *flash, uint8_t *buf)
default:
break;
}
- if (flash->erase(flash)) {
+ if (erase_flash(flash)) {
fprintf(stderr, "ERASE FAILED!\n");
return -1;
}
OpenPOWER on IntegriCloud