Add 4-bit SPI bus width on target devices
Subsystems (2)
cover Add 4-bit SPI bus width on target devices
From: "Fong, Yan Kei" <[email protected]>
Add SPI bus width properties to correctly describe the hardware on the following devices:
- Stratix10
- Agilex
- Agilex5
- N5X
Fong, Yan Kei (4):
arm64: dts: socfpga: n5x: Add 4-bit SPI bus width
arm64: dts: socfpga: stratix10: Add 4-bit SPI bus width
arm64: dts: socfpga: agilex: Add 4-bit SPI bus width
arm64: dts: socfpga: agilex5: Add 4-bit SPI bus width
arch/arm64/boot/dts/altera/socfpga_stratix10_socdk.dts | 2 ++ arch/arm64/boot/dts/intel/socfpga_agilex5_socdk.dts | 2 ++ arch/arm64/boot/dts/intel/socfpga_agilex_socdk.dts | 2 ++ arch/arm64/boot/dts/intel/socfpga_n5x_socdk.dts | 2 ++ 4 files changed, 8 insertions(+)
Signature · 1 line
2.25.1
PATCH 1/4 arm64: dts: socfpga: n5x: Add 4-bit SPI bus width
From: "Fong, Yan Kei" <[email protected]>
Add spi-tx-bus-width and spi-rx-bus-width properties with value 4 to the n5x device tree.
This update configures the SPI controller to use a 4-bit bus width for both transmission and reception, potentially improving SPI throughput and matching the hardware capabilities more closely.
--- arch/arm64/boot/dts/intel/socfpga_n5x_socdk.dts | 2 ++ 1 file changed, 2 insertions(+)
arch/arm64/boot/dts/intel/socfpga_n5x_socdk.dts +2 -0
@@ -93,6 +93,8 @@ flash@0 { cdns,tsd2d-ns = <50>; cdns,tchsh-ns = <4>; cdns,tslch-ns = <4>; + spi-tx-bus-width = <4>; + spi-rx-bus-width = <4>; partitions { compatible = "fixed-partitions";
Signature · 1 line
2.25.1
Re: [PATCH 1/4] arm64: dts: socfpga: n5x: Add 4-bit SPI bus width
Quoted 8 lines · On 6/24/25 01:52, [email protected] wrote:
From: "Fong, Yan Kei" <[email protected]>
Add spi-tx-bus-width and spi-rx-bus-width properties with value 4 to the n5x device tree.
This update configures the SPI controller to use a 4-bit bus width for both transmission and reception, potentially improving SPI throughput and matching the hardware capabilities more closely.
Please use 80 columns for your commit message! Like this:
Add spi-tx-bus-width and spi-rx-bus-width properties with value 4 to the
n5x device tree. This update configures the SPI controller to use a
4-bit bus width for both transmission and reception, potentially improving SPI throughput and matching the hardware capabilities more closely.
Doesn't the above make it much easier to read? Please do this fall your patches from now on!
Dinh
PATCH 2/4 arm64: dts: socfpga: stratix10: Add 4-bit SPI bus width
In reply to [email protected]From: "Fong, Yan Kei" <[email protected]>
Add spi-tx-bus-width and spi-rx-bus-width properties with value 4 to the stratix10 device tree.
This update configures the SPI controller to use a 4-bit bus width for both transmission and reception, potentially improving SPI throughput and matching the hardware capabilities more closely.
--- arch/arm64/boot/dts/altera/socfpga_stratix10_socdk.dts | 2 ++ 1 file changed, 2 insertions(+)
arch/arm64/boot/dts/altera/socfpga_stratix10_socdk.dts +2 -0
@@ -190,6 +190,8 @@ flash@0 { cdns,tsd2d-ns = <50>; cdns,tchsh-ns = <4>; cdns,tslch-ns = <4>; + spi-tx-bus-width = <4>; + spi-rx-bus-width = <4>; partitions { compatible = "fixed-partitions";
Signature · 1 line
2.25.1
PATCH 3/4 arm64: dts: socfpga: agilex: Add 4-bit SPI bus width
In reply to [email protected]From: "Fong, Yan Kei" <[email protected]>
Add spi-tx-bus-width and spi-rx-bus-width properties with value 4 to the agilex device tree.
This update configures the SPI controller to use a 4-bit bus width for both transmission and reception, potentially improving SPI throughput and matching the hardware capabilities more closely.
--- arch/arm64/boot/dts/intel/socfpga_agilex_socdk.dts | 2 ++ 1 file changed, 2 insertions(+)
arch/arm64/boot/dts/intel/socfpga_agilex_socdk.dts +2 -0
@@ -116,6 +116,8 @@ flash@0 { cdns,tsd2d-ns = <50>; cdns,tchsh-ns = <4>; cdns,tslch-ns = <4>; + spi-tx-bus-width = <4>; + spi-rx-bus-width = <4>; partitions { compatible = "fixed-partitions";
Signature · 1 line
2.25.1
PATCH 4/4 arm64: dts: socfpga: agilex5: Add 4-bit SPI bus width
In reply to [email protected]From: "Fong, Yan Kei" <[email protected]>
Add spi-tx-bus-width and spi-rx-bus-width properties with value 4 to the agilex5 device tree.
This update configures the SPI controller to use a 4-bit bus width for both transmission and reception, potentially improving SPI throughput and matching the hardware capabilities more closely.
--- arch/arm64/boot/dts/intel/socfpga_agilex5_socdk.dts | 2 ++ 1 file changed, 2 insertions(+)
arch/arm64/boot/dts/intel/socfpga_agilex5_socdk.dts +2 -0
@@ -57,6 +57,8 @@ flash@0 { cdns,tsd2d-ns = <50>; cdns,tchsh-ns = <4>; cdns,tslch-ns = <4>; + spi-tx-bus-width = <4>; + spi-rx-bus-width = <4>; partitions { compatible = "fixed-partitions";
Signature · 1 line
2.25.1
Dinh Nguyen
maintainerQuoted 14 lines · On 6/24/25 01:52, [email protected] wrote:
From: "Fong, Yan Kei" <[email protected]>
Add SPI bus width properties to correctly describe the hardware on the following devices:
- Stratix10
- Agilex
- Agilex5
- N5XFong, Yan Kei (4):
arm64: dts: socfpga: n5x: Add 4-bit SPI bus width
arm64: dts: socfpga: stratix10: Add 4-bit SPI bus width
arm64: dts: socfpga: agilex: Add 4-bit SPI bus width
arm64: dts: socfpga: agilex5: Add 4-bit SPI bus width
Quoted 6 lines
arch/arm64/boot/dts/altera/socfpga_stratix10_socdk.dts | 2 ++ arch/arm64/boot/dts/intel/socfpga_agilex5_socdk.dts | 2 ++ arch/arm64/boot/dts/intel/socfpga_agilex_socdk.dts | 2 ++ arch/arm64/boot/dts/intel/socfpga_n5x_socdk.dts | 2 ++ 4 files changed, 8 insertions(+)
This is for the QSPI driver right? I don't even see the driver using this property. So how would this help?
cover Add 4-bit SPI bus width on target devices
From: Fong, Yan Kei <[email protected]>
The changes required for the QSPI subsystem. With this implementation, the read performance will be greater compare to single bus width when trying to read the QSPI flash chips. Below is the test results:
$cat /sys/kernel/debug/spi-nor/spi0.0/params
...
...
opcodes
read 0x6c -> from micron QSPI spec, 6c indicates quad output fast read
...
...
protocols
read 1S-1S-4S
Quoted 23 lines · On 6/24/25 01:52, [email protected] wrote:
Quoted 3 lines
From: "Fong, Yan Kei" <[email protected]>
Add SPI bus width properties to correctly describe the hardware on the
following devices:
Quoted 11 lines
- Stratix10
- Agilex
- Agilex5
- N5XFong, Yan Kei (4):
arm64: dts: socfpga: n5x: Add 4-bit SPI bus width
arm64: dts: socfpga: stratix10: Add 4-bit SPI bus width
arm64: dts: socfpga: agilex: Add 4-bit SPI bus width
arm64: dts: socfpga: agilex5: Add 4-bit SPI bus widthQuoted 6 lines
arch/arm64/boot/dts/altera/socfpga_stratix10_socdk.dts | 2 ++ arch/arm64/boot/dts/intel/socfpga_agilex5_socdk.dts | 2 ++ arch/arm64/boot/dts/intel/socfpga_agilex_socdk.dts | 2 ++ arch/arm64/boot/dts/intel/socfpga_n5x_socdk.dts | 2 ++ 4 files changed, 8 insertions(+)
Quoted 2 lines
This is for the QSPI driver right? I don't even see the driver using this property. So how would this help?
Yes, it's for QSPI driver. The bindings (spi-tx-bus-width and spi-rx-bus-width) are defined in Documentation/devicetree/bindings/spi/spi-peripheral-props.yaml. They are read in of_spi_parse_dt() which is ultimately called from spi_register_controller().