samples: drivers: spi_flash: add support for arty_a7_arm_designstart_m3

Add support for running the JEDEC SPI NOR flash sample on the ARM
Cortex-M3 DesignStart FPGA reference implementation.

Special care is needed to avoid overwriting part of the FPGA
configuration bitstream, which is stored in the onboard QSPI flash.

Signed-off-by: Henrik Brix Andersen <henrik@brixandersen.dk>
This commit is contained in:
Henrik Brix Andersen 2020-08-30 12:43:42 +02:00 committed by Ioannis Glaropoulos
parent 80cb465a89
commit aab95f09f2
1 changed files with 2 additions and 1 deletions

View File

@ -25,7 +25,8 @@
#if defined(CONFIG_BOARD_ADAFRUIT_FEATHER_STM32F405)
#define FLASH_TEST_REGION_OFFSET 0xf000
#elif defined(CONFIG_BOARD_ARTY_A7_ARM_DESIGNSTART_M1)
#elif defined(CONFIG_BOARD_ARTY_A7_ARM_DESIGNSTART_M1) || \
defined(CONFIG_BOARD_ARTY_A7_ARM_DESIGNSTART_M3)
/* The FPGA bitstream is stored in the lower 536 sectors of the flash. */
#define FLASH_TEST_REGION_OFFSET \
DT_REG_SIZE(DT_NODE_BY_FIXED_PARTITION_LABEL(fpga_bitstream))