mediatek: dts: remove useless SPI cs-gpios property
authorShiji Yang <[email protected]>
Sun, 24 Aug 2025 12:59:53 +0000 (20:59 +0800)
committerHauke Mehrtens <[email protected]>
Sun, 19 Oct 2025 22:28:15 +0000 (00:28 +0200)
These devices only have one SPI peripheral. And the chip select pin is
directly controlled by the SPI host hardware. Hence we don't need to
assign empty GPIO phandle for them. This patch also adjust the reg
address of the SPI peripheral node to follow the cs-gpios changes.

Signed-off-by: Shiji Yang <[email protected]>
Link: https://github.com/openwrt/openwrt/pull/19845
Signed-off-by: Hauke Mehrtens <[email protected]>
target/linux/mediatek/dts/mt7981a-comfast-cf-e393ax.dts
target/linux/mediatek/dts/mt7981a-edgecore-eap111.dts
target/linux/mediatek/dts/mt7981b-openwrt-one.dts
target/linux/mediatek/dts/mt7986a-zyxel-ex5601-t0-common.dtsi
target/linux/mediatek/dts/mt7986a-zyxel-ex5700-telenor.dts
target/linux/mediatek/files-6.12/arch/arm64/boot/dts/mediatek/mt7981-rfb.dts
target/linux/mediatek/files-6.12/arch/arm64/boot/dts/mediatek/mt7986a-rfb.dtsi

index 1cf13ff6a9fd28186dab4e01757be23ad2cc6bad..fa7856163bc7477baacb06795e739a4162963af4 100644 (file)
 &spi0 {
        pinctrl-names = "default";
        pinctrl-0 = <&spi0_flash_pins>;
-       cs-gpios = <0>, <0>;
        #address-cells = <1>;
        #size-cells = <0>;
        status = "okay";
        #address-cells = <1>;
        #size-cells = <0>;
 
-       spi_nand: spi_nand@1 {
+       spi_nand: spi_nand@0 {
                #address-cells = <1>;
                #size-cells = <1>;
                compatible = "spi-nand";
-               reg = <1>;
+               reg = <0>;
                spi-max-frequency = <52000000>;
 
                spi-cal-enable;
index 7844d11eb5a9b6ca061b8fa8c34370170bbb4cb8..adfc3f5b09d379e8a7ca89e2708a3753548e8d4b 100644 (file)
@@ -76,7 +76,6 @@
 &spi0 {
        pinctrl-names = "default";
        pinctrl-0 = <&spi0_flash_pins>;
-       cs-gpios = <0>, <0>;
        #address-cells = <1>;
        #size-cells = <0>;
        status = "okay";
index 5f54506b2cba16ca78e8c360d495e94294f0fa7b..302e6289b7aeebe8afbd98c2dd1ea6a1ed5795f6 100644 (file)
 &spi0 {
        pinctrl-names = "default";
        pinctrl-0 = <&spi0_flash_pins>;
-       cs-gpios = <0>, <0>;
        #address-cells = <1>;
        #size-cells = <0>;
        status = "okay";
 
-       flash@1 {
+       flash@0 {
                #address-cells = <1>;
                #size-cells = <1>;
                compatible = "spi-nand";
-               reg = <1>;
+               reg = <0>;
                spi-max-frequency = <52000000>;
 
                spi-cal-enable;
index 2c7d1dc18462be129f9b2acedf91777e1b55de65..82abf5f3a5b15452b4f04dd577c0fc83be04b4ab 100644 (file)
 &spi0 {
        pinctrl-names = "default";
        pinctrl-0 = <&spi_flash_pins>;
-       cs-gpios = <0>, <0>;
        #address-cells = <1>;
        #size-cells = <0>;
        status = "okay";
 
-       spi_nand: spi_nand@1 {
+       spi_nand: spi_nand@0 {
                #address-cells = <1>;
                #size-cells = <1>;
                compatible = "spi-nand";
-               reg = <1>;
+               reg = <0>;
                spi-max-frequency = <52000000>;
                spi-tx-bus-width = <4>;
                spi-rx-bus-width = <4>;
index 0252ab7aba96f9df1387ea55c312f73b7ca0c99c..97f498ba8c45ae06fdf68948f08e264d900423b0 100644 (file)
 &spi0 {
        pinctrl-names = "default";
        pinctrl-0 = <&spi_flash_pins>;
-       cs-gpios = <0>, <0>;
        status = "okay";
 
        flash@0 {
-               compatible = "jedec,spi-nor";
-               reg = <0>;
-               spi-max-frequency = <20000000>;
-       };
-
-       flash@1 {
                compatible = "spi-nand";
-               reg = <1>;
+               reg = <0>;
 
                mediatek,nmbm;
                mediatek,bmt-max-ratio = <1>;
index 28bcc155dfb61c50c572797f7db565ec4bf506e5..155157762479a5329869db660515c6185af118fe 100644 (file)
 &spi0 {
        pinctrl-names = "default";
        pinctrl-0 = <&spi0_flash_pins>;
-       cs-gpios = <0>, <0>;
        #address-cells = <1>;
        #size-cells = <0>;
        status = "disabled";
index c01f3dd0e484868e5516d27789f958441b5b5af7..1dfb64d4565e8d4234bdbdd53e5a1632a2a796fd 100644 (file)
 &spi0 {
        pinctrl-names = "default";
        pinctrl-0 = <&spi_flash_pins>;
-       cs-gpios = <0>, <0>;
        #address-cells = <1>;
        #size-cells = <0>;
        status = "disabled";