From 0d941425b95d0b5fd55862a6f1f0c4fd1222db28 Mon Sep 17 00:00:00 2001 From: Jonathan Gordon Date: Thu, 9 Nov 2006 12:36:50 +0000 Subject: call call_ata_idle_notifys on clean shutdown, this should work, but threads with possible callbacks should deal with shutdown/usb themselves. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@11480 a1c6a512-1295-4272-9138-f99709370657 --- apps/misc.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'apps/misc.c') diff --git a/apps/misc.c b/apps/misc.c index 01463851be..7e4e5071a1 100644 --- a/apps/misc.c +++ b/apps/misc.c @@ -36,6 +36,7 @@ #include "mp3_playback.h" #include "settings.h" #include "ata.h" +#include "ata_idle_notify.h" #include "kernel.h" #include "power.h" #include "powermgmt.h" @@ -554,6 +555,7 @@ bool settings_parseline(char* line, char** name, char** value) static void system_flush(void) { + call_ata_idle_notifys(false); /*doesnt work on usb and shutdown from ata thread */ tree_flush(); } @@ -567,6 +569,7 @@ static bool clean_shutdown(void (*callback)(void *), void *parameter) #ifdef SIMULATOR (void)callback; (void)parameter; + call_ata_idle_notifys(false); exit(0); #else int i; -- cgit v1.2.3