summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCástor Muñoz <cmvidal@gmail.com>2016-05-15 03:11:17 +0200
committerCástor Muñoz <cmvidal@gmail.com>2016-05-15 23:43:00 +0200
commitb8a237dca21227e591a0b3c6204f4b2503075ae8 (patch)
treea8d01acbb43cf7ecc0a31588dc0aa588fc902232
parent52a6db3a363e915b1af7eb37778baaee81306c48 (diff)
downloadrockbox-b8a237dca21227e591a0b3c6204f4b2503075ae8.tar.gz
rockbox-b8a237dca21227e591a0b3c6204f4b2503075ae8.tar.bz2
rockbox-b8a237dca21227e591a0b3c6204f4b2503075ae8.zip
iPod Classic: wait for ATA power down on device shutdown
Change-Id: I5d3d19d6d0c937e11e28b99f34d729631051ab93
-rw-r--r--firmware/target/arm/s5l8702/ipod6g/storage_ata-ipod6g.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/firmware/target/arm/s5l8702/ipod6g/storage_ata-ipod6g.c b/firmware/target/arm/s5l8702/ipod6g/storage_ata-ipod6g.c
index 5b0ab3e22a..3458e1918c 100644
--- a/firmware/target/arm/s5l8702/ipod6g/storage_ata-ipod6g.c
+++ b/firmware/target/arm/s5l8702/ipod6g/storage_ata-ipod6g.c
@@ -692,7 +692,6 @@ static int ata_power_up(void)
static void ata_power_down(void)
{
if (!ata_powered) return;
- ata_powered = false;
if (ceata)
{
memset(ceata_taskfile, 0, 16);
@@ -720,6 +719,7 @@ static void ata_power_down(void)
PCON(10) &= ~0xffff;
PCON(11) &= ~0xf;
ide_power_enable(false);
+ ata_powered = false;
}
static int ata_rw_chunk_internal(uint64_t sector, uint32_t cnt, void* buffer, bool write)