spi: Avoid checking console in SPL
When SPI flash is used in SPL there is no console, so ctrlc() cannot be called. Add a condition to fix this. Signed-off-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
parent
a50b561333
commit
564e532eea
@ -929,7 +929,7 @@ static int spi_nor_erase(struct mtd_info *mtd, struct erase_info *instr)
|
||||
|
||||
while (len) {
|
||||
WATCHDOG_RESET();
|
||||
if (ctrlc()) {
|
||||
if (!IS_ENABLED(CONFIG_SPL_BUILD) && ctrlc()) {
|
||||
addr_known = false;
|
||||
ret = -EINTR;
|
||||
goto erase_err;
|
||||
|
Loading…
Reference in New Issue
Block a user