diff options
author | Jonathan Gordon <rockbox@jdgordon.info> | 2008-03-17 05:22:53 +0000 |
---|---|---|
committer | Jonathan Gordon <rockbox@jdgordon.info> | 2008-03-17 05:22:53 +0000 |
commit | a67e5d89efe6c3fcf5a2eaf27aac1c14f024ee27 (patch) | |
tree | 2e62c72ea2e45410216bdbd62b70101db0f4e7ca /firmware/ata_idle_notify.c | |
parent | c6b6bad18fcd68182574086c2eb2a1da30d36d25 (diff) | |
download | rockbox-a67e5d89efe6c3fcf5a2eaf27aac1c14f024ee27.tar.gz rockbox-a67e5d89efe6c3fcf5a2eaf27aac1c14f024ee27.zip |
It makes more sense for the callback registrar to decide if its a "oneshot" then the callback caller.
(Doing it this way means playback could(/should?) registar a disk spinup callback at init which is called every spinup without needing to be reregistered)
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16685 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/ata_idle_notify.c')
-rw-r--r-- | firmware/ata_idle_notify.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/firmware/ata_idle_notify.c b/firmware/ata_idle_notify.c index a97c3538da..ab2233da1f 100644 --- a/firmware/ata_idle_notify.c +++ b/firmware/ata_idle_notify.c | |||
@@ -26,7 +26,7 @@ | |||
26 | void register_ata_idle_func(ata_idle_notify function) | 26 | void register_ata_idle_func(ata_idle_notify function) |
27 | { | 27 | { |
28 | #if USING_ATA_CALLBACK | 28 | #if USING_ATA_CALLBACK |
29 | add_event(DISK_EVENT_SPINUP, function); | 29 | add_event(DISK_EVENT_SPINUP, true, function); |
30 | #else | 30 | #else |
31 | function(); /* just call the function now */ | 31 | function(); /* just call the function now */ |
32 | /* this _may_ cause problems later if the calling function | 32 | /* this _may_ cause problems later if the calling function |
@@ -55,7 +55,7 @@ bool call_ata_idle_notifys(bool force) | |||
55 | } | 55 | } |
56 | lock_until = current_tick + 30*HZ; | 56 | lock_until = current_tick + 30*HZ; |
57 | 57 | ||
58 | send_event(DISK_EVENT_SPINUP, true, NULL); | 58 | send_event(DISK_EVENT_SPINUP, NULL); |
59 | 59 | ||
60 | return true; | 60 | return true; |
61 | } | 61 | } |