flash/stm32l4x: remove stm32l4_part_info.default_flash_regs
authorTarek BOCHKATI <tarek.bouchkati@gmail.com>
Fri, 13 Aug 2021 23:09:29 +0000 (00:09 +0100)
committerOleksij Rempel <linux@rempel-privat.de>
Thu, 26 Aug 2021 06:37:38 +0000 (06:37 +0000)
commite7e46ba61e6d0bf06f65f352e8607db1dda83da1
treeff1def68990e81224aced56dc7f2e81f6debb9e1
parent1247eee4e6e55889b14bec8d81c4748767bb67b8
flash/stm32l4x: remove stm32l4_part_info.default_flash_regs

This struct element is replaced by the usage of F_HAS_L5_FLASH_REGS flag:
since over this driver stm32l4_flash_regs is the default register layout,
and the only exception is STM32L5 family,
so it's simpler to manage it using a flag.

Note: the same flag will be used with STM32U5 devices, as they have
the same registers layout, which explains the move of stm32l5_s_flash_regs
before the switch(device_id) in order to not re-write this for STM32U5.

Change-Id: I3b67a6f558d9350f609a22524012b6fceb7de7c2
Signed-off-by: Tarek BOCHKATI <tarek.bouchkati@gmail.com>
Reviewed-on: https://review.openocd.org/c/openocd/+/6435
Reviewed-by: Oleksij Rempel <linux@rempel-privat.de>
Tested-by: jenkins
src/flash/nor/stm32l4x.c
src/flash/nor/stm32l4x.h