* [PATCH 1/2] arm64: dts: freescale: ls1028a: Fix embedded PCI interrupt mapping
2024-04-18 20:09 [PATCH 0/2] arm64: dts: freescale: LS1028a PCI fixes Rob Herring (Arm)
@ 2024-04-18 20:09 ` Rob Herring (Arm)
2024-04-18 20:09 ` [PATCH 2/2] arm64: dts: freescale: ls1028a: Add standard PCI device compatible strings to ENETC Rob Herring (Arm)
2024-04-25 6:44 ` [PATCH 0/2] arm64: dts: freescale: LS1028a PCI fixes Shawn Guo
2 siblings, 0 replies; 4+ messages in thread
From: Rob Herring (Arm) @ 2024-04-18 20:09 UTC (permalink / raw)
To: Shawn Guo, Li Yang, Krzysztof Kozlowski, Conor Dooley,
Richard Cochran
Cc: linux-arm-kernel, devicetree, linux-kernel, netdev
PCI devices should use PCI interrupt binding for their interrupts assuming
they function as standard PCI interrupts. The embedded PCI devices in the
LS1028a are mapping the interrupts directly to the host interrupt
controller. While that works here, it is unusual.
Based on the reference manual, there is not any INTC or INTD to map, so
only INTA and INTB are mapped.
Signed-off-by: Rob Herring (Arm) <robh@kernel.org>
---
arch/arm64/boot/dts/freescale/fsl-ls1028a.dtsi | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/arch/arm64/boot/dts/freescale/fsl-ls1028a.dtsi b/arch/arm64/boot/dts/freescale/fsl-ls1028a.dtsi
index ae534c23b970..8f8179924851 100644
--- a/arch/arm64/boot/dts/freescale/fsl-ls1028a.dtsi
+++ b/arch/arm64/boot/dts/freescale/fsl-ls1028a.dtsi
@@ -1099,6 +1099,10 @@ pcie@1f0000000 { /* Integrated Endpoint Root Complex */
0xc2000000 0x1 0xf8230000 0x1 0xf8230000 0x0 0x020000
/* BAR4 (PF5) - non-prefetchable memory */
0x82000000 0x1 0xfc000000 0x1 0xfc000000 0x0 0x400000>;
+ #interrupt-cells = <1>;
+ interrupt-map-mask = <0 0 0 7>;
+ interrupt-map = <0000 0 0 1 &gic 0 0 GIC_SPI 94 IRQ_TYPE_LEVEL_HIGH>,
+ <0000 0 0 2 &gic 0 0 GIC_SPI 95 IRQ_TYPE_LEVEL_HIGH>;
enetc_port0: ethernet@0,0 {
compatible = "fsl,enetc";
@@ -1143,7 +1147,7 @@ ethernet@0,4 {
mscc_felix: ethernet-switch@0,5 {
reg = <0x000500 0 0 0 0>;
/* IEP INT_B */
- interrupts = <GIC_SPI 95 IRQ_TYPE_LEVEL_HIGH>;
+ interrupts = <2>;
status = "disabled";
mscc_felix_ports: ports {
@@ -1216,7 +1220,7 @@ fixed-link {
rcec@1f,0 {
reg = <0x00f800 0 0 0 0>;
/* IEP INT_A */
- interrupts = <GIC_SPI 94 IRQ_TYPE_LEVEL_HIGH>;
+ interrupts = <1>;
};
};
--
2.43.0
^ permalink raw reply related [flat|nested] 4+ messages in thread* [PATCH 2/2] arm64: dts: freescale: ls1028a: Add standard PCI device compatible strings to ENETC
2024-04-18 20:09 [PATCH 0/2] arm64: dts: freescale: LS1028a PCI fixes Rob Herring (Arm)
2024-04-18 20:09 ` [PATCH 1/2] arm64: dts: freescale: ls1028a: Fix embedded PCI interrupt mapping Rob Herring (Arm)
@ 2024-04-18 20:09 ` Rob Herring (Arm)
2024-04-25 6:44 ` [PATCH 0/2] arm64: dts: freescale: LS1028a PCI fixes Shawn Guo
2 siblings, 0 replies; 4+ messages in thread
From: Rob Herring (Arm) @ 2024-04-18 20:09 UTC (permalink / raw)
To: Shawn Guo, Li Yang, Krzysztof Kozlowski, Conor Dooley,
Richard Cochran
Cc: linux-arm-kernel, devicetree, linux-kernel, netdev
PCI devices should have a compatible string based on the vendor and device
IDs. Add these to the Freescale ENETC devices.
Putting the PCI compatible string first as vendor and device ID is more
specific than a compatible without any device specific information.
Signed-off-by: Rob Herring (Arm) <robh@kernel.org>
---
arch/arm64/boot/dts/freescale/fsl-ls1028a.dtsi | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/arch/arm64/boot/dts/freescale/fsl-ls1028a.dtsi b/arch/arm64/boot/dts/freescale/fsl-ls1028a.dtsi
index 8f8179924851..70b8731029c4 100644
--- a/arch/arm64/boot/dts/freescale/fsl-ls1028a.dtsi
+++ b/arch/arm64/boot/dts/freescale/fsl-ls1028a.dtsi
@@ -1105,19 +1105,19 @@ pcie@1f0000000 { /* Integrated Endpoint Root Complex */
<0000 0 0 2 &gic 0 0 GIC_SPI 95 IRQ_TYPE_LEVEL_HIGH>;
enetc_port0: ethernet@0,0 {
- compatible = "fsl,enetc";
+ compatible = "pci1957,e100", "fsl,enetc";
reg = <0x000000 0 0 0 0>;
status = "disabled";
};
enetc_port1: ethernet@0,1 {
- compatible = "fsl,enetc";
+ compatible = "pci1957,e100", "fsl,enetc";
reg = <0x000100 0 0 0 0>;
status = "disabled";
};
enetc_port2: ethernet@0,2 {
- compatible = "fsl,enetc";
+ compatible = "pci1957,e100", "fsl,enetc";
reg = <0x000200 0 0 0 0>;
phy-mode = "internal";
status = "disabled";
@@ -1130,14 +1130,14 @@ fixed-link {
};
enetc_mdio_pf3: mdio@0,3 {
- compatible = "fsl,enetc-mdio";
+ compatible = "pci1957,ee01", "fsl,enetc-mdio";
reg = <0x000300 0 0 0 0>;
#address-cells = <1>;
#size-cells = <0>;
};
ethernet@0,4 {
- compatible = "fsl,enetc-ptp";
+ compatible = "pci1957,ee02", "fsl,enetc-ptp";
reg = <0x000400 0 0 0 0>;
clocks = <&clockgen QORIQ_CLK_HWACCEL 3>;
little-endian;
@@ -1205,7 +1205,7 @@ fixed-link {
};
enetc_port3: ethernet@0,6 {
- compatible = "fsl,enetc";
+ compatible = "pci1957,e100", "fsl,enetc";
reg = <0x000600 0 0 0 0>;
phy-mode = "internal";
status = "disabled";
--
2.43.0
^ permalink raw reply related [flat|nested] 4+ messages in thread* Re: [PATCH 0/2] arm64: dts: freescale: LS1028a PCI fixes
2024-04-18 20:09 [PATCH 0/2] arm64: dts: freescale: LS1028a PCI fixes Rob Herring (Arm)
2024-04-18 20:09 ` [PATCH 1/2] arm64: dts: freescale: ls1028a: Fix embedded PCI interrupt mapping Rob Herring (Arm)
2024-04-18 20:09 ` [PATCH 2/2] arm64: dts: freescale: ls1028a: Add standard PCI device compatible strings to ENETC Rob Herring (Arm)
@ 2024-04-25 6:44 ` Shawn Guo
2 siblings, 0 replies; 4+ messages in thread
From: Shawn Guo @ 2024-04-25 6:44 UTC (permalink / raw)
To: Rob Herring (Arm)
Cc: Shawn Guo, Li Yang, Krzysztof Kozlowski, Conor Dooley,
Richard Cochran, linux-arm-kernel, devicetree, linux-kernel,
netdev
On Thu, Apr 18, 2024 at 03:09:24PM -0500, Rob Herring (Arm) wrote:
> This short series addresses a couple of schema warnings with the
> embedded PCI devices in the LS1028a:
>
> pcie@1f0000000: rcec@1f,0:interrupts:0:0: 0 is not one of [1, 2, 3, 4]
> pcie@1f0000000: rcec@1f,0:interrupts:0: [0, 94, 4] is too long
> pcie@1f0000000: mdio@0,3:compatible: ['fsl,enetc-mdio'] does not contain items matching the given schema
> pcie@1f0000000: ethernet@0,6:compatible: ['fsl,enetc'] does not contain items matching the given schema
> pcie@1f0000000: ethernet@0,4:compatible: ['fsl,enetc-ptp'] does not contain items matching the given schema
> pcie@1f0000000: ethernet@0,2:compatible: ['fsl,enetc'] does not contain items matching the given schema
> pcie@1f0000000: ethernet@0,1:compatible: ['fsl,enetc'] does not contain items matching the given schema
> pcie@1f0000000: ethernet@0,0:compatible: ['fsl,enetc'] does not contain items matching the given schema
> pcie@1f0000000: ethernet-switch@0,5:interrupts:0:0: 0 is not one of [1, 2, 3, 4]
> pcie@1f0000000: ethernet-switch@0,5:interrupts:0: [0, 95, 4] is too long
>
> Signed-off-by: Rob Herring (Arm) <robh@kernel.org>
> ---
> Rob Herring (Arm) (2):
> arm64: dts: freescale: ls1028a: Fix embedded PCI interrupt mapping
> arm64: dts: freescale: ls1028a: Add standard PCI device compatible strings to ENETC
Applied both, thanks!
^ permalink raw reply [flat|nested] 4+ messages in thread