* [PATCH v2 1/1] riscv: dts: spacemit: Add 'linux,pci-domain' to PCIe nodes for K1
@ 2026-03-09 3:00 Chukun Pan
2026-03-09 10:51 ` Yixun Lan
2026-03-10 9:41 ` Yixun Lan
0 siblings, 2 replies; 3+ messages in thread
From: Chukun Pan @ 2026-03-09 3:00 UTC (permalink / raw)
To: Yixun Lan
Cc: Rob Herring, Paul Walmsley, Alexandre Ghiti, Albert Ou,
Conor Dooley, Palmer Dabbelt, Krzysztof Kozlowski, linux-riscv,
linux-kernel, devicetree, spacemit, Chukun Pan
The SpacemiT K1 SoC has 3 PCIe EP controller nodes. Add the
'linux,pci-domain' property to assign a PCI domain number to
each of the controllers instead of assigning it randomly.
This creates a stable sysfs path, allowing userspace scripts
to reliably target specific PCIe devices (such as PCIe NICs).
Signed-off-by: Chukun Pan <amadeus@jmu.edu.cn>
---
Changes in v2:
- Improve the commit messages
---
arch/riscv/boot/dts/spacemit/k1.dtsi | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/arch/riscv/boot/dts/spacemit/k1.dtsi b/arch/riscv/boot/dts/spacemit/k1.dtsi
index 529ec68e9c23..d2015201f8e5 100644
--- a/arch/riscv/boot/dts/spacemit/k1.dtsi
+++ b/arch/riscv/boot/dts/spacemit/k1.dtsi
@@ -1033,6 +1033,7 @@ pcie-bus {
#size-cells = <2>;
dma-ranges = <0x0 0x00000000 0x0 0x00000000 0x0 0x80000000>,
<0x0 0xb8000000 0x1 0x38000000 0x3 0x48000000>;
+
pcie0: pcie@ca000000 {
device_type = "pci";
compatible = "spacemit,k1-pcie";
@@ -1044,6 +1045,7 @@ pcie0: pcie@ca000000 {
"atu",
"config",
"link";
+ linux,pci-domain = <0>;
#address-cells = <3>;
#size-cells = <2>;
ranges = <0x01000000 0x0 0x00000000 0x0 0x8f002000 0x0 0x00100000>,
@@ -1087,6 +1089,7 @@ pcie1: pcie@ca400000 {
"atu",
"config",
"link";
+ linux,pci-domain = <1>;
#address-cells = <3>;
#size-cells = <2>;
ranges = <0x01000000 0x0 0x00000000 0x0 0x9f002000 0x0 0x00100000>,
@@ -1130,6 +1133,7 @@ pcie2: pcie@ca800000 {
"atu",
"config",
"link";
+ linux,pci-domain = <2>;
#address-cells = <3>;
#size-cells = <2>;
ranges = <0x01000000 0x0 0x00000000 0x0 0xb7002000 0x0 0x00100000>,
--
2.25.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH v2 1/1] riscv: dts: spacemit: Add 'linux,pci-domain' to PCIe nodes for K1
2026-03-09 3:00 [PATCH v2 1/1] riscv: dts: spacemit: Add 'linux,pci-domain' to PCIe nodes for K1 Chukun Pan
@ 2026-03-09 10:51 ` Yixun Lan
2026-03-10 9:41 ` Yixun Lan
1 sibling, 0 replies; 3+ messages in thread
From: Yixun Lan @ 2026-03-09 10:51 UTC (permalink / raw)
To: Chukun Pan
Cc: Rob Herring, Paul Walmsley, Alexandre Ghiti, Albert Ou,
Conor Dooley, Palmer Dabbelt, Krzysztof Kozlowski, linux-riscv,
linux-kernel, devicetree, spacemit
Hi Chukun,
On 11:00 Mon 09 Mar , Chukun Pan wrote:
> The SpacemiT K1 SoC has 3 PCIe EP controller nodes. Add the
> 'linux,pci-domain' property to assign a PCI domain number to
> each of the controllers instead of assigning it randomly.
>
> This creates a stable sysfs path, allowing userspace scripts
> to reliably target specific PCIe devices (such as PCIe NICs).
>
> Signed-off-by: Chukun Pan <amadeus@jmu.edu.cn>
Looks good to me
Reviewed-by: Yixun Lan <dlan@kernel.org>
> ---
> Changes in v2:
> - Improve the commit messages
> ---
> arch/riscv/boot/dts/spacemit/k1.dtsi | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/arch/riscv/boot/dts/spacemit/k1.dtsi b/arch/riscv/boot/dts/spacemit/k1.dtsi
> index 529ec68e9c23..d2015201f8e5 100644
> --- a/arch/riscv/boot/dts/spacemit/k1.dtsi
> +++ b/arch/riscv/boot/dts/spacemit/k1.dtsi
> @@ -1033,6 +1033,7 @@ pcie-bus {
> #size-cells = <2>;
> dma-ranges = <0x0 0x00000000 0x0 0x00000000 0x0 0x80000000>,
> <0x0 0xb8000000 0x1 0x38000000 0x3 0x48000000>;
> +
> pcie0: pcie@ca000000 {
> device_type = "pci";
> compatible = "spacemit,k1-pcie";
> @@ -1044,6 +1045,7 @@ pcie0: pcie@ca000000 {
> "atu",
> "config",
> "link";
> + linux,pci-domain = <0>;
> #address-cells = <3>;
> #size-cells = <2>;
> ranges = <0x01000000 0x0 0x00000000 0x0 0x8f002000 0x0 0x00100000>,
> @@ -1087,6 +1089,7 @@ pcie1: pcie@ca400000 {
> "atu",
> "config",
> "link";
> + linux,pci-domain = <1>;
> #address-cells = <3>;
> #size-cells = <2>;
> ranges = <0x01000000 0x0 0x00000000 0x0 0x9f002000 0x0 0x00100000>,
> @@ -1130,6 +1133,7 @@ pcie2: pcie@ca800000 {
> "atu",
> "config",
> "link";
> + linux,pci-domain = <2>;
> #address-cells = <3>;
> #size-cells = <2>;
> ranges = <0x01000000 0x0 0x00000000 0x0 0xb7002000 0x0 0x00100000>,
> --
> 2.25.1
>
--
Yixun Lan (dlan)
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH v2 1/1] riscv: dts: spacemit: Add 'linux,pci-domain' to PCIe nodes for K1
2026-03-09 3:00 [PATCH v2 1/1] riscv: dts: spacemit: Add 'linux,pci-domain' to PCIe nodes for K1 Chukun Pan
2026-03-09 10:51 ` Yixun Lan
@ 2026-03-10 9:41 ` Yixun Lan
1 sibling, 0 replies; 3+ messages in thread
From: Yixun Lan @ 2026-03-10 9:41 UTC (permalink / raw)
To: Chukun Pan
Cc: Yixun Lan, Rob Herring, Paul Walmsley, Alexandre Ghiti, Albert Ou,
Conor Dooley, Palmer Dabbelt, Krzysztof Kozlowski, linux-riscv,
linux-kernel, devicetree, spacemit
On Mon, 09 Mar 2026 11:00:00 +0800, Chukun Pan wrote:
> The SpacemiT K1 SoC has 3 PCIe EP controller nodes. Add the
> 'linux,pci-domain' property to assign a PCI domain number to
> each of the controllers instead of assigning it randomly.
>
> This creates a stable sysfs path, allowing userspace scripts
> to reliably target specific PCIe devices (such as PCIe NICs).
>
> [...]
Applied, thanks!
[1/1] riscv: dts: spacemit: Add 'linux,pci-domain' to PCIe nodes for K1
https://github.com/spacemit-com/linux/commit/86314111f654310a69c9775e35e263c036031675
Best regards,
--
Yixun Lan <dlan@kernel.org>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2026-03-10 9:41 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-03-09 3:00 [PATCH v2 1/1] riscv: dts: spacemit: Add 'linux,pci-domain' to PCIe nodes for K1 Chukun Pan
2026-03-09 10:51 ` Yixun Lan
2026-03-10 9:41 ` Yixun Lan
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox