summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--firmware/drivers/ata.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/firmware/drivers/ata.c b/firmware/drivers/ata.c
index f49040a..0fbc418 100644
--- a/firmware/drivers/ata.c
+++ b/firmware/drivers/ata.c
@@ -222,8 +222,10 @@ int ata_read_sectors(unsigned long start,
goto retry;
}
- if ( ATA_ALT_STATUS & (STATUS_ERR | STATUS_DF) )
+ if ( ATA_ALT_STATUS & (STATUS_ERR | STATUS_DF) ) {
+ ret = -5;
goto retry;
+ }
/* if destination address is odd, use byte copying,
otherwise use word copying */