diff options
Diffstat (limited to 'quantum')
-rw-r--r-- | quantum/audio/audio_arm.c | 2 | ||||
-rw-r--r-- | quantum/rgblight.c | 8 |
2 files changed, 6 insertions, 4 deletions
diff --git a/quantum/audio/audio_arm.c b/quantum/audio/audio_arm.c index 87d625301..e4483c302 100644 --- a/quantum/audio/audio_arm.c +++ b/quantum/audio/audio_arm.c | |||
@@ -258,7 +258,7 @@ void audio_init() { | |||
258 | } | 258 | } |
259 | 259 | ||
260 | // Check EEPROM | 260 | // Check EEPROM |
261 | #if defined(STM32_EEPROM_ENABLE) || defined(PROTOCOL_ARM_ATSAM) || defined(EEPROM_SIZE) | 261 | #ifdef EEPROM_ENABLE |
262 | if (!eeconfig_is_enabled()) { | 262 | if (!eeconfig_is_enabled()) { |
263 | eeconfig_init(); | 263 | eeconfig_init(); |
264 | } | 264 | } |
diff --git a/quantum/rgblight.c b/quantum/rgblight.c index 40de19eac..67d601af7 100644 --- a/quantum/rgblight.c +++ b/quantum/rgblight.c | |||
@@ -19,9 +19,11 @@ | |||
19 | # include <avr/eeprom.h> | 19 | # include <avr/eeprom.h> |
20 | # include <avr/interrupt.h> | 20 | # include <avr/interrupt.h> |
21 | #endif | 21 | #endif |
22 | #ifdef EEPROM_ENABLE | ||
23 | # include "eeprom.h" | ||
24 | #endif | ||
22 | #ifdef STM32_EEPROM_ENABLE | 25 | #ifdef STM32_EEPROM_ENABLE |
23 | # include "hal.h" | 26 | # include "hal.h" |
24 | # include "eeprom.h" | ||
25 | # include "eeprom_stm32.h" | 27 | # include "eeprom_stm32.h" |
26 | #endif | 28 | #endif |
27 | #include "wait.h" | 29 | #include "wait.h" |
@@ -146,7 +148,7 @@ void rgblight_check_config(void) { | |||
146 | } | 148 | } |
147 | 149 | ||
148 | uint32_t eeconfig_read_rgblight(void) { | 150 | uint32_t eeconfig_read_rgblight(void) { |
149 | #if defined(__AVR__) || defined(STM32_EEPROM_ENABLE) || defined(PROTOCOL_ARM_ATSAM) || defined(EEPROM_SIZE) | 151 | #ifdef EEPROM_ENABLE |
150 | return eeprom_read_dword(EECONFIG_RGBLIGHT); | 152 | return eeprom_read_dword(EECONFIG_RGBLIGHT); |
151 | #else | 153 | #else |
152 | return 0; | 154 | return 0; |
@@ -154,7 +156,7 @@ uint32_t eeconfig_read_rgblight(void) { | |||
154 | } | 156 | } |
155 | 157 | ||
156 | void eeconfig_update_rgblight(uint32_t val) { | 158 | void eeconfig_update_rgblight(uint32_t val) { |
157 | #if defined(__AVR__) || defined(STM32_EEPROM_ENABLE) || defined(PROTOCOL_ARM_ATSAM) || defined(EEPROM_SIZE) | 159 | #ifdef EEPROM_ENABLE |
158 | rgblight_check_config(); | 160 | rgblight_check_config(); |
159 | eeprom_update_dword(EECONFIG_RGBLIGHT, val); | 161 | eeprom_update_dword(EECONFIG_RGBLIGHT, val); |
160 | #endif | 162 | #endif |