From 2f8a0081c64534da23fc0fa9cc685eb7454fd9c9 Mon Sep 17 00:00:00 2001 From: Frank Gevaerts Date: Sat, 1 Nov 2008 16:14:28 +0000 Subject: Apply FS#9500. This adds a storage_*() abstraction to replace ata_*(). To do that, it also introduces sd_*, nand_*, and mmc_*. This should be a good first step to allow multi-driver targets, like the Elio (ATA/SD), or the D2 (NAND/SD). git-svn-id: svn://svn.rockbox.org/rockbox/trunk@18960 a1c6a512-1295-4272-9138-f99709370657 --- apps/settings.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'apps/settings.c') diff --git a/apps/settings.c b/apps/settings.c index 709e05e086..e15bfc8638 100644 --- a/apps/settings.c +++ b/apps/settings.c @@ -38,6 +38,7 @@ #include "rtc.h" #include "power.h" #include "ata_idle_notify.h" +#include "storage.h" #include "screens.h" #include "ctype.h" #include "file.h" @@ -582,11 +583,11 @@ void status_save(void) { update_runtime(); #ifdef HAVE_RTC_RAM - /* this will be done in the ata_callback if + /* this will be done in the storage_callback if target doesnt have rtc ram */ write_nvram_data(nvram_buffer,NVRAM_BLOCK_SIZE); #else - register_ata_idle_func(flush_global_status_callback); + register_storage_idle_func(flush_global_status_callback); #endif } @@ -594,11 +595,11 @@ int settings_save(void) { update_runtime(); #ifdef HAVE_RTC_RAM - /* this will be done in the ata_callback if + /* this will be done in the storage_callback if target doesnt have rtc ram */ write_nvram_data(nvram_buffer,NVRAM_BLOCK_SIZE); #endif - register_ata_idle_func(flush_config_block_callback); + register_storage_idle_func(flush_config_block_callback); return 0; } @@ -768,7 +769,7 @@ void settings_apply(bool read_disk) buttonlight_set_timeout(global_settings.buttonlight_timeout); #endif #ifdef HAVE_DISK_STORAGE - ata_spindown(global_settings.disk_spindown); + storage_spindown(global_settings.disk_spindown); #endif #if (CONFIG_CODEC == MAS3507D) && !defined(SIMULATOR) dac_line_in(global_settings.line_in); -- cgit v1.2.3