9
0
Fork 0

ARM: am33xx update SPI NOR: Ask use before flashing

Let the user confirm the update process before flashing the new
image.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
This commit is contained in:
Sascha Hauer 2014-09-30 11:00:58 +02:00
parent 130d511909
commit 77b8c95e8b
1 changed files with 4 additions and 0 deletions

View File

@ -59,6 +59,10 @@ static int spi_nor_mlo_handler(struct bbu_handler *handler,
return -ENOSPC;
}
ret = bbu_confirm(data);
if (ret != 0)
return ret;
dstfd = open(data->devicefile, O_WRONLY);
if (dstfd < 0) {
printf("could not open %s: %s", data->devicefile, errno_str());