diff options
author | Solomon Peachy <pizza@shaftnet.org> | 2024-07-07 11:48:46 -0400 |
---|---|---|
committer | Solomon Peachy <pizza@shaftnet.org> | 2024-07-07 12:05:18 -0400 |
commit | 181fe7530a6b45568167a0d539f6806c62338165 (patch) | |
tree | 46fa7c1a02c2a924d6b9e95e9140fd57b5230e23 | |
parent | ea80d1cc9cdaf1af5e1e5a42d878f3f231a3a65b (diff) | |
download | rockbox-181fe7530a6b45568167a0d539f6806c62338165.tar.gz rockbox-181fe7530a6b45568167a0d539f6806c62338165.zip |
Fix most of the (extensive) red in ea80d1cc9ca
Change-Id: Ie494df80caa222423a52977031920d54bd058c3c
-rw-r--r-- | firmware/export/config.h | 33 | ||||
-rw-r--r-- | firmware/export/config/ihifi760.h | 1 | ||||
-rw-r--r-- | firmware/export/config/ihifi770.h | 6 | ||||
-rw-r--r-- | firmware/export/config/ihifi770c.h | 6 | ||||
-rw-r--r-- | firmware/export/config/ihifi800.h | 6 | ||||
-rw-r--r-- | firmware/export/config/ihifi960.h | 1 | ||||
-rw-r--r-- | firmware/export/config/rk27generic.h | 1 | ||||
-rw-r--r-- | firmware/target/mips/ingenic_x1000/sd-x1000.c | 7 |
8 files changed, 35 insertions, 26 deletions
diff --git a/firmware/export/config.h b/firmware/export/config.h index cad25facb0..c6bd74ba34 100644 --- a/firmware/export/config.h +++ b/firmware/export/config.h | |||
@@ -868,6 +868,18 @@ Lyre prototype 1 */ | |||
868 | #define CONFIG_STORAGE_MULTI | 868 | #define CONFIG_STORAGE_MULTI |
869 | #endif | 869 | #endif |
870 | 870 | ||
871 | #if defined(CONFIG_STORAGE_MULTI) && !defined(HAVE_MULTIDRIVE) | ||
872 | #define HAVE_MULTIDRIVE | ||
873 | #endif | ||
874 | |||
875 | #if defined(HAVE_MULTIDRIVE) && !defined(NUM_DRIVES) | ||
876 | #error HAVE_MULTIDRIVE needs to have an explicit NUM_DRIVES | ||
877 | #endif | ||
878 | |||
879 | #ifndef NUM_DRIVES | ||
880 | #define NUM_DRIVES 1 | ||
881 | #endif | ||
882 | |||
871 | #if !defined(HAVE_MULTIVOLUME) | 883 | #if !defined(HAVE_MULTIVOLUME) |
872 | #if defined(HAVE_MULTIDRIVE) | 884 | #if defined(HAVE_MULTIDRIVE) |
873 | /* Multidrive strongly implies multivolume */ | 885 | /* Multidrive strongly implies multivolume */ |
@@ -886,13 +898,6 @@ Lyre prototype 1 */ | |||
886 | #else | 898 | #else |
887 | #define NUM_VOLUMES_PER_DRIVE 1 | 899 | #define NUM_VOLUMES_PER_DRIVE 1 |
888 | #endif | 900 | #endif |
889 | #if defined(CONFIG_STORAGE_MULTI) && !defined(HAVE_MULTIDRIVE) | ||
890 | #define HAVE_MULTIDRIVE | ||
891 | #endif | ||
892 | |||
893 | #if defined(HAVE_MULTIDRIVE) && !defined(NUM_DRIVES) | ||
894 | #error HAVE_MULTIDRIVE needs to have an explicit NUM_DRIVES | ||
895 | #endif | ||
896 | 901 | ||
897 | /* note to remove multi-partition booting this could be changed to MULTIDRIVE */ | 902 | /* note to remove multi-partition booting this could be changed to MULTIDRIVE */ |
898 | #if defined(HAVE_BOOTDATA) && defined(BOOT_REDIR) && defined(HAVE_MULTIVOLUME) | 903 | #if defined(HAVE_BOOTDATA) && defined(BOOT_REDIR) && defined(HAVE_MULTIVOLUME) |
@@ -905,10 +910,6 @@ Lyre prototype 1 */ | |||
905 | # define MULTIBOOT_MIN_VOLUME 0 | 910 | # define MULTIBOOT_MIN_VOLUME 0 |
906 | #endif | 911 | #endif |
907 | 912 | ||
908 | #ifndef NUM_DRIVES | ||
909 | #define NUM_DRIVES 1 | ||
910 | #endif | ||
911 | |||
912 | #define NUM_VOLUMES (NUM_DRIVES * NUM_VOLUMES_PER_DRIVE) | 913 | #define NUM_VOLUMES (NUM_DRIVES * NUM_VOLUMES_PER_DRIVE) |
913 | 914 | ||
914 | #if defined(BOOTLOADER) && defined(HAVE_ADJUSTABLE_CPU_FREQ) | 915 | #if defined(BOOTLOADER) && defined(HAVE_ADJUSTABLE_CPU_FREQ) |
@@ -942,31 +943,35 @@ Lyre prototype 1 */ | |||
942 | #ifdef HAVE_BOOTLOADER_USB_MODE | 943 | #ifdef HAVE_BOOTLOADER_USB_MODE |
943 | /* Priority in bootloader is wanted */ | 944 | /* Priority in bootloader is wanted */ |
944 | #define HAVE_PRIORITY_SCHEDULING | 945 | #define HAVE_PRIORITY_SCHEDULING |
946 | |||
945 | #if (CONFIG_CPU == S5L8702) | 947 | #if (CONFIG_CPU == S5L8702) |
946 | #define USB_DRIVER_CLOSE | 948 | #define USB_DRIVER_CLOSE |
947 | #else | 949 | #else |
948 | #define USB_STATUS_BY_EVENT | 950 | #define USB_STATUS_BY_EVENT |
949 | #define USB_DETECT_BY_REQUEST | 951 | #define USB_DETECT_BY_REQUEST |
950 | #endif | 952 | #endif |
953 | |||
951 | #if defined(HAVE_USBSTACK) && CONFIG_USBOTG == USBOTG_ARC | 954 | #if defined(HAVE_USBSTACK) && CONFIG_USBOTG == USBOTG_ARC |
952 | #define INCLUDE_TIMEOUT_API | 955 | #define INCLUDE_TIMEOUT_API |
953 | #define USB_DRIVER_CLOSE | 956 | #define USB_DRIVER_CLOSE |
954 | #endif | 957 | #endif |
958 | |||
955 | #if defined(HAVE_USBSTACK) && CONFIG_USBOTG == USBOTG_TNETV105 | 959 | #if defined(HAVE_USBSTACK) && CONFIG_USBOTG == USBOTG_TNETV105 |
956 | #define INCLUDE_TIMEOUT_API | 960 | #define INCLUDE_TIMEOUT_API |
957 | #define USB_DRIVER_CLOSE | 961 | #define USB_DRIVER_CLOSE |
958 | #endif | 962 | #endif |
963 | |||
959 | #if CONFIG_CPU == X1000 | 964 | #if CONFIG_CPU == X1000 |
960 | #define USB_DRIVER_CLOSE | 965 | #define USB_DRIVER_CLOSE |
961 | #endif | 966 | #endif |
962 | #endif | 967 | |
968 | #endif /* BOOTLOADER_USB_MODE */ | ||
963 | 969 | ||
964 | #else /* !BOOTLOADER */ | 970 | #else /* !BOOTLOADER */ |
965 | 971 | ||
966 | #define HAVE_EXTENDED_MESSAGING_AND_NAME | 972 | #define HAVE_EXTENDED_MESSAGING_AND_NAME |
967 | #define HAVE_WAKEUP_EXT_CB | 973 | #define HAVE_WAKEUP_EXT_CB |
968 | 974 | ||
969 | |||
970 | #if defined(ASSEMBLER_THREADS) \ | 975 | #if defined(ASSEMBLER_THREADS) \ |
971 | || defined(HAVE_WIN32_FIBER_THREADS) \ | 976 | || defined(HAVE_WIN32_FIBER_THREADS) \ |
972 | || defined(HAVE_SIGALTSTACK_THREADS) | 977 | || defined(HAVE_SIGALTSTACK_THREADS) |
@@ -1001,7 +1006,7 @@ Lyre prototype 1 */ | |||
1001 | #endif /* CONFIG_USB == */ | 1006 | #endif /* CONFIG_USB == */ |
1002 | #endif /* HAVE_USBSTACK */ | 1007 | #endif /* HAVE_USBSTACK */ |
1003 | 1008 | ||
1004 | #endif /* BOOTLOADER */ | 1009 | #endif /* !BOOTLOADER */ |
1005 | 1010 | ||
1006 | #if defined(HAVE_USBSTACK) || (CONFIG_CPU == JZ4732) || (CONFIG_CPU == JZ4760B) \ | 1011 | #if defined(HAVE_USBSTACK) || (CONFIG_CPU == JZ4732) || (CONFIG_CPU == JZ4760B) \ |
1007 | || (CONFIG_CPU == AS3525) || (CONFIG_CPU == AS3525v2) \ | 1012 | || (CONFIG_CPU == AS3525) || (CONFIG_CPU == AS3525v2) \ |
diff --git a/firmware/export/config/ihifi760.h b/firmware/export/config/ihifi760.h index b4a1e6ade0..5ba19a55c3 100644 --- a/firmware/export/config/ihifi760.h +++ b/firmware/export/config/ihifi760.h | |||
@@ -49,6 +49,7 @@ | |||
49 | #define HAVE_FLASH_STORAGE | 49 | #define HAVE_FLASH_STORAGE |
50 | 50 | ||
51 | #define CONFIG_STORAGE (STORAGE_SD | STORAGE_NAND) | 51 | #define CONFIG_STORAGE (STORAGE_SD | STORAGE_NAND) |
52 | #define NUM_DRIVES 1 /* NAND doesn't work yet */#define NUM_DRIVES 1 /* NAND doesn't work yet */ | ||
52 | 53 | ||
53 | #define CONFIG_NAND NAND_RK27XX | 54 | #define CONFIG_NAND NAND_RK27XX |
54 | #define HAVE_SW_TONE_CONTROLS | 55 | #define HAVE_SW_TONE_CONTROLS |
diff --git a/firmware/export/config/ihifi770.h b/firmware/export/config/ihifi770.h index 82a9b1b1eb..68f6c71b90 100644 --- a/firmware/export/config/ihifi770.h +++ b/firmware/export/config/ihifi770.h | |||
@@ -50,11 +50,12 @@ | |||
50 | #define HAVE_FLASH_STORAGE | 50 | #define HAVE_FLASH_STORAGE |
51 | 51 | ||
52 | #define CONFIG_STORAGE (STORAGE_SD | STORAGE_NAND) | 52 | #define CONFIG_STORAGE (STORAGE_SD | STORAGE_NAND) |
53 | #define NUM_DRIVES 1 /* NAND doesn't work yet */ | ||
53 | 54 | ||
54 | #define CONFIG_NAND NAND_RK27XX | 55 | #define CONFIG_NAND NAND_RK27XX |
55 | #define HAVE_SW_TONE_CONTROLS | 56 | #define HAVE_SW_TONE_CONTROLS |
56 | 57 | ||
57 | #define HAVE_HOTSWAP | 58 | // #define HAVE_HOTSWAP |
58 | 59 | ||
59 | #define SECTOR_SIZE 512 | 60 | #define SECTOR_SIZE 512 |
60 | 61 | ||
@@ -182,7 +183,4 @@ | |||
182 | #define BOOTFILE "rockbox." BOOTFILE_EXT | 183 | #define BOOTFILE "rockbox." BOOTFILE_EXT |
183 | #define BOOTDIR "/.rockbox" | 184 | #define BOOTDIR "/.rockbox" |
184 | 185 | ||
185 | /* disabled for now */ | ||
186 | #undef HAVE_HOTSWAP | ||
187 | |||
188 | #endif /* SIMULATOR */ | 186 | #endif /* SIMULATOR */ |
diff --git a/firmware/export/config/ihifi770c.h b/firmware/export/config/ihifi770c.h index 1e945610bc..a34d1b85c2 100644 --- a/firmware/export/config/ihifi770c.h +++ b/firmware/export/config/ihifi770c.h | |||
@@ -50,11 +50,12 @@ | |||
50 | #define HAVE_FLASH_STORAGE | 50 | #define HAVE_FLASH_STORAGE |
51 | 51 | ||
52 | #define CONFIG_STORAGE (STORAGE_SD | STORAGE_NAND) | 52 | #define CONFIG_STORAGE (STORAGE_SD | STORAGE_NAND) |
53 | #define NUM_DRIVES 1 /* NAND doesn't work yet */ | ||
53 | 54 | ||
54 | #define CONFIG_NAND NAND_RK27XX | 55 | #define CONFIG_NAND NAND_RK27XX |
55 | #define HAVE_SW_TONE_CONTROLS | 56 | #define HAVE_SW_TONE_CONTROLS |
56 | 57 | ||
57 | #define HAVE_HOTSWAP | 58 | // #define HAVE_HOTSWAP |
58 | 59 | ||
59 | #define SECTOR_SIZE 512 | 60 | #define SECTOR_SIZE 512 |
60 | 61 | ||
@@ -182,7 +183,4 @@ | |||
182 | #define BOOTFILE "rockbox." BOOTFILE_EXT | 183 | #define BOOTFILE "rockbox." BOOTFILE_EXT |
183 | #define BOOTDIR "/.rockbox" | 184 | #define BOOTDIR "/.rockbox" |
184 | 185 | ||
185 | /* disabled for now */ | ||
186 | #undef HAVE_HOTSWAP | ||
187 | |||
188 | #endif /* SIMULATOR */ | 186 | #endif /* SIMULATOR */ |
diff --git a/firmware/export/config/ihifi800.h b/firmware/export/config/ihifi800.h index 9c1614c30c..e0cd1e1161 100644 --- a/firmware/export/config/ihifi800.h +++ b/firmware/export/config/ihifi800.h | |||
@@ -50,11 +50,12 @@ | |||
50 | #define HAVE_FLASH_STORAGE | 50 | #define HAVE_FLASH_STORAGE |
51 | 51 | ||
52 | #define CONFIG_STORAGE (STORAGE_SD | STORAGE_NAND) | 52 | #define CONFIG_STORAGE (STORAGE_SD | STORAGE_NAND) |
53 | #define NUM_DRIVES 1 /* NAND doesn't work yet */ | ||
53 | 54 | ||
54 | #define CONFIG_NAND NAND_RK27XX | 55 | #define CONFIG_NAND NAND_RK27XX |
55 | #define HAVE_SW_TONE_CONTROLS | 56 | #define HAVE_SW_TONE_CONTROLS |
56 | 57 | ||
57 | #define HAVE_HOTSWAP | 58 | //#define HAVE_HOTSWAP |
58 | 59 | ||
59 | #define SECTOR_SIZE 512 | 60 | #define SECTOR_SIZE 512 |
60 | 61 | ||
@@ -183,7 +184,4 @@ | |||
183 | #define BOOTFILE "rockbox." BOOTFILE_EXT | 184 | #define BOOTFILE "rockbox." BOOTFILE_EXT |
184 | #define BOOTDIR "/.rockbox" | 185 | #define BOOTDIR "/.rockbox" |
185 | 186 | ||
186 | /* disabled for now */ | ||
187 | #undef HAVE_HOTSWAP | ||
188 | |||
189 | #endif /* SIMULATOR */ | 187 | #endif /* SIMULATOR */ |
diff --git a/firmware/export/config/ihifi960.h b/firmware/export/config/ihifi960.h index f8bd46d1ea..c0af676f28 100644 --- a/firmware/export/config/ihifi960.h +++ b/firmware/export/config/ihifi960.h | |||
@@ -49,6 +49,7 @@ | |||
49 | #define HAVE_FLASH_STORAGE | 49 | #define HAVE_FLASH_STORAGE |
50 | 50 | ||
51 | #define CONFIG_STORAGE (STORAGE_SD | STORAGE_NAND) | 51 | #define CONFIG_STORAGE (STORAGE_SD | STORAGE_NAND) |
52 | #define NUM_DRIVES 1 /* NAND doesn't work yet */ | ||
52 | 53 | ||
53 | #define CONFIG_NAND NAND_RK27XX | 54 | #define CONFIG_NAND NAND_RK27XX |
54 | #define HAVE_SW_TONE_CONTROLS | 55 | #define HAVE_SW_TONE_CONTROLS |
diff --git a/firmware/export/config/rk27generic.h b/firmware/export/config/rk27generic.h index 5a18f7a35e..23768c1d2e 100644 --- a/firmware/export/config/rk27generic.h +++ b/firmware/export/config/rk27generic.h | |||
@@ -56,6 +56,7 @@ | |||
56 | #define HAVE_FLASH_STORAGE | 56 | #define HAVE_FLASH_STORAGE |
57 | 57 | ||
58 | #define CONFIG_STORAGE (STORAGE_SD | STORAGE_NAND) | 58 | #define CONFIG_STORAGE (STORAGE_SD | STORAGE_NAND) |
59 | #define NUM_DRIVES 1 /* NAND doesn't work yet */ | ||
59 | 60 | ||
60 | #define CONFIG_NAND NAND_RK27XX | 61 | #define CONFIG_NAND NAND_RK27XX |
61 | #define HAVE_SW_TONE_CONTROLS | 62 | #define HAVE_SW_TONE_CONTROLS |
diff --git a/firmware/target/mips/ingenic_x1000/sd-x1000.c b/firmware/target/mips/ingenic_x1000/sd-x1000.c index 679a25a222..4312937ee8 100644 --- a/firmware/target/mips/ingenic_x1000/sd-x1000.c +++ b/firmware/target/mips/ingenic_x1000/sd-x1000.c | |||
@@ -187,6 +187,9 @@ long sd_last_disk_activity(void) | |||
187 | 187 | ||
188 | bool sd_present(IF_MD_NONVOID(int drive)) | 188 | bool sd_present(IF_MD_NONVOID(int drive)) |
189 | { | 189 | { |
190 | #ifndef HAVE_MULTIDRIVE | ||
191 | int drive = 0; | ||
192 | #endif | ||
190 | /* Seems that volume_properties() in firmware/common/disk.c may pass | 193 | /* Seems that volume_properties() in firmware/common/disk.c may pass |
191 | * drive = -1 when the SD card is not inserted, so just return false. | 194 | * drive = -1 when the SD card is not inserted, so just return false. |
192 | */ | 195 | */ |
@@ -198,6 +201,10 @@ bool sd_present(IF_MD_NONVOID(int drive)) | |||
198 | 201 | ||
199 | bool sd_removable(IF_MD_NONVOID(int drive)) | 202 | bool sd_removable(IF_MD_NONVOID(int drive)) |
200 | { | 203 | { |
204 | #ifndef HAVE_MULTIDRIVE | ||
205 | int drive = 0; | ||
206 | #endif | ||
207 | |||
201 | /* Same reason as sd_present() */ | 208 | /* Same reason as sd_present() */ |
202 | if(drive < 0) | 209 | if(drive < 0) |
203 | return false; | 210 | return false; |