Skip to content

Commit cf849d8

Browse files
committed
stm32/boards: Enable MICROPY_HW_SPIFLASH_ENABLE_CACHE on VCC_GND boards.
Because these boards use the SPI flash cache in their bdev.c configuration. Signed-off-by: Damien George <[email protected]>
1 parent 71e3538 commit cf849d8

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

ports/stm32/boards/VCC_GND_F407VE/mpconfigboard.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -132,6 +132,7 @@ void VCC_GND_F407VE_board_early_init(void);
132132

133133
extern const struct _mp_spiflash_config_t spiflash_config;
134134
extern struct _spi_bdev_t spi_bdev;
135+
#define MICROPY_HW_SPIFLASH_ENABLE_CACHE (1)
135136
#define MICROPY_HW_BDEV_IOCTL(op, arg) ( \
136137
(op) == BDEV_IOCTL_NUM_BLOCKS ? (MICROPY_HW_SPIFLASH_SIZE_BITS / 8 / FLASH_BLOCK_SIZE) : \
137138
(op) == BDEV_IOCTL_INIT ? spi_bdev_ioctl(&spi_bdev, (op), (uint32_t)&spiflash_config) : \

ports/stm32/boards/VCC_GND_F407ZG/mpconfigboard.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -140,6 +140,7 @@ void VCC_GND_F407ZG_board_early_init(void);
140140

141141
extern const struct _mp_spiflash_config_t spiflash_config;
142142
extern struct _spi_bdev_t spi_bdev;
143+
#define MICROPY_HW_SPIFLASH_ENABLE_CACHE (1)
143144
#define MICROPY_HW_BDEV_IOCTL(op, arg) ( \
144145
(op) == BDEV_IOCTL_NUM_BLOCKS ? (MICROPY_HW_SPIFLASH_SIZE_BITS / 8 / FLASH_BLOCK_SIZE) : \
145146
(op) == BDEV_IOCTL_INIT ? spi_bdev_ioctl(&spi_bdev, (op), (uint32_t)&spiflash_config) : \

0 commit comments

Comments
 (0)