summaryrefslogtreecommitdiffstats
path: root/firmware
diff options
context:
space:
mode:
authorBjörn Stenberg <bjorn@haxx.se>2003-03-24 16:19:54 +0000
committerBjörn Stenberg <bjorn@haxx.se>2003-03-24 16:19:54 +0000
commitaa78324fde4a7d8df64506322aaaaa20c7d43efc (patch)
treed1c8b47a7291ac40f734ade73cd9c316526eb7b8 /firmware
parente1426d4cb8a829010b98be2bd4f6c96e9ef706db (diff)
downloadrockbox-aa78324fde4a7d8df64506322aaaaa20c7d43efc.tar.gz
rockbox-aa78324fde4a7d8df64506322aaaaa20c7d43efc.zip
Another attempt to stop the red led dead.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@3498 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware')
-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 8c0292d474..935b91271e 100644
--- a/firmware/drivers/ata.c
+++ b/firmware/drivers/ata.c
@@ -226,6 +226,8 @@ int ata_read_sectors(unsigned long start,
if (!wait_for_start_of_transfer()) {
ret = -4;
+ if(ata_hard_reset())
+ break;
goto retry;
}
@@ -279,7 +281,7 @@ int ata_read_sectors(unsigned long start,
last_disk_activity = current_tick;
}
- if(!wait_for_end_of_transfer()) {
+ if(!ret && !wait_for_end_of_transfer()) {
ret = -3;
goto retry;
}