aboutsummaryrefslogtreecommitdiffstats
path: root/quantum/dynamic_keymap.c
diff options
context:
space:
mode:
authorGravatar Xelus22 <17491233+Xelus22@users.noreply.github.com>2020-09-16 16:16:01 +1000
committerGravatar GitHub <noreply@github.com>2020-09-16 16:16:01 +1000
commit97122d203bf443eda8ff63865223cc96bcc695f4 (patch)
treed29dc10321cc52dfe2d23586b7e512a19da1a2c3 /quantum/dynamic_keymap.c
parent06d4c0a3968f3f0ae0fc5deb36cb4b8de44b1428 (diff)
downloadqmk_firmware-97122d203bf443eda8ff63865223cc96bcc695f4.tar.gz
[Core] DYNAMIC_KEYMAP_EEPROM_MAX_ADDR check (#10315)
* add error check * remove quotes * update error message Co-authored-by: Ryan <fauxpark@gmail.com> Co-authored-by: Ryan <fauxpark@gmail.com>
Diffstat (limited to 'quantum/dynamic_keymap.c')
-rw-r--r--quantum/dynamic_keymap.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/quantum/dynamic_keymap.c b/quantum/dynamic_keymap.c
index 27ee6a284..0608b469c 100644
--- a/quantum/dynamic_keymap.c
+++ b/quantum/dynamic_keymap.c
@@ -42,6 +42,11 @@
# endif
#endif
+// Due to usage of uint16_t check for max 65535
+#if DYNAMIC_KEYMAP_EEPROM_MAX_ADDR > 65535
+# error DYNAMIC_KEYMAP_EEPROM_MAX_ADDR must be less than 65536
+#endif
+
// If DYNAMIC_KEYMAP_EEPROM_ADDR not explicitly defined in config.h,
// default it start after VIA_EEPROM_CUSTOM_ADDR+VIA_EEPROM_CUSTOM_SIZE
#ifndef DYNAMIC_KEYMAP_EEPROM_ADDR