diff options
Diffstat (limited to 'apps')
| -rw-r--r-- | apps/playback.c | 1 | ||||
| -rw-r--r-- | apps/settings.c | 8 |
2 files changed, 8 insertions, 1 deletions
diff --git a/apps/playback.c b/apps/playback.c index f4274a8..c0558ed 100644 --- a/apps/playback.c +++ b/apps/playback.c @@ -2781,6 +2781,7 @@ static void audio_fill_file_buffer( filling = false; } + ata_sleep(); } static void audio_rebuffer(void) diff --git a/apps/settings.c b/apps/settings.c index ec96cc7..08e6376 100644 --- a/apps/settings.c +++ b/apps/settings.c @@ -38,6 +38,7 @@ #include "talk.h" #include "string.h" #include "ata.h" +#include "ata_idle_notify.h" #include "fat.h" #include "power.h" #include "powermgmt.h" @@ -802,6 +803,11 @@ static void init_config_buffer( void ) config_block[3] = CONFIG_BLOCK_VERSION; } +bool flush_config_block_callback(void) +{ + ata_write_sectors(IF_MV2(0,) config_sector, 1, config_block); + return true; +} /* * save the config block buffer to disk or RTC RAM */ @@ -833,7 +839,7 @@ static int save_config_buffer( void ) #endif if (config_sector != 0) - ata_delayed_write( config_sector, config_block); + register_ata_idle_func(flush_config_block_callback); else return -1; |