From d4a2c400d16f1ba563b55fe4c72ebe6df7b32ff5 Mon Sep 17 00:00:00 2001 From: Tom Rini Date: Thu, 24 Mar 2022 17:18:04 -0400 Subject: [PATCH] Convert CONFIG_NORFLASH_PS32BIT to Kconfig This converts the following to Kconfig: CONFIG_NORFLASH_PS32BIT Note that we also attempt to correct the behavior of the code here, which had been testing for "NORFLASH_PS32BIT" which would never be set, instead check for the now set "CONFIG_NORFLASH_PS32BIT", which results in some behavior change. Cc: TsiChung Liew Signed-off-by: Tom Rini --- board/freescale/m5235evb/Kconfig | 3 +++ configs/M5235EVB_Flash32_defconfig | 2 +- include/configs/M5235EVB.h | 4 ++-- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/board/freescale/m5235evb/Kconfig b/board/freescale/m5235evb/Kconfig index fc83419..f0d4c8c 100644 --- a/board/freescale/m5235evb/Kconfig +++ b/board/freescale/m5235evb/Kconfig @@ -12,4 +12,7 @@ config SYS_VENDOR config SYS_CONFIG_NAME default "M5235EVB" +config NORFLASH_PS32BIT + bool "Board has 32bit CFI flash" + endif diff --git a/configs/M5235EVB_Flash32_defconfig b/configs/M5235EVB_Flash32_defconfig index 8d43b45..f0077b6 100644 --- a/configs/M5235EVB_Flash32_defconfig +++ b/configs/M5235EVB_Flash32_defconfig @@ -5,9 +5,9 @@ CONFIG_ENV_SIZE=0x2000 CONFIG_ENV_SECT_SIZE=0x2000 CONFIG_DEFAULT_DEVICE_TREE="M5235EVB_Flash32" CONFIG_TARGET_M5235EVB=y +CONFIG_NORFLASH_PS32BIT=y CONFIG_MCFTMR=y CONFIG_SYS_LOAD_ADDR=0x20000 -CONFIG_SYS_EXTRA_OPTIONS="NORFLASH_PS32BIT" CONFIG_BOOTDELAY=1 # CONFIG_DISPLAY_BOARDINFO is not set # CONFIG_CMDLINE_EDITING is not set diff --git a/include/configs/M5235EVB.h b/include/configs/M5235EVB.h index e2f3367..625fa01 100644 --- a/include/configs/M5235EVB.h +++ b/include/configs/M5235EVB.h @@ -105,7 +105,7 @@ */ #ifdef CONFIG_SYS_FLASH_CFI # define CONFIG_SYS_FLASH_SIZE 0x800000 /* Max size that the board might have */ -#ifdef NORFLASH_PS32BIT +#ifdef CONFIG_NORFLASH_PS32BIT # define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_32BIT #else # define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_16BIT @@ -152,7 +152,7 @@ * CS6 - Available * CS7 - Available */ -#ifdef NORFLASH_PS32BIT +#ifdef CONFIG_NORFLASH_PS32BIT # define CONFIG_SYS_CS0_BASE 0xFFC00000 # define CONFIG_SYS_CS0_MASK 0x003f0001 # define CONFIG_SYS_CS0_CTRL 0x00001D00 -- 2.7.4