[U-Boot] [PATCH v2 05/10] fastboot: rockchip: Select FASTBOOT_FLASH[_MMC_DEV]

Kever Yang kever.yang at rock-chips.com
Sat Nov 23 14:21:14 UTC 2019


On 2019/11/19 下午4:26, Jagan Teki wrote:
> Select CONFIG_FASTBOOT_FLASH, CONFIG_FASTBOOT_FLASH_MMC_DEV
> for rockchip SoC plaforms in fastboot Kconfig file instead
> of defined it in board defconfig.
>
> This eventually drop the explicit configs defined in
> supporting board defconfig files.
>
> Tested-by: Levin Du <djw at t-chip.com.cn>
> Signed-off-by: Jagan Teki <jagan at amarulasolutions.com>

Reviewed-by: Kever Yang <kever.yang at rock-chips.com>

Thanks,
- Kever
> ---
>   configs/evb-rk3036_defconfig      | 2 --
>   configs/evb-rk3128_defconfig      | 2 --
>   configs/evb-rk3229_defconfig      | 2 --
>   configs/evb-rk3288_defconfig      | 2 --
>   configs/evb-rk3328_defconfig      | 2 --
>   configs/firefly-rk3288_defconfig  | 2 --
>   configs/kylin-rk3036_defconfig    | 2 --
>   configs/miqi-rk3288_defconfig     | 2 --
>   configs/phycore-rk3288_defconfig  | 2 --
>   configs/popmetal-rk3288_defconfig | 2 --
>   configs/rock64-rk3328_defconfig   | 2 --
>   configs/tinker-rk3288_defconfig   | 2 --
>   configs/tinker-s-rk3288_defconfig | 2 --
>   drivers/fastboot/Kconfig          | 4 +++-
>   14 files changed, 3 insertions(+), 27 deletions(-)
>
> diff --git a/configs/evb-rk3036_defconfig b/configs/evb-rk3036_defconfig
> index 79e413145f..4bed28f102 100644
> --- a/configs/evb-rk3036_defconfig
> +++ b/configs/evb-rk3036_defconfig
> @@ -35,8 +35,6 @@ CONFIG_REGMAP=y
>   CONFIG_SYSCON=y
>   # CONFIG_SPL_BLK is not set
>   CONFIG_CLK=y
> -CONFIG_FASTBOOT_FLASH=y
> -CONFIG_FASTBOOT_FLASH_MMC_DEV=0
>   CONFIG_FASTBOOT_CMD_OEM_FORMAT=y
>   CONFIG_ROCKCHIP_GPIO=y
>   CONFIG_SYS_I2C_ROCKCHIP=y
> diff --git a/configs/evb-rk3128_defconfig b/configs/evb-rk3128_defconfig
> index cb3c5372aa..bf91c642dd 100644
> --- a/configs/evb-rk3128_defconfig
> +++ b/configs/evb-rk3128_defconfig
> @@ -23,8 +23,6 @@ CONFIG_SYSCON=y
>   CONFIG_CLK=y
>   CONFIG_FASTBOOT_BUF_ADDR=0x60800800
>   CONFIG_FASTBOOT_BUF_SIZE=0x04000000
> -CONFIG_FASTBOOT_FLASH=y
> -CONFIG_FASTBOOT_FLASH_MMC_DEV=0
>   CONFIG_FASTBOOT_CMD_OEM_FORMAT=y
>   CONFIG_ROCKCHIP_GPIO=y
>   CONFIG_SYS_I2C_ROCKCHIP=y
> diff --git a/configs/evb-rk3229_defconfig b/configs/evb-rk3229_defconfig
> index 8d7d11c3e8..cdf28154f8 100644
> --- a/configs/evb-rk3229_defconfig
> +++ b/configs/evb-rk3229_defconfig
> @@ -44,8 +44,6 @@ CONFIG_CLK=y
>   CONFIG_SPL_CLK=y
>   CONFIG_TPL_CLK=y
>   CONFIG_FASTBOOT_BUF_SIZE=0x04000000
> -CONFIG_FASTBOOT_FLASH=y
> -CONFIG_FASTBOOT_FLASH_MMC_DEV=0
>   CONFIG_FASTBOOT_CMD_OEM_FORMAT=y
>   CONFIG_ROCKCHIP_GPIO=y
>   CONFIG_SYS_I2C_ROCKCHIP=y
> diff --git a/configs/evb-rk3288_defconfig b/configs/evb-rk3288_defconfig
> index db7e6fa7b1..833b0b6a6d 100644
> --- a/configs/evb-rk3288_defconfig
> +++ b/configs/evb-rk3288_defconfig
> @@ -43,8 +43,6 @@ CONFIG_SYSCON=y
>   CONFIG_SPL_SYSCON=y
>   CONFIG_CLK=y
>   CONFIG_SPL_CLK=y
> -CONFIG_FASTBOOT_FLASH=y
> -CONFIG_FASTBOOT_FLASH_MMC_DEV=0
>   CONFIG_FASTBOOT_CMD_OEM_FORMAT=y
>   CONFIG_ROCKCHIP_GPIO=y
>   CONFIG_SYS_I2C_ROCKCHIP=y
> diff --git a/configs/evb-rk3328_defconfig b/configs/evb-rk3328_defconfig
> index 0293546b04..74b7295e62 100644
> --- a/configs/evb-rk3328_defconfig
> +++ b/configs/evb-rk3328_defconfig
> @@ -46,8 +46,6 @@ CONFIG_TPL_SYSCON=y
>   CONFIG_CLK=y
>   CONFIG_SPL_CLK=y
>   CONFIG_FASTBOOT_BUF_ADDR=0x800800
> -CONFIG_FASTBOOT_FLASH=y
> -CONFIG_FASTBOOT_FLASH_MMC_DEV=1
>   CONFIG_FASTBOOT_CMD_OEM_FORMAT=y
>   CONFIG_ROCKCHIP_GPIO=y
>   CONFIG_SYS_I2C_ROCKCHIP=y
> diff --git a/configs/firefly-rk3288_defconfig b/configs/firefly-rk3288_defconfig
> index 6efc5735f9..178029cc47 100644
> --- a/configs/firefly-rk3288_defconfig
> +++ b/configs/firefly-rk3288_defconfig
> @@ -44,8 +44,6 @@ CONFIG_SPL_SYSCON=y
>   # CONFIG_SPL_SIMPLE_BUS is not set
>   CONFIG_CLK=y
>   CONFIG_SPL_CLK=y
> -CONFIG_FASTBOOT_FLASH=y
> -CONFIG_FASTBOOT_FLASH_MMC_DEV=0
>   CONFIG_FASTBOOT_CMD_OEM_FORMAT=y
>   CONFIG_ROCKCHIP_GPIO=y
>   CONFIG_SYS_I2C_ROCKCHIP=y
> diff --git a/configs/kylin-rk3036_defconfig b/configs/kylin-rk3036_defconfig
> index c1607e52fb..6c13c4c080 100644
> --- a/configs/kylin-rk3036_defconfig
> +++ b/configs/kylin-rk3036_defconfig
> @@ -37,8 +37,6 @@ CONFIG_REGMAP=y
>   CONFIG_SYSCON=y
>   # CONFIG_SPL_BLK is not set
>   CONFIG_CLK=y
> -CONFIG_FASTBOOT_FLASH=y
> -CONFIG_FASTBOOT_FLASH_MMC_DEV=0
>   CONFIG_FASTBOOT_CMD_OEM_FORMAT=y
>   CONFIG_ROCKCHIP_GPIO=y
>   CONFIG_SYS_I2C_ROCKCHIP=y
> diff --git a/configs/miqi-rk3288_defconfig b/configs/miqi-rk3288_defconfig
> index 4590e38ad3..488cc54203 100644
> --- a/configs/miqi-rk3288_defconfig
> +++ b/configs/miqi-rk3288_defconfig
> @@ -45,8 +45,6 @@ CONFIG_SPL_SYSCON=y
>   # CONFIG_SPL_SIMPLE_BUS is not set
>   CONFIG_CLK=y
>   CONFIG_SPL_CLK=y
> -CONFIG_FASTBOOT_FLASH=y
> -CONFIG_FASTBOOT_FLASH_MMC_DEV=0
>   CONFIG_FASTBOOT_CMD_OEM_FORMAT=y
>   CONFIG_ROCKCHIP_GPIO=y
>   CONFIG_SYS_I2C_ROCKCHIP=y
> diff --git a/configs/phycore-rk3288_defconfig b/configs/phycore-rk3288_defconfig
> index 51bd8adcbc..75de1d68e5 100644
> --- a/configs/phycore-rk3288_defconfig
> +++ b/configs/phycore-rk3288_defconfig
> @@ -47,8 +47,6 @@ CONFIG_SPL_SYSCON=y
>   # CONFIG_SPL_SIMPLE_BUS is not set
>   CONFIG_CLK=y
>   CONFIG_SPL_CLK=y
> -CONFIG_FASTBOOT_FLASH=y
> -CONFIG_FASTBOOT_FLASH_MMC_DEV=0
>   CONFIG_FASTBOOT_CMD_OEM_FORMAT=y
>   CONFIG_ROCKCHIP_GPIO=y
>   CONFIG_SYS_I2C_ROCKCHIP=y
> diff --git a/configs/popmetal-rk3288_defconfig b/configs/popmetal-rk3288_defconfig
> index 8cc55bdbe0..320f34bd04 100644
> --- a/configs/popmetal-rk3288_defconfig
> +++ b/configs/popmetal-rk3288_defconfig
> @@ -45,8 +45,6 @@ CONFIG_SPL_SYSCON=y
>   # CONFIG_SPL_SIMPLE_BUS is not set
>   CONFIG_CLK=y
>   CONFIG_SPL_CLK=y
> -CONFIG_FASTBOOT_FLASH=y
> -CONFIG_FASTBOOT_FLASH_MMC_DEV=0
>   CONFIG_FASTBOOT_CMD_OEM_FORMAT=y
>   CONFIG_ROCKCHIP_GPIO=y
>   CONFIG_SYS_I2C_ROCKCHIP=y
> diff --git a/configs/rock64-rk3328_defconfig b/configs/rock64-rk3328_defconfig
> index 0dab5d7e54..73ca535ff8 100644
> --- a/configs/rock64-rk3328_defconfig
> +++ b/configs/rock64-rk3328_defconfig
> @@ -48,8 +48,6 @@ CONFIG_TPL_SYSCON=y
>   CONFIG_CLK=y
>   CONFIG_SPL_CLK=y
>   CONFIG_FASTBOOT_BUF_ADDR=0x800800
> -CONFIG_FASTBOOT_FLASH=y
> -CONFIG_FASTBOOT_FLASH_MMC_DEV=1
>   CONFIG_FASTBOOT_CMD_OEM_FORMAT=y
>   CONFIG_ROCKCHIP_GPIO=y
>   CONFIG_SYS_I2C_ROCKCHIP=y
> diff --git a/configs/tinker-rk3288_defconfig b/configs/tinker-rk3288_defconfig
> index c350c0d8ba..56fcbb94d3 100644
> --- a/configs/tinker-rk3288_defconfig
> +++ b/configs/tinker-rk3288_defconfig
> @@ -47,8 +47,6 @@ CONFIG_SPL_SYSCON=y
>   # CONFIG_SPL_SIMPLE_BUS is not set
>   CONFIG_CLK=y
>   CONFIG_SPL_CLK=y
> -CONFIG_FASTBOOT_FLASH=y
> -CONFIG_FASTBOOT_FLASH_MMC_DEV=0
>   CONFIG_FASTBOOT_CMD_OEM_FORMAT=y
>   CONFIG_ROCKCHIP_GPIO=y
>   CONFIG_SYS_I2C_ROCKCHIP=y
> diff --git a/configs/tinker-s-rk3288_defconfig b/configs/tinker-s-rk3288_defconfig
> index c016a264b2..458e1695a2 100644
> --- a/configs/tinker-s-rk3288_defconfig
> +++ b/configs/tinker-s-rk3288_defconfig
> @@ -52,8 +52,6 @@ CONFIG_SPL_SYSCON=y
>   # CONFIG_SPL_SIMPLE_BUS is not set
>   CONFIG_CLK=y
>   CONFIG_SPL_CLK=y
> -CONFIG_FASTBOOT_FLASH=y
> -CONFIG_FASTBOOT_FLASH_MMC_DEV=0
>   CONFIG_FASTBOOT_CMD_OEM_FORMAT=y
>   CONFIG_ROCKCHIP_GPIO=y
>   CONFIG_SYS_I2C_ROCKCHIP=y
> diff --git a/drivers/fastboot/Kconfig b/drivers/fastboot/Kconfig
> index d63ecdd27e..34864ca613 100644
> --- a/drivers/fastboot/Kconfig
> +++ b/drivers/fastboot/Kconfig
> @@ -64,7 +64,7 @@ config FASTBOOT_USB_DEV
>   
>   config FASTBOOT_FLASH
>   	bool "Enable FASTBOOT FLASH command"
> -	default y if ARCH_SUNXI
> +	default y if ARCH_SUNXI || ARCH_ROCKCHIP
>   	depends on MMC || (NAND && CMD_MTDPARTS)
>   	select IMAGE_SPARSE
>   	help
> @@ -89,6 +89,8 @@ endchoice
>   config FASTBOOT_FLASH_MMC_DEV
>   	int "Define FASTBOOT MMC FLASH default device"
>   	depends on FASTBOOT_FLASH_MMC
> +	default 1 if ROCKCHIP_RK3328
> +	default 0 if ARCH_ROCKCHIP
>   	default 0 if ARCH_SUNXI && MMC_SUNXI_SLOT_EXTRA = -1
>   	default 1 if ARCH_SUNXI && MMC_SUNXI_SLOT_EXTRA != -1
>   	help




More information about the U-Boot mailing list