ARM: dts: at91: sama5d2_icp: add QSPI1 device
Subsystems (2)
PATCH 1/4 ARM: dts: at91: sama5d2_icp: add QSPI1 device
From: Mihai Sain <[email protected]>
Add support for sst26vf064b 64Mbit qspi-flash that is present on sama5d2_icp board.
--- arch/arm/dts/at91-sama5d2_icp-u-boot.dtsi | 16 +++++++++++++ arch/arm/dts/at91-sama5d2_icp.dts | 29 +++++++++++++++++++++++ 2 files changed, 45 insertions(+)
arch/arm/dts/at91-sama5d2_icp-u-boot.dtsi +16 -0
@@ -28,3 +28,19 @@ &pinctrl_mikrobus1_uart { u-boot,dm-pre-reloc; }; + +&pinctrl_qspi1_sck_cs_default { + u-boot,dm-pre-reloc; +}; + +&pinctrl_qspi1_dat_default { + u-boot,dm-pre-reloc; +}; + +&qspi1 { + u-boot,dm-pre-reloc; + + flash@0 { + u-boot,dm-pre-reloc; + }; +};
arch/arm/dts/at91-sama5d2_icp.dts +29 -0
@@ -33,6 +33,21 @@ }; apb { + + qspi1: spi@f0024000 { + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_qspi1_sck_cs_default &pinctrl_qspi1_dat_default>; + status = "okay"; + + flash@0 { + compatible = "jedec,spi-nor"; + reg = <0>; + spi-max-frequency = <83000000>; + spi-rx-bus-width = <4>; + spi-tx-bus-width = <4>; + }; + }; + uart0: serial@f801c000 { /* mikrobus1 uart */ pinctrl-names = "default"; pinctrl-0 = <&pinctrl_mikrobus1_uart>;
@@ -109,6 +124,20 @@ bias-pull-up; }; + pinctrl_qspi1_sck_cs_default: qspi1_sck_cs_default { + pinmux = <PIN_PA6__QSPI1_SCK>, + <PIN_PA11__QSPI1_CS>; + bias-disable; + }; + + pinctrl_qspi1_dat_default: qspi1_dat_default { + pinmux = <PIN_PA7__QSPI1_IO0>, + <PIN_PA8__QSPI1_IO1>, + <PIN_PA9__QSPI1_IO2>, + <PIN_PA10__QSPI1_IO3>; + bias-pull-up; + }; + pinctrl_sdmmc0_default: sdmmc0_default { pinmux = <PIN_PA1__SDMMC0_CMD>, <PIN_PA2__SDMMC0_DAT0>,
Signature · 1 line
2.25.1
PATCH 2/4 ARM: dts: at91: sama5d2_icp: cosmetic arrangement of the nodes
Reorder the nodes following the kernel rules: nodes in a range are sorted by ascending bus address, and when referenced by phandle, are ordered alphabetically.
--- arch/arm/dts/at91-sama5d2_icp-u-boot.dtsi | 23 +++++++++++---------- arch/arm/dts/at91-sama5d2_icp.dts | 25 ++++++++++++----------- 2 files changed, 25 insertions(+), 23 deletions(-)
arch/arm/dts/at91-sama5d2_icp-u-boot.dtsi +12 -11
@@ -13,34 +13,35 @@ }; }; -&sdmmc0 { +&pinctrl_mikrobus1_uart { u-boot,dm-pre-reloc; }; -&uart0 { /* mikrobus1 uart */ +&pinctrl_qspi1_sck_cs_default { u-boot,dm-pre-reloc; }; -&pinctrl_sdmmc0_default { +&pinctrl_qspi1_dat_default { u-boot,dm-pre-reloc; }; -&pinctrl_mikrobus1_uart { +&pinctrl_sdmmc0_default { u-boot,dm-pre-reloc; }; -&pinctrl_qspi1_sck_cs_default { +&qspi1 { u-boot,dm-pre-reloc; + + flash@0 { + u-boot,dm-pre-reloc; + }; }; -&pinctrl_qspi1_dat_default { +&sdmmc0 { u-boot,dm-pre-reloc; }; -&qspi1 { +&uart0 { /* mikrobus1 uart */ u-boot,dm-pre-reloc; - - flash@0 { - u-boot,dm-pre-reloc; - }; }; +
arch/arm/dts/at91-sama5d2_icp.dts +13 -12
@@ -1,7 +1,7 @@ // SPDX-License-Identifier: GPL-2.0+ OR MIT /* * at91-sama5d2_icp.dts - Device Tree file for SAMA5D2 ICP board - * SAMA5D2 Industrial Connectivity Board + * SAMA5D2 Industrial Connectivity Platform * * Copyright (c) 2018, Microchip Technology Inc. * 2018, Eugen Hristev <[email protected]>
@@ -48,16 +48,16 @@ }; }; - uart0: serial@f801c000 { /* mikrobus1 uart */ + macb0: ethernet@f8008000 { pinctrl-names = "default"; - pinctrl-0 = <&pinctrl_mikrobus1_uart>; + pinctrl-0 = <&pinctrl_macb0_rmii &pinctrl_macb0_phy_irq &pinctrl_macb0_rst>; + phy-mode = "internal"; status = "okay"; }; - macb0: ethernet@f8008000 { + uart0: serial@f801c000 { /* mikrobus1 uart */ pinctrl-names = "default"; - pinctrl-0 = <&pinctrl_macb0_rmii &pinctrl_macb0_phy_irq &pinctrl_macb0_rst>; - phy-mode = "internal"; + pinctrl-0 = <&pinctrl_mikrobus1_uart>; status = "okay"; };
@@ -85,6 +85,7 @@ pagesize = <16>; }; }; + pioA: gpio@fc038000 { status = "okay"; pinctrl {
@@ -124,6 +125,12 @@ bias-pull-up; }; + pinctrl_mikrobus1_uart: mikrobus1_uart { + pinmux = <PIN_PB26__URXD0>, + <PIN_PB27__UTXD0>; + bias-disable; + }; + pinctrl_qspi1_sck_cs_default: qspi1_sck_cs_default { pinmux = <PIN_PA6__QSPI1_SCK>, <PIN_PA11__QSPI1_CS>;
@@ -148,12 +155,6 @@ <PIN_PA13__SDMMC0_CD>; bias-disable; }; - - pinctrl_mikrobus1_uart: mikrobus1_uart { - pinmux = <PIN_PB26__URXD0>, - <PIN_PB27__UTXD0>; - bias-disable; - }; }; }; };
Signature · 1 line
2.25.1
PATCH 3/4 ARM: dts: at91: sama5d2: fix dtc warning for ohci and ehci
In reply to Eugen HristevFixed the following DTC build warning (reproducible with W=1)
arch/arm/dts/at91-sama5d2_icp.dtb: Warning (unit_address_format): /ahb/ohci@00400000: unit name should not have leading 0s arch/arm/dts/at91-sama5d2_icp.dtb: Warning (unit_address_format): /ahb/ehci@00500000: unit name should not have leading 0s
--- arch/arm/dts/at91-sama5d27_som1_ek.dts | 4 ++-- arch/arm/dts/at91-sama5d2_ptc_ek.dts | 4 ++-- arch/arm/dts/at91-sama5d2_xplained.dts | 4 ++-- arch/arm/dts/sama5d2.dtsi | 4 ++-- 4 files changed, 8 insertions(+), 8 deletions(-)
arch/arm/dts/at91-sama5d27_som1_ek.dts +2 -2
@@ -68,7 +68,7 @@ }; ahb { - usb1: ohci@00400000 { + usb1: ohci@400000 { num-ports = <3>; atmel,vbus-gpio = <&pioA 42 0>; pinctrl-names = "default";
@@ -76,7 +76,7 @@ status = "okay"; }; - usb2: ehci@00500000 { + usb2: ehci@500000 { status = "okay"; };
arch/arm/dts/at91-sama5d2_ptc_ek.dts +2 -2
@@ -76,7 +76,7 @@ status = "okay"; }; - usb1: ohci@00400000 { + usb1: ohci@400000 { num-ports = <3>; atmel,vbus-gpio = <0 &pioA PIN_PB12 GPIO_ACTIVE_HIGH
@@ -87,7 +87,7 @@ status = "okay"; }; - usb2: ehci@00500000 { + usb2: ehci@500000 { status = "okay"; };
arch/arm/dts/at91-sama5d2_xplained.dts +2 -2
@@ -25,7 +25,7 @@ }; ahb { - usb1: ohci@00400000 { + usb1: ohci@400000 { num-ports = <3>; atmel,vbus-gpio = <&pioA 42 0>; pinctrl-names = "default";
@@ -33,7 +33,7 @@ status = "okay"; }; - usb2: ehci@00500000 { + usb2: ehci@500000 { status = "okay"; };
arch/arm/dts/sama5d2.dtsi +2 -2
@@ -32,7 +32,7 @@ #size-cells = <1>; u-boot,dm-pre-reloc; - usb1: ohci@00400000 { + usb1: ohci@400000 { compatible = "atmel,at91rm9200-ohci", "usb-ohci"; reg = <0x00400000 0x100000>; clocks = <&uhphs_clk>, <&uhphs_clk>, <&uhpck>;
@@ -40,7 +40,7 @@ status = "disabled"; }; - usb2: ehci@00500000 { + usb2: ehci@500000 { compatible = "atmel,at91sam9g45-ehci", "usb-ehci"; reg = <0x00500000 0x100000>; clocks = <&utmi>, <&uhphs_clk>;
Signature · 1 line
2.25.1
Re: [PATCH 3/4] ARM: dts: at91: sama5d2: fix dtc warning for ohci and ehci
Hello,
Am Tue, Aug 17, 2021 at 01:29:24PM +0300 schrieb Eugen Hristev:
Quoted 93 lines
Fixed the following DTC build warning (reproducible with W=1)
arch/arm/dts/at91-sama5d2_icp.dtb: Warning (unit_address_format): /ahb/ohci@00400000: unit name should not have leading 0sarch/arm/dts/at91-sama5d2_icp.dtb: Warning (unit_address_format): /ahb/ehci@00500000: unit name should not have leading 0sSigned-off-by Eugen Hristev <[email protected]>--- arch/arm/dts/at91-sama5d27_som1_ek.dts | 4 ++-- arch/arm/dts/at91-sama5d2_ptc_ek.dts | 4 ++-- arch/arm/dts/at91-sama5d2_xplained.dts | 4 ++-- arch/arm/dts/sama5d2.dtsi | 4 ++-- 4 files changed, 8 insertions(+), 8 deletions(-)arch/arm/dts/at91-sama5d27_som1_ek.dts +2
-2@@ -68,7 +68,7 @@ }; ahb { - usb1: ohci@00400000 { + usb1: ohci@400000 { num-ports = <3>; atmel,vbus-gpio = <&pioA 42 0>; pinctrl-names = "default";@@ -76,7 +76,7 @@ status = "okay"; }; - usb2: ehci@00500000 { + usb2: ehci@500000 { status = "okay"; };arch/arm/dts/at91-sama5d2_ptc_ek.dts +2
-2@@ -76,7 +76,7 @@ status = "okay"; }; - usb1: ohci@00400000 { + usb1: ohci@400000 { num-ports = <3>; atmel,vbus-gpio = <0 &pioA PIN_PB12 GPIO_ACTIVE_HIGH@@ -87,7 +87,7 @@ status = "okay"; }; - usb2: ehci@00500000 { + usb2: ehci@500000 { status = "okay"; };arch/arm/dts/at91-sama5d2_xplained.dts +2
-2@@ -25,7 +25,7 @@ }; ahb { - usb1: ohci@00400000 { + usb1: ohci@400000 { num-ports = <3>; atmel,vbus-gpio = <&pioA 42 0>; pinctrl-names = "default";@@ -33,7 +33,7 @@ status = "okay"; }; - usb2: ehci@00500000 { + usb2: ehci@500000 { status = "okay"; };arch/arm/dts/sama5d2.dtsi +1
-1@@ -32,7 +32,7 @@ #size-cells = <1>; u-boot,dm-pre-reloc; - usb1: ohci@00400000 { + usb1: ohci@400000 { compatible = "atmel,at91rm9200-ohci", "usb-ohci"; reg = <0x00400000 0x100000>; clocks = <&uhphs_clk>, <&uhphs_clk>, <&uhpck>;
arch/arm/dts/sama5d2.dtsi line 46
Quoted 8 lines
arch/arm/dts/sama5d2.dtsi +1
-1@@ -40,7 +40,7 @@ status = "disabled"; }; - usb2: ehci@00500000 { + usb2: ehci@500000 { compatible = "atmel,at91sam9g45-ehci", "usb-ehci"; reg = <0x00500000 0x100000>; clocks = <&utmi>, <&uhphs_clk>;
Greets
Alex
PATCH 4/4 configs: sama5d2: add qspi config for QSPI1
In reply to Eugen HristevFrom: Mihai Sain <[email protected]>
Add new config for storing environment from QSPI1.
--- board/atmel/sama5d2_icp/MAINTAINERS | 1 + configs/sama5d2_icp_qspiflash_defconfig | 103 ++++++++++++++++++++++++ 2 files changed, 104 insertions(+) create mode 100644 configs/sama5d2_icp_qspiflash_defconfig
board/atmel/sama5d2_icp/MAINTAINERS +1 -0
@@ -4,4 +4,5 @@ S: Maintained F: board/atmel/sama5d2_icp/ F: include/configs/sama5d2_icp.h F: configs/sama5d2_icp_mmc_defconfig +F: configs/sama5d2_icp_qspiflash_defconfig
configs/sama5d2_icp_qspiflash_defconfig new file +103 -0
103 lines not on this page · raw message
Signature · 1 line
2.25.1
Quoted 9 lines · Eugen Hristev
From: Mihai Sain <[email protected]>
Add support for sst26vf064b 64Mbit qspi-flash that is present on
sama5d2_icpboard.Signed-off-by Mihai Sain <[email protected]>[[email protected]: move u-boot properties to sama5d2_icp-u-boot.dtsi]Signed-off-by Eugen Hristev <[email protected]>---
Applied whole series to u-boot-atmel/next , thanks !