spi: Kconfig: Enable SPI_SUNXI for SUNXI
Subsystems (4)
PATCH v3 1/3 spi: Kconfig: Enable SPI_SUNXI for SUNXI
SPI_SUNXI driver is fully dm-aware and the Allwinner architecture kconfig would have logic to enable the DM_SPI. So, select default spi sunxi driver for sunxi architecture.
---
Changes for v3:
- none
drivers/spi/Kconfig | 1 + 1 file changed, 1 insertion(+)
drivers/spi/Kconfig +1 -0
@@ -260,6 +260,7 @@ config SPI_SIFIVE config SPI_SUNXI bool "Allwinner SoC SPI controllers" + default ARCH_SUNXI help Enable the Allwinner SoC SPi controller driver.
Signature · 1 line
2.18.0.321.gffc6fa0e3
PATCH v3 2/3 arm: sunxi: Enable SPI/SPI-FLASH support for A64
SPI is available in Allwinner A64 SoC, so enable it globally in Kconfig.
- CONFIG_SPI
- CONFIG_DM_SPI
- CONFIG_DM_SPI_FLASH
---
Changes for v3:
- Move to kconfig from defconfig
arch/arm/mach-sunxi/Kconfig | 3 +++ 1 file changed, 3 insertions(+)
arch/arm/mach-sunxi/Kconfig +3 -0
@@ -275,7 +275,10 @@ config MACH_SUN9I config MACH_SUN50I bool "sun50i (Allwinner A64)" select ARM64 + select SPI select DM_I2C + select DM_SPI if SPI + select DM_SPI_FLASH select PHY_SUN4I_USB select SUN6I_PRCM select SUNXI_DE2
Signature · 1 line
2.18.0.321.gffc6fa0e3
PATCH v3 3/3 configs: sopine-baseboard: Enable SPI-FLASH
In reply to Jagan TekiSoPine has winbond SPI-FLASH, so enable the same in defconfig and add aliases for spi0 in -u-boot.dtsi
---
Changes for v3:
- none
arch/arm/dts/sun50i-a64-sopine-baseboard-u-boot.dtsi | 12 ++++++++++++ configs/sopine_baseboard_defconfig | 1 + 2 files changed, 13 insertions(+) create mode 100644 arch/arm/dts/sun50i-a64-sopine-baseboard-u-boot.dtsi
arch/arm/dts/sun50i-a64-sopine-baseboard-u-boot.dtsi new file +12 -0
@@ -0,0 +1,12 @@ +// SPDX-License-Identifier: GPL-2.0+ +/* + * Copyright (C) 2018 Jagan Teki <[email protected]> + */ + +#include "sunxi-u-boot.dtsi" + +/ { + aliases { + spi0 = &spi0; + }; +};
configs/sopine_baseboard_defconfig +1 -0
@@ -10,6 +10,7 @@ CONFIG_DRAM_ZQ=3881949 CONFIG_MMC0_CD_PIN="" CONFIG_MMC_SUNXI_SLOT_EXTRA=2 CONFIG_SPL_SPI_SUNXI=y +CONFIG_SPI_FLASH_WINBOND=y # CONFIG_SYS_MALLOC_CLEAR_ON_INIT is not set CONFIG_USE_PREBOOT=y CONFIG_SYS_SPI_U_BOOT_OFFS=0x8000
Signature · 1 line
2.18.0.321.gffc6fa0e3
PATCH v3 3/3 configs: sopine-baseboard: Enable SPI-FLASH
Quoted 37 lines · Jagan Teki
SoPine has winbond SPI-FLASH, so enable the same in defconfig and add aliases for spi0 in
-u-boot.dtsiSigned-off-by Jagan Teki <[email protected]>---
Changes for v3:
- nonearch/arm/dts/sun50i-a64-sopine-baseboard-u-boot.dtsi | 12 ++++++++++++ configs/sopine_baseboard_defconfig | 1 + 2 files changed, 13 insertions(+) create mode 100644 arch/arm/dts/sun50i-a64-sopine-baseboard-u-boot.dtsiarch/arm/dts/sun50i-a64-sopine-baseboard-u-boot.dtsi new file +12
-0@@ -0,0 +1,12 @@ +// SPDX-License-Identifier: GPL-2.0+ +/* + * Copyright (C) 2018 Jagan Teki <[email protected]> + */ + +#include "sunxi-u-boot.dtsi" + +/ { + aliases { + spi0 = &spi0; + }; +};configs/sopine_baseboard_defconfig +0
-0
configs/sopine_baseboard_defconfig CONFIG_DRAM_ZQ=3881949 · line 13
Quoted 4 lines
configs/sopine_baseboard_defconfig +1
-0@@ -10,6 +10,7 @@ CONFIG_DRAM_ZQ=3881949 CONFIG_MMC0_CD_PIN="" CONFIG_MMC_SUNXI_SLOT_EXTRA=2 CONFIG_SPL_SPI_SUNXI=y +CONFIG_SPI_FLASH_WINBOND=y
You also need to set CONFIG_SPI_FLASH since it's not set by default and CONFIG_SPI_FLASH_WINBOND depends on CONFIG_SPI_FLASH.
Quoted 10 lines
configs/sopine_baseboard_defconfig +0
-1# CONFIG_SYS_MALLOC_CLEAR_ON_INIT is not set CONFIG_USE_PREBOOT=y CONFIG_SYS_SPI_U_BOOT_OFFS=0x8000 --2.18.0.321.gffc6fa0e3
_______________________________________________
U-Boot mailing list
U-Boot at lists.denx.de
https://lists.denx.de/listinfo/u-boot
PATCH v3 3/3 configs: sopine-baseboard: Enable SPI-FLASH
Quoted 38 lines · Vasily Khoruzhick
Quoted 36 lines · Jagan Teki
SoPine has winbond SPI-FLASH, so enable the same in defconfig and add aliases for spi0 in
-u-boot.dtsiSigned-off-by Jagan Teki <[email protected]>---
Changes for v3:
- nonearch/arm/dts/sun50i-a64-sopine-baseboard-u-boot.dtsi | 12 ++++++++++++ configs/sopine_baseboard_defconfig | 1 + 2 files changed, 13 insertions(+) create mode 100644 arch/arm/dts/sun50i-a64-sopine-baseboard-u-boot.dtsiarch/arm/dts/sun50i-a64-sopine-baseboard-u-boot.dtsi new file +12
-0@@ -0,0 +1,12 @@ +// SPDX-License-Identifier: GPL-2.0+ +/* + * Copyright (C) 2018 Jagan Teki <[email protected]> + */ + +#include "sunxi-u-boot.dtsi" + +/ { + aliases { + spi0 = &spi0; + }; +};configs/sopine_baseboard_defconfig +0
-0
Quoted 8 lines
configs/sopine_baseboard_defconfig CONFIG_DRAM_ZQ=3881949 · line 13
Quoted 5 lines
configs/sopine_baseboard_defconfig +1
-0@@ -10,6 +10,7 @@ CONFIG_DRAM_ZQ=3881949 CONFIG_MMC0_CD_PIN="" CONFIG_MMC_SUNXI_SLOT_EXTRA=2 CONFIG_SPL_SPI_SUNXI=y +CONFIG_SPI_FLASH_WINBOND=yYou also need to set
CONFIG_SPI_FLASHsince it's not set by default andCONFIG_SPI_FLASH_WINBONDdepends onCONFIG_SPI_FLASH.
SPI_FLASH would select if DM_SPI_FLASH set. we have a patch on ML.
Winbond seems to boards specific flash, so I've mark it to board config itself.