From: Marek Vasut Date: Tue, 13 Feb 2018 20:34:03 +0000 (+0100) Subject: ARM: rmobile: Enable RPC QSPI on R8A77970 V3M Eagle X-Git-Url: http://git.dujemihanovic.xyz/?a=commitdiff_plain;h=5e7f63db92d7313dcf0ef7aa4c3c3c4c9b43a4fc;p=u-boot.git ARM: rmobile: Enable RPC QSPI on R8A77970 V3M Eagle Enable the RPC QSPI driver on R8A77970 V3M Eagle and configure the environment layout to match that used by old U-Boot. Signed-off-by: Marek Vasut Cc: Nobuhiro Iwamatsu --- diff --git a/arch/arm/dts/r8a77970-eagle.dts b/arch/arm/dts/r8a77970-eagle.dts index cb76c89b57..c051cddb25 100644 --- a/arch/arm/dts/r8a77970-eagle.dts +++ b/arch/arm/dts/r8a77970-eagle.dts @@ -17,6 +17,7 @@ aliases { serial0 = &scif0; ethernet0 = &avb; + spi0 = &rpc; }; chosen { @@ -59,6 +60,25 @@ }; }; +&rpc { + num-cs = <1>; + status = "okay"; + spi-max-frequency = <50000000>; + #address-cells = <1>; + #size-cells = <0>; + + flash0: spi-flash@0 { + #address-cells = <1>; + #size-cells = <1>; + compatible = "s25fs512s", "spi-flash", "jedec,spi-nor"; + spi-max-frequency = <50000000>; + spi-tx-bus-width = <1>; + spi-rx-bus-width = <1>; + reg = <0>; + status = "okay"; + }; +}; + &scif0 { pinctrl-0 = <&scif0_pins>; pinctrl-names = "default"; diff --git a/configs/r8a77970_eagle_defconfig b/configs/r8a77970_eagle_defconfig index eb8666abca..65cfc91c80 100644 --- a/configs/r8a77970_eagle_defconfig +++ b/configs/r8a77970_eagle_defconfig @@ -18,6 +18,8 @@ CONFIG_CMD_BOOTZ=y CONFIG_CMD_GPIO=y CONFIG_CMD_I2C=y CONFIG_CMD_MMC=y +CONFIG_CMD_SF=y +CONFIG_CMD_SPI=y CONFIG_CMD_USB=y CONFIG_CMD_DHCP=y CONFIG_CMD_MII=y @@ -28,6 +30,7 @@ CONFIG_CMD_EXT4_WRITE=y CONFIG_CMD_FAT=y CONFIG_CMD_FS_GENERIC=y CONFIG_OF_CONTROL=y +CONFIG_ENV_IS_IN_SPI_FLASH=y CONFIG_REGMAP=y CONFIG_SYSCON=y CONFIG_CLK=y @@ -41,6 +44,10 @@ CONFIG_MMC_IO_VOLTAGE=y CONFIG_MMC_UHS_SUPPORT=y CONFIG_MMC_HS200_SUPPORT=y CONFIG_RENESAS_SDHI=y +CONFIG_DM_SPI_FLASH=y +CONFIG_SPI_FLASH=y +CONFIG_SPI_FLASH_BAR=y +CONFIG_SPI_FLASH_SPANSION=y CONFIG_PHY_MICREL=y CONFIG_PHY_MICREL_KSZ90X1=y CONFIG_DM_ETH=y @@ -52,6 +59,8 @@ CONFIG_DM_REGULATOR=y CONFIG_DM_REGULATOR_FIXED=y CONFIG_DM_REGULATOR_GPIO=y CONFIG_SCIF_CONSOLE=y +CONFIG_DM_SPI=y +CONFIG_RENESAS_RPC_SPI=y CONFIG_USB=y CONFIG_DM_USB=y CONFIG_USB_XHCI_HCD=y diff --git a/include/configs/eagle.h b/include/configs/eagle.h index 2ef0c7a777..d2edd56130 100644 --- a/include/configs/eagle.h +++ b/include/configs/eagle.h @@ -19,6 +19,12 @@ #define CONFIG_BITBANGMII #define CONFIG_BITBANGMII_MULTI +/* Environment compatibility */ +#undef CONFIG_ENV_SIZE_REDUND +#undef CONFIG_ENV_SECT_SIZE +#define CONFIG_ENV_SECT_SIZE (256 * 1024) +#define CONFIG_ENV_OFFSET 0x700000 + /* Board Clock */ /* XTAL_CLK : 33.33MHz */ #define CONFIG_SYS_CLK_FREQ 33333333u