mirror of
https://github.com/openwrt/openwrt.git
synced 2024-12-18 21:28:02 +00:00
layerscape: remove kernel 6.1 support
Layerscape was switched to 6.6 kernel. Now is time to remove 6.1 support. Signed-off-by: Pawel Dembicki <paweldembicki@gmail.com> Link: https://github.com/openwrt/openwrt/pull/16037 Signed-off-by: Robert Marko <robimarko@gmail.com>
This commit is contained in:
parent
633341c1a5
commit
f20987c161
@ -6,11 +6,7 @@ define Device/Default
|
||||
PROFILES := Default
|
||||
FILESYSTEMS := squashfs
|
||||
IMAGES := firmware.bin sysupgrade.bin
|
||||
ifdef CONFIG_LINUX_6_1
|
||||
DEVICE_DTS_DIR := $(DTS_DIR)
|
||||
else
|
||||
DEVICE_DTS_DIR := $(DTS_DIR)/nxp/ls
|
||||
endif
|
||||
KERNEL := kernel-bin | uImage none
|
||||
KERNEL_INITRAMFS = kernel-bin | gzip | fit gzip $$(DEVICE_DTS_DIR)/$$(DEVICE_DTS).dtb
|
||||
KERNEL_NAME := zImage
|
||||
|
@ -1,288 +0,0 @@
|
||||
From 1bb35ff4ce33e65601c8d9c736be52e4aabd6252 Mon Sep 17 00:00:00 2001
|
||||
From: Calvin Johnson <calvin.johnson@nxp.com>
|
||||
Date: Sat, 16 Sep 2017 14:20:23 +0530
|
||||
Subject: [PATCH] arm64: dts: freescale: ls1012a: update with ppfe support
|
||||
|
||||
Update ls1012a dtsi and platform dts files with support for ppfe.
|
||||
|
||||
Signed-off-by: Calvin Johnson <calvin.johnson@nxp.com>
|
||||
Signed-off-by: Anjaneyulu Jagarlmudi <anji.jagarlmudi@nxp.com>
|
||||
---
|
||||
.../boot/dts/freescale/fsl-ls1012a-frdm.dts | 43 +++++++++++++++++
|
||||
.../boot/dts/freescale/fsl-ls1012a-frwy.dts | 43 +++++++++++++++++
|
||||
.../boot/dts/freescale/fsl-ls1012a-qds.dts | 43 +++++++++++++++++
|
||||
.../boot/dts/freescale/fsl-ls1012a-rdb.dts | 47 +++++++++++++++++++
|
||||
.../arm64/boot/dts/freescale/fsl-ls1012a.dtsi | 29 ++++++++++++
|
||||
5 files changed, 205 insertions(+)
|
||||
|
||||
--- a/arch/arm64/boot/dts/freescale/fsl-ls1012a-frdm.dts
|
||||
+++ b/arch/arm64/boot/dts/freescale/fsl-ls1012a-frdm.dts
|
||||
@@ -14,6 +14,11 @@
|
||||
model = "LS1012A Freedom Board";
|
||||
compatible = "fsl,ls1012a-frdm", "fsl,ls1012a";
|
||||
|
||||
+ aliases {
|
||||
+ ethernet0 = &pfe_mac0;
|
||||
+ ethernet1 = &pfe_mac1;
|
||||
+ };
|
||||
+
|
||||
sys_mclk: clock-mclk {
|
||||
compatible = "fixed-clock";
|
||||
#clock-cells = <0>;
|
||||
@@ -95,6 +100,44 @@
|
||||
};
|
||||
};
|
||||
|
||||
+&pfe {
|
||||
+ status = "okay";
|
||||
+ #address-cells = <1>;
|
||||
+ #size-cells = <0>;
|
||||
+
|
||||
+ pfe_mac0: ethernet@0 {
|
||||
+ compatible = "fsl,pfe-gemac-port";
|
||||
+ #address-cells = <1>;
|
||||
+ #size-cells = <0>;
|
||||
+ reg = <0x0>; /* GEM_ID */
|
||||
+ fsl,gemac-bus-id = <0x0>; /* BUS_ID */
|
||||
+ fsl,gemac-phy-id = <0x2>; /* PHY_ID */
|
||||
+ fsl,mdio-mux-val = <0x0>;
|
||||
+ phy-mode = "sgmii";
|
||||
+ fsl,pfe-phy-if-flags = <0x0>;
|
||||
+
|
||||
+ mdio@0 {
|
||||
+ reg = <0x1>; /* enabled/disabled */
|
||||
+ };
|
||||
+ };
|
||||
+
|
||||
+ pfe_mac1: ethernet@1 {
|
||||
+ compatible = "fsl,pfe-gemac-port";
|
||||
+ #address-cells = <1>;
|
||||
+ #size-cells = <0>;
|
||||
+ reg = <0x1>; /* GEM_ID */
|
||||
+ fsl,gemac-bus-id = <0x1>; /* BUS_ID */
|
||||
+ fsl,gemac-phy-id = <0x1>; /* PHY_ID */
|
||||
+ fsl,mdio-mux-val = <0x0>;
|
||||
+ phy-mode = "sgmii";
|
||||
+ fsl,pfe-phy-if-flags = <0x0>;
|
||||
+
|
||||
+ mdio@0 {
|
||||
+ reg = <0x0>; /* enabled/disabled */
|
||||
+ };
|
||||
+ };
|
||||
+};
|
||||
+
|
||||
&qspi {
|
||||
status = "okay";
|
||||
|
||||
--- a/arch/arm64/boot/dts/freescale/fsl-ls1012a-frwy.dts
|
||||
+++ b/arch/arm64/boot/dts/freescale/fsl-ls1012a-frwy.dts
|
||||
@@ -14,6 +14,11 @@
|
||||
/ {
|
||||
model = "LS1012A FRWY Board";
|
||||
compatible = "fsl,ls1012a-frwy", "fsl,ls1012a";
|
||||
+
|
||||
+ aliases {
|
||||
+ ethernet0 = &pfe_mac0;
|
||||
+ ethernet1 = &pfe_mac1;
|
||||
+ };
|
||||
};
|
||||
|
||||
&duart0 {
|
||||
@@ -28,6 +33,44 @@
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
+&pfe {
|
||||
+ status = "okay";
|
||||
+ #address-cells = <1>;
|
||||
+ #size-cells = <0>;
|
||||
+
|
||||
+ pfe_mac0: ethernet@0 {
|
||||
+ compatible = "fsl,pfe-gemac-port";
|
||||
+ #address-cells = <1>;
|
||||
+ #size-cells = <0>;
|
||||
+ reg = <0x0>; /* GEM_ID */
|
||||
+ fsl,gemac-bus-id = <0x0>; /* BUS_ID */
|
||||
+ fsl,gemac-phy-id = <0x2>; /* PHY_ID */
|
||||
+ fsl,mdio-mux-val = <0x0>;
|
||||
+ phy-mode = "sgmii";
|
||||
+ fsl,pfe-phy-if-flags = <0x0>;
|
||||
+
|
||||
+ mdio@0 {
|
||||
+ reg = <0x1>; /* enabled/disabled */
|
||||
+ };
|
||||
+ };
|
||||
+
|
||||
+ pfe_mac1: ethernet@1 {
|
||||
+ compatible = "fsl,pfe-gemac-port";
|
||||
+ #address-cells = <1>;
|
||||
+ #size-cells = <0>;
|
||||
+ reg = <0x1>; /* GEM_ID */
|
||||
+ fsl,gemac-bus-id = <0x1>; /* BUS_ID */
|
||||
+ fsl,gemac-phy-id = <0x1>; /* PHY_ID */
|
||||
+ fsl,mdio-mux-val = <0x0>;
|
||||
+ phy-mode = "sgmii";
|
||||
+ fsl,pfe-phy-if-flags = <0x0>;
|
||||
+
|
||||
+ mdio@0 {
|
||||
+ reg = <0x0>; /* enabled/disabled */
|
||||
+ };
|
||||
+ };
|
||||
+};
|
||||
+
|
||||
&qspi {
|
||||
status = "okay";
|
||||
|
||||
--- a/arch/arm64/boot/dts/freescale/fsl-ls1012a-qds.dts
|
||||
+++ b/arch/arm64/boot/dts/freescale/fsl-ls1012a-qds.dts
|
||||
@@ -18,6 +18,11 @@
|
||||
mmc1 = &esdhc1;
|
||||
};
|
||||
|
||||
+ aliases {
|
||||
+ ethernet0 = &pfe_mac0;
|
||||
+ ethernet1 = &pfe_mac1;
|
||||
+ };
|
||||
+
|
||||
sys_mclk: clock-mclk {
|
||||
compatible = "fixed-clock";
|
||||
#clock-cells = <0>;
|
||||
@@ -132,6 +137,44 @@
|
||||
};
|
||||
};
|
||||
};
|
||||
+
|
||||
+&pfe {
|
||||
+ status = "okay";
|
||||
+ #address-cells = <1>;
|
||||
+ #size-cells = <0>;
|
||||
+
|
||||
+ pfe_mac0: ethernet@0 {
|
||||
+ compatible = "fsl,pfe-gemac-port";
|
||||
+ #address-cells = <1>;
|
||||
+ #size-cells = <0>;
|
||||
+ reg = <0x0>; /* GEM_ID */
|
||||
+ fsl,gemac-bus-id = <0x0>; /* BUS_ID */
|
||||
+ fsl,gemac-phy-id = <0x1>; /* PHY_ID */
|
||||
+ fsl,mdio-mux-val = <0x2>;
|
||||
+ phy-mode = "sgmii-2500";
|
||||
+ fsl,pfe-phy-if-flags = <0x0>;
|
||||
+
|
||||
+ mdio@0 {
|
||||
+ reg = <0x1>; /* enabled/disabled */
|
||||
+ };
|
||||
+ };
|
||||
+
|
||||
+ pfe_mac1: ethernet@1 {
|
||||
+ compatible = "fsl,pfe-gemac-port";
|
||||
+ #address-cells = <1>;
|
||||
+ #size-cells = <0>;
|
||||
+ reg = <0x1>; /* GEM_ID */
|
||||
+ fsl,gemac-bus-id = <0x1>; /* BUS_ID */
|
||||
+ fsl,gemac-phy-id = <0x2>; /* PHY_ID */
|
||||
+ fsl,mdio-mux-val = <0x3>;
|
||||
+ phy-mode = "sgmii-2500";
|
||||
+ fsl,pfe-phy-if-flags = <0x0>;
|
||||
+
|
||||
+ mdio@0 {
|
||||
+ reg = <0x0>; /* enabled/disabled */
|
||||
+ };
|
||||
+ };
|
||||
+};
|
||||
|
||||
&qspi {
|
||||
status = "okay";
|
||||
--- a/arch/arm64/boot/dts/freescale/fsl-ls1012a-rdb.dts
|
||||
+++ b/arch/arm64/boot/dts/freescale/fsl-ls1012a-rdb.dts
|
||||
@@ -16,6 +16,8 @@
|
||||
|
||||
aliases {
|
||||
serial0 = &duart0;
|
||||
+ ethernet0 = &pfe_mac0;
|
||||
+ ethernet1 = &pfe_mac1;
|
||||
mmc0 = &esdhc0;
|
||||
mmc1 = &esdhc1;
|
||||
};
|
||||
@@ -86,6 +88,44 @@
|
||||
};
|
||||
};
|
||||
|
||||
+&pfe {
|
||||
+ status = "okay";
|
||||
+ #address-cells = <1>;
|
||||
+ #size-cells = <0>;
|
||||
+
|
||||
+ pfe_mac0: ethernet@0 {
|
||||
+ compatible = "fsl,pfe-gemac-port";
|
||||
+ #address-cells = <1>;
|
||||
+ #size-cells = <0>;
|
||||
+ reg = <0x0>; /* GEM_ID */
|
||||
+ fsl,gemac-bus-id = <0x0>; /* BUS_ID */
|
||||
+ fsl,gemac-phy-id = <0x2>; /* PHY_ID */
|
||||
+ fsl,mdio-mux-val = <0x0>;
|
||||
+ phy-mode = "sgmii";
|
||||
+ fsl,pfe-phy-if-flags = <0x0>;
|
||||
+
|
||||
+ mdio@0 {
|
||||
+ reg = <0x1>; /* enabled/disabled */
|
||||
+ };
|
||||
+ };
|
||||
+
|
||||
+ pfe_mac1: ethernet@1 {
|
||||
+ compatible = "fsl,pfe-gemac-port";
|
||||
+ #address-cells = <1>;
|
||||
+ #size-cells = <0>;
|
||||
+ reg = <0x1>; /* GEM_ID */
|
||||
+ fsl,gemac-bus-id = < 0x1 >; /* BUS_ID */
|
||||
+ fsl,gemac-phy-id = < 0x1 >; /* PHY_ID */
|
||||
+ fsl,mdio-mux-val = <0x0>;
|
||||
+ phy-mode = "rgmii-txid";
|
||||
+ fsl,pfe-phy-if-flags = <0x0>;
|
||||
+
|
||||
+ mdio@0 {
|
||||
+ reg = <0x0>; /* enabled/disabled */
|
||||
+ };
|
||||
+ };
|
||||
+};
|
||||
+
|
||||
&qspi {
|
||||
status = "okay";
|
||||
|
||||
--- a/arch/arm64/boot/dts/freescale/fsl-ls1012a.dtsi
|
||||
+++ b/arch/arm64/boot/dts/freescale/fsl-ls1012a.dtsi
|
||||
@@ -568,6 +568,35 @@
|
||||
};
|
||||
};
|
||||
|
||||
+ reserved-memory {
|
||||
+ #address-cells = <2>;
|
||||
+ #size-cells = <2>;
|
||||
+ ranges;
|
||||
+
|
||||
+ pfe_reserved: packetbuffer@83400000 {
|
||||
+ reg = <0 0x83400000 0 0xc00000>;
|
||||
+ };
|
||||
+ };
|
||||
+
|
||||
+ pfe: pfe@04000000 {
|
||||
+ compatible = "fsl,pfe";
|
||||
+ reg = <0x0 0x04000000 0x0 0xc00000>, /* AXI 16M */
|
||||
+ <0x0 0x83400000 0x0 0xc00000>; /* PFE DDR 12M */
|
||||
+ reg-names = "pfe", "pfe-ddr";
|
||||
+ fsl,pfe-num-interfaces = <0x2>;
|
||||
+ interrupts = <0 172 0x4>, /* HIF interrupt */
|
||||
+ <0 173 0x4>, /*HIF_NOCPY interrupt */
|
||||
+ <0 174 0x4>; /* WoL interrupt */
|
||||
+ interrupt-names = "pfe_hif", "pfe_hif_nocpy", "pfe_wol";
|
||||
+ memory-region = <&pfe_reserved>;
|
||||
+ fsl,pfe-scfg = <&scfg 0>;
|
||||
+ fsl,rcpm-wakeup = <&rcpm 0xf0000020>;
|
||||
+ clocks = <&clockgen 4 0>;
|
||||
+ clock-names = "pfe";
|
||||
+
|
||||
+ status = "okay";
|
||||
+ };
|
||||
+
|
||||
firmware {
|
||||
optee {
|
||||
compatible = "linaro,optee-tz";
|
@ -1,41 +0,0 @@
|
||||
From 9c5c18dbf8e1845d349ef7020f8af5bc9b56ed1f Mon Sep 17 00:00:00 2001
|
||||
From: Pawel Dembicki <paweldembicki@gmail.com>
|
||||
Date: Fri, 28 Sep 2022 17:14:32 +0200
|
||||
Subject: [PATCH] arm64: dts: ls1012a-frdm/qds: workaround by updating qspi flash to
|
||||
single mode
|
||||
|
||||
Update rx and tx bus-width to 1 to use single mode to workaround ubifs
|
||||
issue found with double mode. (The same method as RDB board)
|
||||
|
||||
Signed-off-by: Pawel Dembicki <paweldembicki@gmail.com>
|
||||
---
|
||||
arch/arm64/boot/dts/freescale/fsl-ls1012a-frdm.dts | 4 ++--
|
||||
arch/arm64/boot/dts/freescale/fsl-ls1012a-qds.dts | 4 ++--
|
||||
2 file changed, 4 insertions(+), 4 deletions(-)
|
||||
|
||||
--- a/arch/arm64/boot/dts/freescale/fsl-ls1012a-frdm.dts
|
||||
+++ b/arch/arm64/boot/dts/freescale/fsl-ls1012a-frdm.dts
|
||||
@@ -148,8 +148,8 @@
|
||||
spi-max-frequency = <50000000>;
|
||||
m25p,fast-read;
|
||||
reg = <0>;
|
||||
- spi-rx-bus-width = <2>;
|
||||
- spi-tx-bus-width = <2>;
|
||||
+ spi-rx-bus-width = <1>;
|
||||
+ spi-tx-bus-width = <1>;
|
||||
};
|
||||
};
|
||||
|
||||
--- a/arch/arm64/boot/dts/freescale/fsl-ls1012a-qds.dts
|
||||
+++ b/arch/arm64/boot/dts/freescale/fsl-ls1012a-qds.dts
|
||||
@@ -186,8 +186,8 @@
|
||||
spi-max-frequency = <50000000>;
|
||||
m25p,fast-read;
|
||||
reg = <0>;
|
||||
- spi-rx-bus-width = <2>;
|
||||
- spi-tx-bus-width = <2>;
|
||||
+ spi-rx-bus-width = <1>;
|
||||
+ spi-tx-bus-width = <1>;
|
||||
};
|
||||
};
|
||||
|
@ -1,29 +0,0 @@
|
||||
From 9c5c18dbf8e1845d349ef7020f8af5bc9b56ed1f Mon Sep 17 00:00:00 2001
|
||||
From: Kuldeep Singh <kuldeep.singh@nxp.com>
|
||||
Date: Tue, 7 Jan 2020 17:14:32 +0530
|
||||
Subject: [PATCH] arm64: dts: ls1012a-rdb: workaround by updating qspi flash to
|
||||
single mode
|
||||
|
||||
Update rx and tx bus-width to 1 to use single mode to workaround ubifs
|
||||
issue found with double mode.
|
||||
|
||||
[ Leo: Local workaround ]
|
||||
|
||||
Signed-off-by: Kuldeep Singh <kuldeep.singh@nxp.com>
|
||||
---
|
||||
arch/arm64/boot/dts/freescale/fsl-ls1012a-rdb.dts | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
--- a/arch/arm64/boot/dts/freescale/fsl-ls1012a-rdb.dts
|
||||
+++ b/arch/arm64/boot/dts/freescale/fsl-ls1012a-rdb.dts
|
||||
@@ -136,8 +136,8 @@
|
||||
spi-max-frequency = <50000000>;
|
||||
m25p,fast-read;
|
||||
reg = <0>;
|
||||
- spi-rx-bus-width = <2>;
|
||||
- spi-tx-bus-width = <2>;
|
||||
+ spi-rx-bus-width = <1>;
|
||||
+ spi-tx-bus-width = <1>;
|
||||
};
|
||||
};
|
||||
|
@ -1,34 +0,0 @@
|
||||
From 38093ebbf25eb60a1aa863f46118a68a0300c56e Mon Sep 17 00:00:00 2001
|
||||
From: Kuldeep Singh <kuldeep.singh@nxp.com>
|
||||
Date: Fri, 3 Jan 2020 14:49:07 +0530
|
||||
Subject: [PATCH] arm64: dts: ls1046a-rdb: Update qspi spi-rx-bus-width to 1
|
||||
|
||||
Update rx width from quad mode to single mode as a workaround.
|
||||
|
||||
[Leo: Local workaround ]
|
||||
|
||||
Signed-off-by: Kuldeep Singh <kuldeep.singh@nxp.com>
|
||||
---
|
||||
arch/arm64/boot/dts/freescale/fsl-ls1046a-rdb.dts | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
--- a/arch/arm64/boot/dts/freescale/fsl-ls1046a-rdb.dts
|
||||
+++ b/arch/arm64/boot/dts/freescale/fsl-ls1046a-rdb.dts
|
||||
@@ -104,7 +104,7 @@
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
spi-max-frequency = <50000000>;
|
||||
- spi-rx-bus-width = <4>;
|
||||
+ spi-rx-bus-width = <1>;
|
||||
spi-tx-bus-width = <1>;
|
||||
reg = <0>;
|
||||
};
|
||||
@@ -114,7 +114,7 @@
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
spi-max-frequency = <50000000>;
|
||||
- spi-rx-bus-width = <4>;
|
||||
+ spi-rx-bus-width = <1>;
|
||||
spi-tx-bus-width = <1>;
|
||||
reg = <1>;
|
||||
};
|
@ -1,27 +0,0 @@
|
||||
From 20b1193c8c1d81a8d44ae36e579f70e6fbab45b9 Mon Sep 17 00:00:00 2001
|
||||
From: Han Xu <han.xu@nxp.com>
|
||||
Date: Tue, 14 Apr 2020 11:58:44 -0500
|
||||
Subject: [PATCH] LF-20-3 mtd: spi-nor: Use 1 bit mode of spansion(s25fs512s)
|
||||
flash
|
||||
|
||||
This is a workaround patch which uses only single bit mode of s25fs512s
|
||||
flash
|
||||
|
||||
Signed-off-by: Han Xu <han.xu@nxp.com>
|
||||
Signed-off-by: Kuldeep Singh <kuldeep.singh@nxp.com>
|
||||
---
|
||||
drivers/mtd/spi-nor/spansion.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
--- a/drivers/mtd/spi-nor/spansion.c
|
||||
+++ b/drivers/mtd/spi-nor/spansion.c
|
||||
@@ -398,8 +398,8 @@ static const struct flash_info spansion_
|
||||
MFR_FLAGS(USE_CLSR)
|
||||
},
|
||||
{ "s25fs512s", INFO6(0x010220, 0x4d0081, 256 * 1024, 256)
|
||||
- NO_SFDP_FLAGS(SPI_NOR_DUAL_READ | SPI_NOR_QUAD_READ)
|
||||
MFR_FLAGS(USE_CLSR)
|
||||
+ FIXUP_FLAGS(SPI_NOR_4B_OPCODES)
|
||||
.fixups = &s25fs_s_nor_fixups, },
|
||||
{ "s25sl12800", INFO(0x012018, 0x0300, 256 * 1024, 64) },
|
||||
{ "s25sl12801", INFO(0x012018, 0x0301, 64 * 1024, 256) },
|
File diff suppressed because it is too large
Load Diff
@ -1,54 +0,0 @@
|
||||
From fd32b1bc9a49919d3d59a50d775d03fe7ca5e654 Mon Sep 17 00:00:00 2001
|
||||
From: Bhaskar Upadhaya <Bhaskar.Upadhaya@nxp.com>
|
||||
Date: Wed, 29 Nov 2017 15:27:57 +0530
|
||||
Subject: [PATCH] phy: Add 2.5G SGMII interface mode
|
||||
|
||||
Add 2.5G SGMII interface mode(PHY_INTERFACE_MODE_2500SGMII)
|
||||
in existing phy_interface list
|
||||
|
||||
Signed-off-by: Bhaskar Upadhaya <Bhaskar.Upadhaya@nxp.com>
|
||||
---
|
||||
drivers/net/phy/phy-core.c | 1 +
|
||||
drivers/net/phy/phylink.c | 1 +
|
||||
include/linux/phy.h | 3 +++
|
||||
3 files changed, 5 insertions(+)
|
||||
|
||||
--- a/drivers/net/phy/phy-core.c
|
||||
+++ b/drivers/net/phy/phy-core.c
|
||||
@@ -136,6 +136,7 @@ int phy_interface_num_ports(phy_interfac
|
||||
case PHY_INTERFACE_MODE_RXAUI:
|
||||
case PHY_INTERFACE_MODE_XAUI:
|
||||
case PHY_INTERFACE_MODE_1000BASEKX:
|
||||
+ case PHY_INTERFACE_MODE_2500SGMII:
|
||||
return 1;
|
||||
case PHY_INTERFACE_MODE_QSGMII:
|
||||
case PHY_INTERFACE_MODE_QUSGMII:
|
||||
--- a/drivers/net/phy/phylink.c
|
||||
+++ b/drivers/net/phy/phylink.c
|
||||
@@ -231,6 +231,7 @@ static int phylink_interface_max_speed(p
|
||||
return SPEED_1000;
|
||||
|
||||
case PHY_INTERFACE_MODE_2500BASEX:
|
||||
+ case PHY_INTERFACE_MODE_2500SGMII:
|
||||
return SPEED_2500;
|
||||
|
||||
case PHY_INTERFACE_MODE_5GBASER:
|
||||
--- a/include/linux/phy.h
|
||||
+++ b/include/linux/phy.h
|
||||
@@ -159,6 +159,7 @@ typedef enum {
|
||||
PHY_INTERFACE_MODE_10GKR,
|
||||
PHY_INTERFACE_MODE_QUSGMII,
|
||||
PHY_INTERFACE_MODE_1000BASEKX,
|
||||
+ PHY_INTERFACE_MODE_2500SGMII,
|
||||
PHY_INTERFACE_MODE_MAX,
|
||||
} phy_interface_t;
|
||||
|
||||
@@ -280,6 +281,8 @@ static inline const char *phy_modes(phy_
|
||||
return "100base-x";
|
||||
case PHY_INTERFACE_MODE_QUSGMII:
|
||||
return "qusgmii";
|
||||
+ case PHY_INTERFACE_MODE_2500SGMII:
|
||||
+ return "sgmii-2500";
|
||||
default:
|
||||
return "unknown";
|
||||
}
|
@ -1,239 +0,0 @@
|
||||
From 1dc3a2e216d99adc2df022ab37eab32f61d80e0e Mon Sep 17 00:00:00 2001
|
||||
From: Christian Marangi <ansuelsmth@gmail.com>
|
||||
Date: Mon, 8 May 2023 19:26:48 +0200
|
||||
Subject: [PATCH] layerscape: 6.1: fix compilation warning for fsl ppfe driver
|
||||
|
||||
Rework some desc dump and dummy pkt function to fix compilation warning.
|
||||
Fix compilation warning:
|
||||
drivers/staging/fsl_ppfe/pfe_hif.c: In function 'send_dummy_pkt_to_hif':
|
||||
drivers/staging/fsl_ppfe/pfe_hif.c:118:19: error: cast to pointer from integer of different size [-Werror=int-to-pointer-cast]
|
||||
118 | ddr_ptr = (void *)((u64)readl(BMU2_BASE_ADDR + BMU_ALLOC_CTRL));
|
||||
| ^
|
||||
drivers/staging/fsl_ppfe/pfe_hif.c:122:20: error: cast to pointer from integer of different size [-Werror=int-to-pointer-cast]
|
||||
122 | lmem_ptr = (void *)((u64)readl(BMU1_BASE_ADDR + BMU_ALLOC_CTRL));
|
||||
| ^
|
||||
drivers/staging/fsl_ppfe/pfe_hif.c: In function 'pfe_hif_desc_dump':
|
||||
drivers/staging/fsl_ppfe/pfe_hif.c:195:24: error: cast from pointer to integer of different size [-Werror=pointer-to-int-cast]
|
||||
195 | desc_p = (u32)((u64)desc - (u64)hif->descr_baseaddr_v +
|
||||
| ^
|
||||
drivers/staging/fsl_ppfe/pfe_hif.c:195:36: error: cast from pointer to integer of different size [-Werror=pointer-to-int-cast]
|
||||
195 | desc_p = (u32)((u64)desc - (u64)hif->descr_baseaddr_v +
|
||||
| ^
|
||||
drivers/staging/fsl_ppfe/pfe_hif.c:207:19: error: cast from pointer to integer of different size [-Werror=pointer-to-int-cast]
|
||||
207 | desc_p = ((u64)desc - (u64)hif->descr_baseaddr_v +
|
||||
| ^
|
||||
drivers/staging/fsl_ppfe/pfe_hif.c:207:31: error: cast from pointer to integer of different size [-Werror=pointer-to-int-cast]
|
||||
207 | desc_p = ((u64)desc - (u64)hif->descr_baseaddr_v +
|
||||
| ^
|
||||
cc1: all warnings being treated as errors
|
||||
|
||||
In file included from ./include/linux/kernel.h:19,
|
||||
from ./include/linux/list.h:9,
|
||||
from ./include/linux/wait.h:7,
|
||||
from ./include/linux/eventfd.h:13,
|
||||
from drivers/staging/fsl_ppfe/pfe_cdev.c:11:
|
||||
drivers/staging/fsl_ppfe/pfe_cdev.c: In function 'pfe_cdev_read':
|
||||
./include/linux/kern_levels.h:5:25: error: format '%lu' expects argument of type 'long unsigned int', but argument 3 has type 'int' [-Werror=format=]
|
||||
5 | #define KERN_SOH "\001" /* ASCII Start Of Header */
|
||||
| ^~~~~~
|
||||
./include/linux/printk.h:422:25: note: in definition of macro 'printk_index_wrap'
|
||||
422 | _p_func(_fmt, ##__VA_ARGS__); \
|
||||
| ^~~~
|
||||
./include/linux/printk.h:132:17: note: in expansion of macro 'printk'
|
||||
132 | printk(fmt, ##__VA_ARGS__); \
|
||||
| ^~~~~~
|
||||
./include/linux/printk.h:580:9: note: in expansion of macro 'no_printk'
|
||||
580 | no_printk(KERN_DEBUG pr_fmt(fmt), ##__VA_ARGS__)
|
||||
| ^~~~~~~~~
|
||||
./include/linux/kern_levels.h:15:25: note: in expansion of macro 'KERN_SOH'
|
||||
15 | #define KERN_DEBUG KERN_SOH "7" /* debug-level messages */
|
||||
| ^~~~~~~~
|
||||
./include/linux/printk.h:580:19: note: in expansion of macro 'KERN_DEBUG'
|
||||
580 | no_printk(KERN_DEBUG pr_fmt(fmt), ##__VA_ARGS__)
|
||||
| ^~~~~~~~~~
|
||||
drivers/staging/fsl_ppfe/pfe_cdev.c:42:17: note: in expansion of macro 'pr_debug'
|
||||
42 | pr_debug("%u %lu", link_states[ret].phy_id,
|
||||
| ^~~~~~~~
|
||||
./include/linux/kern_levels.h:5:25: error: format '%lu' expects argument of type 'long unsigned int', but argument 3 has type 'size_t' {aka 'unsigned int'} [-Werror=format=]
|
||||
5 | #define KERN_SOH "\001" /* ASCII Start Of Header */
|
||||
| ^~~~~~
|
||||
./include/linux/printk.h:422:25: note: in definition of macro 'printk_index_wrap'
|
||||
422 | _p_func(_fmt, ##__VA_ARGS__); \
|
||||
| ^~~~
|
||||
./include/linux/printk.h:493:9: note: in expansion of macro 'printk'
|
||||
493 | printk(KERN_ERR pr_fmt(fmt), ##__VA_ARGS__)
|
||||
| ^~~~~~
|
||||
./include/linux/kern_levels.h:11:25: note: in expansion of macro 'KERN_SOH'
|
||||
11 | #define KERN_ERR KERN_SOH "3" /* error conditions */
|
||||
| ^~~~~~~~
|
||||
./include/linux/printk.h:493:16: note: in expansion of macro 'KERN_ERR'
|
||||
493 | printk(KERN_ERR pr_fmt(fmt), ##__VA_ARGS__)
|
||||
| ^~~~~~~~
|
||||
drivers/staging/fsl_ppfe/pfe_cdev.c:50:17: note: in expansion of macro 'pr_err'
|
||||
50 | pr_err("Failed to send (%d)bytes of (%lu) requested.\n",
|
||||
| ^~~~~~
|
||||
./include/linux/kern_levels.h:5:25: error: format '%lu' expects argument of type 'long unsigned int', but argument 2 has type 'unsigned int' [-Werror=format=]
|
||||
5 | #define KERN_SOH "\001" /* ASCII Start Of Header */
|
||||
| ^~~~~~
|
||||
./include/linux/printk.h:422:25: note: in definition of macro 'printk_index_wrap'
|
||||
422 | _p_func(_fmt, ##__VA_ARGS__); \
|
||||
| ^~~~
|
||||
./include/linux/printk.h:132:17: note: in expansion of macro 'printk'
|
||||
132 | printk(fmt, ##__VA_ARGS__); \
|
||||
| ^~~~~~
|
||||
./include/linux/printk.h:580:9: note: in expansion of macro 'no_printk'
|
||||
580 | no_printk(KERN_DEBUG pr_fmt(fmt), ##__VA_ARGS__)
|
||||
| ^~~~~~~~~
|
||||
./include/linux/kern_levels.h:15:25: note: in expansion of macro 'KERN_SOH'
|
||||
15 | #define KERN_DEBUG KERN_SOH "7" /* debug-level messages */
|
||||
| ^~~~~~~~
|
||||
./include/linux/printk.h:580:19: note: in expansion of macro 'KERN_DEBUG'
|
||||
580 | no_printk(KERN_DEBUG pr_fmt(fmt), ##__VA_ARGS__)
|
||||
| ^~~~~~~~~~
|
||||
drivers/staging/fsl_ppfe/pfe_cdev.c:57:9: note: in expansion of macro 'pr_debug'
|
||||
57 | pr_debug("Read of (%lu) bytes performed.\n", sizeof(link_states));
|
||||
| ^~~~~~~~
|
||||
cc1: all warnings being treated as errors
|
||||
|
||||
In file included from ./include/uapi/linux/posix_types.h:5,
|
||||
from ./include/uapi/linux/types.h:14,
|
||||
from ./include/linux/types.h:6,
|
||||
from ./include/linux/list.h:5,
|
||||
from ./include/linux/module.h:12,
|
||||
from drivers/staging/fsl_ppfe/pfe_sysfs.c:7:
|
||||
drivers/staging/fsl_ppfe/pfe_sysfs.c: In function 'pfe_set_util':
|
||||
./include/linux/stddef.h:8:14: error: passing argument 2 of 'kstrtoul' makes integer from pointer without a cast [-Werror=int-conversion]
|
||||
8 | #define NULL ((void *)0)
|
||||
| ^~~~~~~~~~~
|
||||
| |
|
||||
| void *
|
||||
drivers/staging/fsl_ppfe/pfe_sysfs.c:538:39: note: in expansion of macro 'NULL'
|
||||
538 | util_do_clear = kstrtoul(buf, NULL, 0);
|
||||
| ^~~~
|
||||
In file included from ./include/linux/kernel.h:13,
|
||||
from ./include/linux/list.h:9:
|
||||
./include/linux/kstrtox.h:30:69: note: expected 'unsigned int' but argument is of type 'void *'
|
||||
30 | static inline int __must_check kstrtoul(const char *s, unsigned int base, unsigned long *res)
|
||||
| ~~~~~~~~~~~~~^~~~
|
||||
cc1: all warnings being treated as errors
|
||||
|
||||
With UTIL compiled on, fix compilation warning:
|
||||
drivers/staging/fsl_ppfe/pfe_hal.c: In function 'pe_load_ddr_section':
|
||||
drivers/staging/fsl_ppfe/pfe_hal.c:617:19: error: 'else' without a previous 'if'
|
||||
617 | } else {
|
||||
| ^~~~
|
||||
drivers/staging/fsl_ppfe/pfe_hal.c:622:17: error: break statement not within loop or switch
|
||||
622 | break;
|
||||
| ^~~~~
|
||||
drivers/staging/fsl_ppfe/pfe_hal.c:624:9: error: case label not within a switch statement
|
||||
624 | case SHT_NOBITS:
|
||||
| ^~~~
|
||||
drivers/staging/fsl_ppfe/pfe_hal.c:627:17: error: break statement not within loop or switch
|
||||
627 | break;
|
||||
| ^~~~~
|
||||
drivers/staging/fsl_ppfe/pfe_hal.c:629:9: error: 'default' label not within a switch statement
|
||||
629 | default:
|
||||
| ^~~~~~~
|
||||
drivers/staging/fsl_ppfe/pfe_hal.c: At top level:
|
||||
drivers/staging/fsl_ppfe/pfe_hal.c:635:9: error: expected identifier or '(' before 'return'
|
||||
635 | return 0;
|
||||
| ^~~~~~
|
||||
drivers/staging/fsl_ppfe/pfe_hal.c:636:1: error: expected identifier or '(' before '}' token
|
||||
636 | }
|
||||
|
||||
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
Signed-off-by: Pawel Dembicki <paweldembicki@gmail.com>
|
||||
---
|
||||
drivers/staging/fsl_ppfe/pfe_cdev.c | 6 +++---
|
||||
drivers/staging/fsl_ppfe/pfe_hif.c | 14 +++++++-------
|
||||
drivers/staging/fsl_ppfe/pfe_sysfs.c | 2 +-
|
||||
3 files changed, 11 insertions(+), 11 deletions(-)
|
||||
|
||||
--- a/drivers/staging/fsl_ppfe/pfe_cdev.c
|
||||
+++ b/drivers/staging/fsl_ppfe/pfe_cdev.c
|
||||
@@ -34,7 +34,7 @@ static ssize_t pfe_cdev_read(struct file
|
||||
{
|
||||
int ret = 0;
|
||||
|
||||
- pr_info("PFE CDEV attempt copying (%lu) size of user.\n",
|
||||
+ pr_info("PFE CDEV attempt copying (%zu) size of user.\n",
|
||||
sizeof(link_states));
|
||||
|
||||
pr_debug("Dump link_state on screen before copy_to_user\n");
|
||||
@@ -47,14 +47,14 @@ static ssize_t pfe_cdev_read(struct file
|
||||
/* Copy to user the value in buffer sized len */
|
||||
ret = copy_to_user(buf, &link_states, sizeof(link_states));
|
||||
if (ret != 0) {
|
||||
- pr_err("Failed to send (%d)bytes of (%lu) requested.\n",
|
||||
+ pr_err("Failed to send (%d)bytes of (%zu) requested.\n",
|
||||
ret, len);
|
||||
return -EFAULT;
|
||||
}
|
||||
|
||||
/* offset set back to 0 as there is contextual reading offset */
|
||||
*off = 0;
|
||||
- pr_debug("Read of (%lu) bytes performed.\n", sizeof(link_states));
|
||||
+ pr_debug("Read of (%zu) bytes performed.\n", sizeof(link_states));
|
||||
|
||||
return sizeof(link_states);
|
||||
}
|
||||
--- a/drivers/staging/fsl_ppfe/pfe_hif.c
|
||||
+++ b/drivers/staging/fsl_ppfe/pfe_hif.c
|
||||
@@ -115,11 +115,11 @@ static void send_dummy_pkt_to_hif(void)
|
||||
0x33221100, 0xa8c05544, 0x00000301, 0x00000000,
|
||||
0x00000000, 0x00000000, 0x00000000, 0xbe86c51f };
|
||||
|
||||
- ddr_ptr = (void *)((u64)readl(BMU2_BASE_ADDR + BMU_ALLOC_CTRL));
|
||||
+ ddr_ptr = (void *)((uintptr_t)readl(BMU2_BASE_ADDR + BMU_ALLOC_CTRL));
|
||||
if (!ddr_ptr)
|
||||
return;
|
||||
|
||||
- lmem_ptr = (void *)((u64)readl(BMU1_BASE_ADDR + BMU_ALLOC_CTRL));
|
||||
+ lmem_ptr = (void *)((uintptr_t)readl(BMU1_BASE_ADDR + BMU_ALLOC_CTRL));
|
||||
if (!lmem_ptr)
|
||||
return;
|
||||
|
||||
@@ -186,16 +186,16 @@ static void pfe_hif_free_descr(struct pf
|
||||
void pfe_hif_desc_dump(struct pfe_hif *hif)
|
||||
{
|
||||
struct hif_desc *desc;
|
||||
- unsigned long desc_p;
|
||||
+ u64 desc_p;
|
||||
int ii = 0;
|
||||
|
||||
pr_info("%s\n", __func__);
|
||||
|
||||
desc = hif->rx_base;
|
||||
- desc_p = (u32)((u64)desc - (u64)hif->descr_baseaddr_v +
|
||||
+ desc_p = ((void *)desc - hif->descr_baseaddr_v +
|
||||
hif->descr_baseaddr_p);
|
||||
|
||||
- pr_info("HIF Rx desc base %p physical %x\n", desc, (u32)desc_p);
|
||||
+ pr_info("HIF Rx desc base %p physical %llx\n", desc, desc_p);
|
||||
for (ii = 0; ii < hif->rx_ring_size; ii++) {
|
||||
pr_info("status: %08x, ctrl: %08x, data: %08x, next: %x\n",
|
||||
readl(&desc->status), readl(&desc->ctrl),
|
||||
@@ -204,10 +204,10 @@ void pfe_hif_desc_dump(struct pfe_hif *h
|
||||
}
|
||||
|
||||
desc = hif->tx_base;
|
||||
- desc_p = ((u64)desc - (u64)hif->descr_baseaddr_v +
|
||||
+ desc_p = ((void *)desc - hif->descr_baseaddr_v +
|
||||
hif->descr_baseaddr_p);
|
||||
|
||||
- pr_info("HIF Tx desc base %p physical %x\n", desc, (u32)desc_p);
|
||||
+ pr_info("HIF Tx desc base %p physical %llx\n", desc, desc_p);
|
||||
for (ii = 0; ii < hif->tx_ring_size; ii++) {
|
||||
pr_info("status: %08x, ctrl: %08x, data: %08x, next: %x\n",
|
||||
readl(&desc->status), readl(&desc->ctrl),
|
||||
--- a/drivers/staging/fsl_ppfe/pfe_sysfs.c
|
||||
+++ b/drivers/staging/fsl_ppfe/pfe_sysfs.c
|
||||
@@ -535,7 +535,7 @@ static ssize_t pfe_show_tmu3_queues(stru
|
||||
static ssize_t pfe_set_util(struct device *dev, struct device_attribute *attr,
|
||||
const char *buf, size_t count)
|
||||
{
|
||||
- util_do_clear = kstrtoul(buf, NULL, 0);
|
||||
+ util_do_clear = kstrtoul(buf, 0, 0);
|
||||
return count;
|
||||
}
|
||||
|
@ -1,42 +0,0 @@
|
||||
From eb57941154e2ad142c07d47e874a221328467349 Mon Sep 17 00:00:00 2001
|
||||
From: Ioana Ciornei <ioana.ciornei@nxp.com>
|
||||
Date: Thu, 2 Jun 2022 12:11:11 +0300
|
||||
Subject: [PATCH] net: phylink: treat PHY_INTERFACE_MODE_2500SGMII in
|
||||
phylink_get_linkmodes
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
There is a downstream patch which adds a new interface type -
|
||||
PHY_INTERFACE_MODE_2500SGMII (which is really the same one as
|
||||
PHY_INTERFACE_MODE_2500BASEX).
|
||||
|
||||
We backported from upstream the following phylink patch which, of
|
||||
course, does not treat the PHY_INTERFACE_MODE_2500SGMII interface mode
|
||||
in a switch case statement.
|
||||
34ae2c09d46a ("net: phylink: add generic validate implementation")
|
||||
|
||||
Because of this, we get the following build warning.
|
||||
|
||||
drivers/net/phy/phylink.c: In function ‘phylink_get_linkmodes’:
|
||||
drivers/net/phy/phylink.c:322:2: warning: enumeration value ‘PHY_INTERFACE_MODE_2500SGMII’ not handled in switch [-Wswitch]
|
||||
322 | switch (interface) {
|
||||
| ^~~~~~
|
||||
|
||||
Fix it by treating the new interface mode in the switch-case statement.
|
||||
|
||||
Signed-off-by: Ioana Ciornei <ioana.ciornei@nxp.com>
|
||||
---
|
||||
drivers/net/phy/phylink.c | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
--- a/drivers/net/phy/phylink.c
|
||||
+++ b/drivers/net/phy/phylink.c
|
||||
@@ -518,6 +518,7 @@ unsigned long phylink_get_capabilities(p
|
||||
break;
|
||||
|
||||
case PHY_INTERFACE_MODE_2500BASEX:
|
||||
+ case PHY_INTERFACE_MODE_2500SGMII:
|
||||
caps |= MAC_2500FD;
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user