Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sn32: eeprom updates #370

Merged
merged 3 commits into from
Jun 4, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 1 addition & 7 deletions builddefs/common_features.mk
Original file line number Diff line number Diff line change
Expand Up @@ -233,9 +233,6 @@ else
# Teensy EEPROM implementations
OPT_DEFS += -DEEPROM_KINETIS_FLEXRAM
SRC += eeprom_kinetis_flexram.c
else ifneq ($(filter $(MCU_SERIES),SN32F240B SN32F260),)
OPT_DEFS += -DEEPROM_DRIVER -DEEPROM_SN32_FLASH_EMULATED
SRC += eeprom_driver.c eeprom_sn32.c
else
# Fall back to transient, i.e. non-persistent
OPT_DEFS += -DEEPROM_DRIVER -DEEPROM_TRANSIENT
Expand All @@ -253,7 +250,7 @@ else
endif
endif

VALID_WEAR_LEVELING_DRIVER_TYPES := custom embedded_flash spi_flash rp2040_flash legacy sn32_flash
VALID_WEAR_LEVELING_DRIVER_TYPES := custom embedded_flash spi_flash rp2040_flash legacy
WEAR_LEVELING_DRIVER ?= none
ifneq ($(strip $(WEAR_LEVELING_DRIVER)),none)
ifeq ($(filter $(WEAR_LEVELING_DRIVER),$(VALID_WEAR_LEVELING_DRIVER_TYPES)),)
Expand Down Expand Up @@ -281,9 +278,6 @@ ifneq ($(strip $(WEAR_LEVELING_DRIVER)),none)
COMMON_VPATH += $(PLATFORM_PATH)/$(PLATFORM_KEY)/$(DRIVER_DIR)/flash
SRC += legacy_flash_ops.c wear_leveling_legacy.c
POST_CONFIG_H += $(PLATFORM_PATH)/$(PLATFORM_KEY)/$(DRIVER_DIR)/wear_leveling/wear_leveling_legacy_config.h
else ifeq ($(strip $(WEAR_LEVELING_DRIVER)), sn32_flash)
SRC += wear_leveling_sn32_flash.c
POST_CONFIG_H += $(PLATFORM_PATH)/$(PLATFORM_KEY)/$(DRIVER_DIR)/wear_leveling/wear_leveling_sn32_flash_config.h
endif
endif
endif
Expand Down
3 changes: 3 additions & 0 deletions platforms/chibios/chibios_config.h
Original file line number Diff line number Diff line change
Expand Up @@ -173,4 +173,7 @@

#if defined(SN32F2)
# define CPU_CLOCK SN32_HCLK
# ifndef WEAR_LEVELING_EFL_OMIT_LAST_SECTOR_COUNT
# define WEAR_LEVELING_EFL_OMIT_LAST_SECTOR_COUNT 1
# endif
#endif
164 changes: 0 additions & 164 deletions platforms/chibios/drivers/eeprom/eeprom_sn32.c

This file was deleted.

30 changes: 0 additions & 30 deletions platforms/chibios/drivers/eeprom/eeprom_sn32.h

This file was deleted.

59 changes: 0 additions & 59 deletions platforms/chibios/drivers/eeprom/eeprom_sn32_defs.h

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@
# define BACKING_STORE_WRITE_SIZE 4 // from hal_efl_lld.c
# elif defined(QMK_MCU_FAMILY_WB32)
# define BACKING_STORE_WRITE_SIZE 8 // from hal_efl_lld.c
# elif defined(QMK_MCU_FAMILY_SN32)
# define BACKING_STORE_WRITE_SIZE 4 // from hal_efl_lld.c
# elif defined(QMK_MCU_FAMILY_STM32)
# if defined(STM32_FLASH_LINE_SIZE) // from some family's stm32_registry.h file
# define BACKING_STORE_WRITE_SIZE (STM32_FLASH_LINE_SIZE)
Expand Down
56 changes: 0 additions & 56 deletions platforms/chibios/drivers/wear_leveling/wear_leveling_sn32_flash.c

This file was deleted.

Loading