From 1efc79063c5bc5fae6766f7555738b122ef8988d Mon Sep 17 00:00:00 2001 From: Joel Challis Date: Mon, 13 Nov 2023 22:30:19 +0000 Subject: [PATCH] Migrate some EEPROM config to info.json (#22434) --- keyboards/acheron/themis/87h/config.h | 3 --- keyboards/acheron/themis/87h/info.json | 5 +++++ keyboards/acheron/themis/87htsc/config.h | 3 --- keyboards/acheron/themis/87htsc/info.json | 5 +++++ keyboards/acheron/themis/88htsc/config.h | 3 --- keyboards/acheron/themis/88htsc/info.json | 5 +++++ keyboards/akko/5087/config.h | 1 - keyboards/akko/5087/info.json | 7 +++++++ keyboards/akko/5087/rules.mk | 4 +--- keyboards/darkproject/kd87a_bfg_edition/config.h | 1 - keyboards/darkproject/kd87a_bfg_edition/info.json | 10 +++++++--- keyboards/darkproject/kd87a_bfg_edition/rules.mk | 2 +- keyboards/inland/v83p/config.h | 1 - keyboards/inland/v83p/info.json | 7 +++++++ keyboards/inland/v83p/rules.mk | 3 +-- keyboards/jukaie/jk01/config.h | 1 - keyboards/jukaie/jk01/info.json | 10 +++++++--- keyboards/jukaie/jk01/rules.mk | 2 +- keyboards/monsgeek/m3/config.h | 1 - keyboards/monsgeek/m3/info.json | 7 +++++++ keyboards/monsgeek/m3/rules.mk | 3 +-- keyboards/phentech/rpk_001/config.h | 1 - keyboards/phentech/rpk_001/info.json | 7 +++++++ keyboards/phentech/rpk_001/rules.mk | 2 +- keyboards/projectd/75/ansi/config.h | 1 - keyboards/projectd/75/ansi/info.json | 10 +++++++--- keyboards/projectd/75/ansi/rules.mk | 2 +- keyboards/vinhcatba/uncertainty/info.json | 3 +++ keyboards/vinhcatba/uncertainty/rules.mk | 2 -- 29 files changed, 74 insertions(+), 38 deletions(-) diff --git a/keyboards/acheron/themis/87h/config.h b/keyboards/acheron/themis/87h/config.h index 8a1ff485832..605594eea20 100644 --- a/keyboards/acheron/themis/87h/config.h +++ b/keyboards/acheron/themis/87h/config.h @@ -28,6 +28,3 @@ along with this program. If not, see . #define WS2812_PWM_PAL_MODE 1 #define WS2812_DMA_STREAM STM32_DMA2_STREAM5 #define WS2812_DMA_CHANNEL 6 - -#define WEAR_LEVELING_LOGICAL_SIZE 4096 -#define WEAR_LEVELING_BACKING_SIZE 8192 diff --git a/keyboards/acheron/themis/87h/info.json b/keyboards/acheron/themis/87h/info.json index ed5d48690d3..cbff8f4eec5 100644 --- a/keyboards/acheron/themis/87h/info.json +++ b/keyboards/acheron/themis/87h/info.json @@ -21,6 +21,11 @@ "nkro": true }, "diode_direction": "COL2ROW", + "eeprom": { + "wear_leveling": { + "backing_size": 8192 + } + }, "ws2812": { "pin": "B15" }, diff --git a/keyboards/acheron/themis/87htsc/config.h b/keyboards/acheron/themis/87htsc/config.h index 8a1ff485832..605594eea20 100644 --- a/keyboards/acheron/themis/87htsc/config.h +++ b/keyboards/acheron/themis/87htsc/config.h @@ -28,6 +28,3 @@ along with this program. If not, see . #define WS2812_PWM_PAL_MODE 1 #define WS2812_DMA_STREAM STM32_DMA2_STREAM5 #define WS2812_DMA_CHANNEL 6 - -#define WEAR_LEVELING_LOGICAL_SIZE 4096 -#define WEAR_LEVELING_BACKING_SIZE 8192 diff --git a/keyboards/acheron/themis/87htsc/info.json b/keyboards/acheron/themis/87htsc/info.json index 854ad5a7d58..5b491690bbc 100644 --- a/keyboards/acheron/themis/87htsc/info.json +++ b/keyboards/acheron/themis/87htsc/info.json @@ -21,6 +21,11 @@ "nkro": true }, "diode_direction": "COL2ROW", + "eeprom": { + "wear_leveling": { + "backing_size": 8192 + } + }, "ws2812": { "pin": "B15" }, diff --git a/keyboards/acheron/themis/88htsc/config.h b/keyboards/acheron/themis/88htsc/config.h index 8a1ff485832..605594eea20 100644 --- a/keyboards/acheron/themis/88htsc/config.h +++ b/keyboards/acheron/themis/88htsc/config.h @@ -28,6 +28,3 @@ along with this program. If not, see . #define WS2812_PWM_PAL_MODE 1 #define WS2812_DMA_STREAM STM32_DMA2_STREAM5 #define WS2812_DMA_CHANNEL 6 - -#define WEAR_LEVELING_LOGICAL_SIZE 4096 -#define WEAR_LEVELING_BACKING_SIZE 8192 diff --git a/keyboards/acheron/themis/88htsc/info.json b/keyboards/acheron/themis/88htsc/info.json index cfce0702eb4..073a16e9461 100644 --- a/keyboards/acheron/themis/88htsc/info.json +++ b/keyboards/acheron/themis/88htsc/info.json @@ -21,6 +21,11 @@ "nkro": true }, "diode_direction": "COL2ROW", + "eeprom": { + "wear_leveling": { + "backing_size": 8192 + } + }, "ws2812": { "pin": "B15" }, diff --git a/keyboards/akko/5087/config.h b/keyboards/akko/5087/config.h index 50a1f224f8b..3a6b7030ee7 100644 --- a/keyboards/akko/5087/config.h +++ b/keyboards/akko/5087/config.h @@ -34,7 +34,6 @@ #define SPI_MOSI_PAL_MODE 5 #define EXTERNAL_FLASH_SPI_SLAVE_SELECT_PIN C12 -#define WEAR_LEVELING_BACKING_SIZE (8 * 1024) /* I2C Config for LED Driver */ #define DRIVER_COUNT 2 diff --git a/keyboards/akko/5087/info.json b/keyboards/akko/5087/info.json index 43bec927db1..1b4059b0d58 100644 --- a/keyboards/akko/5087/info.json +++ b/keyboards/akko/5087/info.json @@ -29,6 +29,13 @@ "rows": ["B15", "C6", "C7", "C8", "C9", "A8"] }, "diode_direction": "ROW2COL", + "eeprom": { + "driver": "wear_leveling", + "wear_leveling": { + "driver": "spi_flash", + "backing_size": 8192 + } + }, "indicators": { "caps_lock": "A15" }, diff --git a/keyboards/akko/5087/rules.mk b/keyboards/akko/5087/rules.mk index 0dc7a331420..6e7633bfe01 100644 --- a/keyboards/akko/5087/rules.mk +++ b/keyboards/akko/5087/rules.mk @@ -1,3 +1 @@ -EEPROM_DRIVER = wear_leveling -WEAR_LEVELING_DRIVER = spi_flash - +# This file intentionally left blank diff --git a/keyboards/darkproject/kd87a_bfg_edition/config.h b/keyboards/darkproject/kd87a_bfg_edition/config.h index 335648df9ab..a7498186b4b 100644 --- a/keyboards/darkproject/kd87a_bfg_edition/config.h +++ b/keyboards/darkproject/kd87a_bfg_edition/config.h @@ -25,7 +25,6 @@ /* External spi flash */ #define EXTERNAL_FLASH_SPI_SLAVE_SELECT_PIN B14 -#define WEAR_LEVELING_BACKING_SIZE (8 * 1024) /* SPI Config for LED Driver */ #define SPI_DRIVER SPIDQ diff --git a/keyboards/darkproject/kd87a_bfg_edition/info.json b/keyboards/darkproject/kd87a_bfg_edition/info.json index 1cf428a97f1..94717c6baac 100644 --- a/keyboards/darkproject/kd87a_bfg_edition/info.json +++ b/keyboards/darkproject/kd87a_bfg_edition/info.json @@ -7,6 +7,13 @@ "matrix": [1, 3] }, "diode_direction": "COL2ROW", + "eeprom": { + "driver": "wear_leveling", + "wear_leveling": { + "driver": "spi_flash", + "backing_size": 8192 + } + }, "features": { "bootmagic": true, "extrakey": true, @@ -174,9 +181,6 @@ "pid": "0xE393", "vid": "0x342D" }, - "eeprom": { - "driver": "wear_leveling" - }, "community_layouts": ["tkl_ansi"], "layouts": { "LAYOUT_tkl_ansi": { diff --git a/keyboards/darkproject/kd87a_bfg_edition/rules.mk b/keyboards/darkproject/kd87a_bfg_edition/rules.mk index 002458405ee..6e7633bfe01 100644 --- a/keyboards/darkproject/kd87a_bfg_edition/rules.mk +++ b/keyboards/darkproject/kd87a_bfg_edition/rules.mk @@ -1 +1 @@ -WEAR_LEVELING_DRIVER = spi_flash +# This file intentionally left blank diff --git a/keyboards/inland/v83p/config.h b/keyboards/inland/v83p/config.h index 1cd93e20339..1553c3e6325 100644 --- a/keyboards/inland/v83p/config.h +++ b/keyboards/inland/v83p/config.h @@ -29,7 +29,6 @@ #define SPI_MOSI_PAL_MODE 5 #define EXTERNAL_FLASH_SPI_SLAVE_SELECT_PIN C12 -#define WEAR_LEVELING_BACKING_SIZE (4 * 1024) #define RGB_MATRIX_FRAMEBUFFER_EFFECTS #define RGB_MATRIX_KEYPRESSES diff --git a/keyboards/inland/v83p/info.json b/keyboards/inland/v83p/info.json index f738af3ef72..900937570f8 100644 --- a/keyboards/inland/v83p/info.json +++ b/keyboards/inland/v83p/info.json @@ -12,6 +12,13 @@ "suspend_wakeup_delay": 1000 }, "diode_direction": "ROW2COL", + "eeprom": { + "driver": "wear_leveling", + "wear_leveling": { + "driver": "spi_flash", + "backing_size": 4096 + } + }, "features": { "bootmagic": true, "command": false, diff --git a/keyboards/inland/v83p/rules.mk b/keyboards/inland/v83p/rules.mk index 24d5f6f52ec..6e7633bfe01 100644 --- a/keyboards/inland/v83p/rules.mk +++ b/keyboards/inland/v83p/rules.mk @@ -1,2 +1 @@ -EEPROM_DRIVER = wear_leveling -WEAR_LEVELING_DRIVER = spi_flash +# This file intentionally left blank diff --git a/keyboards/jukaie/jk01/config.h b/keyboards/jukaie/jk01/config.h index 8a7ea71db4e..e83415f5baa 100644 --- a/keyboards/jukaie/jk01/config.h +++ b/keyboards/jukaie/jk01/config.h @@ -25,7 +25,6 @@ /* External spi flash */ #define EXTERNAL_FLASH_SPI_SLAVE_SELECT_PIN B14 -#define WEAR_LEVELING_BACKING_SIZE (8 * 1024) /* SPI Config for LED Driver */ #define SPI_DRIVER SPIDQ diff --git a/keyboards/jukaie/jk01/info.json b/keyboards/jukaie/jk01/info.json index 87c787158c7..c53a59a5a31 100644 --- a/keyboards/jukaie/jk01/info.json +++ b/keyboards/jukaie/jk01/info.json @@ -7,6 +7,13 @@ "matrix": [1, 3] }, "diode_direction": "COL2ROW", + "eeprom": { + "driver": "wear_leveling", + "wear_leveling": { + "driver": "spi_flash", + "backing_size": 8192 + } + }, "encoder": { "rotary": [ {"pin_a": "C2", "pin_b": "C3"} @@ -175,9 +182,6 @@ "pid": "0x0002", "vid": "0x4141" }, - "eeprom": { - "driver": "wear_leveling" - }, "layouts": { "LAYOUT": { "layout": [ diff --git a/keyboards/jukaie/jk01/rules.mk b/keyboards/jukaie/jk01/rules.mk index 002458405ee..6e7633bfe01 100644 --- a/keyboards/jukaie/jk01/rules.mk +++ b/keyboards/jukaie/jk01/rules.mk @@ -1 +1 @@ -WEAR_LEVELING_DRIVER = spi_flash +# This file intentionally left blank diff --git a/keyboards/monsgeek/m3/config.h b/keyboards/monsgeek/m3/config.h index 93ffa1f07c4..41c9ea3ceac 100644 --- a/keyboards/monsgeek/m3/config.h +++ b/keyboards/monsgeek/m3/config.h @@ -33,7 +33,6 @@ #define SPI_MOSI_PAL_MODE 5 #define EXTERNAL_FLASH_SPI_SLAVE_SELECT_PIN C12 -#define WEAR_LEVELING_BACKING_SIZE (8 * 1024) /* I2C Config for LED Driver */ #define SNLED27351_DRIVER_COUNT 2 diff --git a/keyboards/monsgeek/m3/info.json b/keyboards/monsgeek/m3/info.json index a93b0d47dcf..df99a6a22c4 100644 --- a/keyboards/monsgeek/m3/info.json +++ b/keyboards/monsgeek/m3/info.json @@ -11,6 +11,13 @@ }, "processor": "WB32FQ95", "bootloader": "wb32-dfu", + "eeprom": { + "driver": "wear_leveling", + "wear_leveling": { + "driver": "spi_flash", + "backing_size": 8192 + } + }, "features": { "bootmagic": true, "extrakey": true, diff --git a/keyboards/monsgeek/m3/rules.mk b/keyboards/monsgeek/m3/rules.mk index 24d5f6f52ec..6e7633bfe01 100644 --- a/keyboards/monsgeek/m3/rules.mk +++ b/keyboards/monsgeek/m3/rules.mk @@ -1,2 +1 @@ -EEPROM_DRIVER = wear_leveling -WEAR_LEVELING_DRIVER = spi_flash +# This file intentionally left blank diff --git a/keyboards/phentech/rpk_001/config.h b/keyboards/phentech/rpk_001/config.h index 05391a21ed7..f513dd26845 100644 --- a/keyboards/phentech/rpk_001/config.h +++ b/keyboards/phentech/rpk_001/config.h @@ -17,7 +17,6 @@ /* SPI Flash */ #define EXTERNAL_FLASH_SPI_SLAVE_SELECT_PIN C12 -#define WEAR_LEVELING_BACKING_SIZE (4 * 1024) /* RGB Matrix */ #define RGB_DISABLE_WHEN_USB_SUSPENDED diff --git a/keyboards/phentech/rpk_001/info.json b/keyboards/phentech/rpk_001/info.json index 3d89d012ee2..d047c36456a 100644 --- a/keyboards/phentech/rpk_001/info.json +++ b/keyboards/phentech/rpk_001/info.json @@ -13,6 +13,13 @@ "suspend_wakeup_delay": 1000 }, "diode_direction": "ROW2COL", + "eeprom": { + "driver": "wear_leveling", + "wear_leveling": { + "driver": "spi_flash", + "backing_size": 4096 + } + }, "features": { "nkro": true, "encoder": true, diff --git a/keyboards/phentech/rpk_001/rules.mk b/keyboards/phentech/rpk_001/rules.mk index 002458405ee..6e7633bfe01 100644 --- a/keyboards/phentech/rpk_001/rules.mk +++ b/keyboards/phentech/rpk_001/rules.mk @@ -1 +1 @@ -WEAR_LEVELING_DRIVER = spi_flash +# This file intentionally left blank diff --git a/keyboards/projectd/75/ansi/config.h b/keyboards/projectd/75/ansi/config.h index 5fcad72e711..c27da26a6f4 100644 --- a/keyboards/projectd/75/ansi/config.h +++ b/keyboards/projectd/75/ansi/config.h @@ -25,7 +25,6 @@ /* External spi flash */ #define EXTERNAL_FLASH_SPI_SLAVE_SELECT_PIN B14 -#define WEAR_LEVELING_BACKING_SIZE (4 * 1024) /* SPI Config for LED Driver */ #define SPI_DRIVER SPIDQ diff --git a/keyboards/projectd/75/ansi/info.json b/keyboards/projectd/75/ansi/info.json index daf94202e06..0e137de614b 100644 --- a/keyboards/projectd/75/ansi/info.json +++ b/keyboards/projectd/75/ansi/info.json @@ -6,6 +6,13 @@ "bootmagic": { "matrix": [1, 3] }, + "eeprom": { + "driver": "wear_leveling", + "wear_leveling": { + "driver": "spi_flash", + "backing_size": 4096 + } + }, "diode_direction": "COL2ROW", "dynamic_keymap": { "layer_count": 10 @@ -176,9 +183,6 @@ "pid": "0x000F", "vid": "0x3233" }, - "eeprom": { - "driver": "wear_leveling" - }, "layouts": { "LAYOUT": { "layout": [ diff --git a/keyboards/projectd/75/ansi/rules.mk b/keyboards/projectd/75/ansi/rules.mk index 002458405ee..6e7633bfe01 100644 --- a/keyboards/projectd/75/ansi/rules.mk +++ b/keyboards/projectd/75/ansi/rules.mk @@ -1 +1 @@ -WEAR_LEVELING_DRIVER = spi_flash +# This file intentionally left blank diff --git a/keyboards/vinhcatba/uncertainty/info.json b/keyboards/vinhcatba/uncertainty/info.json index fc0e69ad19f..5f35a144d83 100644 --- a/keyboards/vinhcatba/uncertainty/info.json +++ b/keyboards/vinhcatba/uncertainty/info.json @@ -4,6 +4,9 @@ "maintainer": "vinhcatba", "development_board": "blackpill_f401", "diode_direction": "COL2ROW", + "eeprom": { + "driver": "i2c" + }, "encoder": { "rotary": [ {"pin_a": "A13", "pin_b": "A14"} diff --git a/keyboards/vinhcatba/uncertainty/rules.mk b/keyboards/vinhcatba/uncertainty/rules.mk index 6255f652947..fd83e26c348 100644 --- a/keyboards/vinhcatba/uncertainty/rules.mk +++ b/keyboards/vinhcatba/uncertainty/rules.mk @@ -1,3 +1 @@ SRC += bongo.c -# using external i2c eeprom -EEPROM_DRIVER = i2c