Skip to contentSkip to conversation

ARM: dts: aspeed: Add dts for ASUS Kommando IPMI card

PATCH Superseded Anirudh Srinivasan 2 participants 9 messages Mar 2 – Mar 24 Arm (32-bit)

v1 of 3 Superseded Latest is v3 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ARM: dts: aspeed: Add dts for ASUS Kommando IPMI card

Add dts for Asus Kommando IPMI card, an ast2600 based pcie bmc card

---
 arch/arm/dts/Makefile                            |  1 +
 arch/arm/dts/ast2600-asus-kommando-ipmi-card.dts | 98 ++++++++++++++++++++++++
 2 files changed, 99 insertions(+)
arch/arm/dts/Makefile +1 -0
index 5141c3dc3aa025e2f5c9b2bb98216ee5c72cdf70..fa6837be747da4fbe102ac27e60ee3d81e230cb7 100755
@@ -682,6 +682,7 @@ dtb-$(CONFIG_ARCH_ASPEED) += \
 	ast2500-genesis3.dtb \
 	ast2500-romulus.dtb \
 	ast2600-ampere.dtb \
+	ast2600-asus-kommando-ipmi-card.dtb \
 	ast2600-bletchley.dtb \
 	ast2600-dcscm.dtb \
 	ast2600-evb-ecc.dtb \
arch/arm/dts/ast2600-asus-kommando-ipmi-card.dts new file +98 -0

98 lines not on this page · raw message

---
base-commit: d40130c7056b84dc5213f3ff6764d0e45bb84035
change-id: 20260228-asus-kommando-9de4d6b779a8

Best regards,

Signature · 1 line
Anirudh Srinivasan <[email protected]>
#1 lore raw

Apologies, This patch was meant for the u-boot tree and I forgot to include u-boot as a prefix in the patch title.

Should I resend another version with the corrected title?

Quoted 134 lines · Anirudh Srinivasan

Add dts for Asus Kommando IPMI card, an ast2600 based pcie bmc card

---
 arch/arm/dts/Makefile                            |  1 +
 arch/arm/dts/ast2600-asus-kommando-ipmi-card.dts | 98 ++++++++++++++++++++++++
 2 files changed, 99 insertions(+)
arch/arm/dts/Makefile +1 -0
index 5141c3dc3aa025e2f5c9b2bb98216ee5c72cdf70..fa6837be747da4fbe102ac27e60ee3d81e230cb7 100755
@@ -682,6 +682,7 @@ dtb-$(CONFIG_ARCH_ASPEED) += \
        ast2500-genesis3.dtb \
        ast2500-romulus.dtb \
        ast2600-ampere.dtb \
+       ast2600-asus-kommando-ipmi-card.dtb \
        ast2600-bletchley.dtb \
        ast2600-dcscm.dtb \
        ast2600-evb-ecc.dtb \
arch/arm/dts/ast2600-asus-kommando-ipmi-card.dts new file +98 -1
new file mode 100644
index 0000000000000000000000000000000000000000..11fee8d5403541f2453f6b8c6f123c5d1108137d
@@ -0,0 +1,98 @@
+// SPDX-License-Identifier: GPL-2.0+
+/dts-v1/;
+
+#include "ast2600-u-boot.dtsi"
+
+/ {
+       model = "ASUS Kommando IPMI Card";
+       compatible = "asus,kommando-ipmi-card", "aspeed,ast2600";
+
+       memory {
+               device_type = "memory";
+               reg = <0x80000000 0x40000000>;
+       };
+
+       chosen {
+               stdout-path = &uart5;
+       };
+
+       aliases {
+               spi0 = &fmc;
+               ethernet0 = &mac2;
+       };
+
+       cpus {
+               cpu@0 {
+                       clock-frequency = <800000000>;
+               };
+               cpu@1 {
+                       clock-frequency = <800000000>;
+               };
+       };
+};
+
+&fmc {
+       status = "okay";
+
+       pinctrl-names = "default";
+       pinctrl-0 = <&pinctrl_fmcquad_default>;
+
+       flash@0 {
+               status = "okay";
+               spi-max-frequency = <50000000>;
+               spi-tx-bus-width = <4>;
+               spi-rx-bus-width = <4>;
+       };
+};
+
+&hace {
+       status = "okay";
+       u-boot,dm-pre-reloc;
+};
+
+&mac2 {
+       status = "okay";
+       phy-mode = "rgmii";
+       phy-handle = <&ethphy2>;
+       pinctrl-names = "default";
+       pinctrl-0 = <&pinctrl_rgmii3_default>;
+};
+
+&mdio {
+       status = "okay";
+       pinctrl-names = "default";
+       pinctrl-0 = <&pinctrl_mdio3_default>;
+       #address-cells = <1>;
+       #size-cells = <0>;
+
+       ethphy2: ethernet-phy@2 {
+               reg = <0>;
+       };
+};
+
+&scu {
+       mac2-clk-delay = <0x08 0x04
+                         0x08 0x04
+                         0x08 0x04>;
+};
+
+&sdrammc {
+       clock-frequency = <400000000>;
+};
+
+&uart5 {
+       status = "okay";
+       u-boot,dm-pre-reloc;
+};
+
+&wdt1 {
+       status = "okay";
+};
+
+&wdt2 {
+       status = "okay";
+};
+
+&wdt3 {
+       status = "okay";
+};
 
---

base-commit: d40130c7056b84dc5213f3ff6764d0e45bb84035
change-id: 20260228-asus-kommando-9de4d6b779a8

Best regards,
--
Anirudh Srinivasan <[email protected]>

Signature · 2 lines
Regards
Anirudh Srinivasan
#2 lore raw
Quoted 4 lines · Anirudh Srinivasan

Apologies, This patch was meant for the u-boot tree and I forgot to include u-boot as a prefix in the patch title.

Should I resend another version with the corrected title?

No, this reply is enough, thanks :)

Andrew

#3 lore raw
In reply to Anirudh Srinivasan
Quoted 98 lines · Anirudh Srinivasan

Add dts for Asus Kommando IPMI card, an ast2600 based pcie bmc card

---
 arch/arm/dts/Makefile                            |  1 + arch/arm/dts/ast2600-asus-kommando-ipmi-card.dts | 98
++++++++++++++++++++++++

 2 files changed, 99 insertions(+)
arch/arm/dts/Makefile +0 -0

index 5141c3dc3aa025e2f5c9b2bb98216ee5c72cdf70..fa6837be747da4fbe102ac27e60 ee3d81e230cb7 100755

arch/arm/dts/Makefile +1 -0
@@ -682,6 +682,7 @@ dtb-$(CONFIG_ARCH_ASPEED) += \
  	ast2500-genesis3.dtb \
  	ast2500-romulus.dtb \
  	ast2600-ampere.dtb \
+	ast2600-asus-kommando-ipmi-card.dtb \
  	ast2600-bletchley.dtb \
  	ast2600-dcscm.dtb \
  	ast2600-evb-ecc.dtb \
arch/arm/dts/ast2600-asus-kommando-ipmi-card.dts new file +0 -0
new file mode 100644

index 0000000000000000000000000000000000000000..11fee8d5403541f2453f6b8c6f1 23c5d1108137d

arch/arm/dts/ast2600-asus-kommando-ipmi-card.dts new file +66 -0
@@ -0,0 +1,98 @@
+// SPDX-License-Identifier: GPL-2.0+
+/dts-v1/;
+
+#include "ast2600-u-boot.dtsi"
+
+/ {
+	model = "ASUS Kommando IPMI Card";
+	compatible = "asus,kommando-ipmi-card", "aspeed,ast2600";
+
+	memory {
+		device_type = "memory";
+		reg = <0x80000000 0x40000000>;
+	};
+
+	chosen {
+		stdout-path = &uart5;
+	};
+
+	aliases {
+		spi0 = &fmc;
+		ethernet0 = &mac2;
+	};
+
+	cpus {
+		cpu@0 {
+			clock-frequency = <800000000>;
+		};
+		cpu@1 {
+			clock-frequency = <800000000>;
+		};
+	};
+};
+
+&fmc {
+	status = "okay";
+
+	pinctrl-names = "default";
+	pinctrl-0 = <&pinctrl_fmcquad_default>;
+
+	flash@0 {
+		status = "okay";
+		spi-max-frequency = <50000000>;
+		spi-tx-bus-width = <4>;
+		spi-rx-bus-width = <4>;
+	};
+};
+
+&hace {
+	status = "okay";
+	u-boot,dm-pre-reloc;
+};
+
+&mac2 {
+	status = "okay";
+	phy-mode = "rgmii";
+	phy-handle = <&ethphy2>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&pinctrl_rgmii3_default>;
+};
+
+&mdio {
+	status = "okay";
+	pinctrl-names = "default";
+	pinctrl-0 = <&pinctrl_mdio3_default>;
+	#address-cells = <1>;
+	#size-cells = <0>;

arch/arm/dts/ast2600-asus-kommando-ipmi-card.dts line 76

Quoted 10 lines
arch/arm/dts/ast2600-asus-kommando-ipmi-card.dts new file +10 -0
+
+	ethphy2: ethernet-phy@2 {
+		reg = <0>;
+	};
+};
+
+&scu {
+	mac2-clk-delay = <0x08 0x04
+			  0x08 0x04
+			  0x08 0x04>;

Before we go too far down this path, are you aware of the discussions on the kernel side?

https://lore.kernel.org/all/[email protected]/

Essentially, can we defer configuring the delays via the SCU here so we can isolate that problem in the kernel?

I recognise that you might want networking in u-boot as well though :)

Quoted 28 lines
arch/arm/dts/ast2600-asus-kommando-ipmi-card.dts new file +22 -1
+};
+
+&sdrammc {
+	clock-frequency = <400000000>;
+};
+
+&uart5 {
+	status = "okay";
+	u-boot,dm-pre-reloc;
+};
+
+&wdt1 {
+	status = "okay";
+};
+
+&wdt2 {
+	status = "okay";
+};
+
+&wdt3 {
+	status = "okay";
+};
 
---

base-commit: d40130c7056b84dc5213f3ff6764d0e45bb84035
change-id: 20260228-asus-kommando-9de4d6b779a8

Best regards,

#4 lore raw

Hi Andrew,

Quoted 17 lines · Andrew Jeffery
Quoted 9 lines · Anirudh Srinivasan

Add dts for Asus Kommando IPMI card, an ast2600 based pcie bmc card

---
 arch/arm/dts/Makefile                            |  1 +
 arch/arm/dts/ast2600-asus-kommando-ipmi-card.dts | 98
++++++++++++++++++++++++
 2 files changed, 99 insertions(+)

arch/arm/dts/ast2600-asus-kommando-ipmi-card.dts line 76

Quoted 5 lines
arch/arm/dts/ast2600-asus-kommando-ipmi-card.dts new file +5 -0
+
+&scu {
+     mac2-clk-delay = <0x08 0x04
+                       0x08 0x04
+                       0x08 0x04>;
Quoted 7 lines

Before we go too far down this path, are you aware of the discussions on the kernel side?

https://lore.kernel.org/all/[email protected]/

Essentially, can we defer configuring the delays via the SCU here so we can isolate that problem in the kernel?

I've been trying to follow that discussion over the last few days, and the more I read it, the more I get confused.

I went back and looked at the u-boot DT from the Asus fw dump [1], and there seems to be no mac2-clk-delay in it. That uses u-boot 2019 too. Not sure how accurate/useful this info is though.

So (correct me if I am wrong)
1. If we don't need this clk delay at all, then I can skip this clk-delay entry in u-boot and use "rgmii-id" in the linux and u-boot DTs.
2. If we need this clk delay, u-boot is supposed to configure it (u-boot DT uses "rgmii") and linux uses "rgmii-id". We don't need to worry about u-boot patching the linux DT because both use separate DTs.

This feels like something I should be able to test without any patches to u-boot/linux. Just try booting u-boot with 2 different DTs (one with rgmii and one with rgmii-id) and see which scenario networking works.

Is anything I'm saying correct?

Quoted 2 lines

I recognise that you might want networking in u-boot as well though :)

I then read this statement and got confused a bit more.

[1] https://gist.github.com/Genius1237/0b81fcbc8c25a8b516e63e466e8522b1

Quoted 29 lines
Quoted 29 lines
arch/arm/dts/ast2600-asus-kommando-ipmi-card.dts new file +22 -1
+};
+
+&sdrammc {
+     clock-frequency = <400000000>;
+};
+
+&uart5 {
+     status = "okay";
+     u-boot,dm-pre-reloc;
+};
+
+&wdt1 {
+     status = "okay";
+};
+
+&wdt2 {
+     status = "okay";
+};
+
+&wdt3 {
+     status = "okay";
+};
 
---

base-commit: d40130c7056b84dc5213f3ff6764d0e45bb84035
change-id: 20260228-asus-kommando-9de4d6b779a8

Best regards,

Signature · 2 lines
Regards
Anirudh Srinivasan
#5 lore raw

Helo Andrew,

After doing some more reading and experimentation, I think I might have a clearer understanding of how things work.

Andrew Lunn's suggestion in the patch series from Aspeed was to patch u-boot to not insert clock delays anymore. And then use rgmii-id as the phy mode in u-boot and linux for all new device trees.

I tested this by setting the mac2 clk delays to 0 in the u-boot device tree like this

&scu {
    mac2-clk-delay = <0 0
              0 0
              0 0>;
};

Setting the phy-mode to rgmii-id now gives us working networking in u-boot and linux.

So how do you suggest we proceed here?
1. Add this DT to u-boot now, set phy mode to rgmii-id and set mac2-clk-delay values to 0. Networking will work in u-boot and linux. Update the DT to remove the clk delay values once Aspeed updates u-boot
2. Add this DT to u-boot now. set phy mode to rgmii-id. This means networking won't work in u-boot, but it works once you're in linux
3. Add this DT to u-boot now without networking. Add networking later when Aspeed updates u-boot based on the discussion in that thread.
3. Wait for aspeed to update u-boot, then add this DT to u-boot.

In any of these cases, we can also now add networking to the linux DT for this card (it's missing currently) with phy-mode set to rgmii-id. No need to wait for Aspeed to update the linux driver (or I think they're not gonna make any updates at all if it's just u-boot that needs fixing).

Let me know what you think (or if I've gotten any info incorrect here).

Regards
Anirudh Srinivasan

#6 lore raw

Hi Anirudh,

Sorry for the delay in reply to this thread.

Quoted 32 lines · Anirudh Srinivasan

Helo Andrew,

After doing some more reading and experimentation, I think I might have a clearer understanding of how things work.

Andrew Lunn's suggestion in the patch series from Aspeed was to patch u-boot to not insert clock delays anymore. And then use rgmii-id as the phy mode in u-boot and linux for all new device trees.

I tested this by setting the mac2 clk delays to 0 in the u-boot device tree like this

&scu {
    mac2-clk-delay = <0 0
              0 0
              0 0>;
};

Setting the phy-mode to rgmii-id now gives us working networking in u-boot and linux.

So how do you suggest we proceed here?
1. Add this DT to u-boot now, set phy mode to rgmii-id and set mac2-clk-delay values to 0. Networking will work in u-boot and linux. Update the DT to remove the clk delay values once Aspeed updates u-boot
2. Add this DT to u-boot now. set phy mode to rgmii-id. This means networking won't work in u-boot, but it works once you're in linux
3. Add this DT to u-boot now without networking. Add networking later when Aspeed updates u-boot based on the discussion in that thread.
3. Wait for aspeed to update u-boot, then add this DT to u-boot.

Quoted 5 lines

In any of these cases, we can also now add networking to the linux DT for this card (it's missing currently) with phy-mode set to rgmii-id. No need to wait for Aspeed to update the linux driver (or I think they're not gonna make any updates at all if it's just u-boot that needs fixing).

Working backwards here, yes, I think we should add the correct (but not necessarily yet functional) description to the linux devicetree (probably best to point out the lack of functionality in a comment in the relevant devicetree node).

Then, do your first option 3 above, except add the description of option 1 in the commit message so people understand how to make networking function for both environments. That way it's apparent that anyone who has enabled networking in u-boot is also aware of the (future) problems of doing so, as they likely will have read that description. Please add links to the relevant discussions between Andrew Lunn and Jacky to the commit message as well.

Any concerns with that approach?

Quoted 2 lines

Let me know what you think (or if I've gotten any info incorrect here).

That all sounds about right to me.

Andrew

#7 lore raw

Hi Andrew

Quoted 49 lines · Andrew Jeffery

Hi Anirudh,

Sorry for the delay in reply to this thread.

Quoted 32 lines · Anirudh Srinivasan

Helo Andrew,

After doing some more reading and experimentation, I think I might have a clearer understanding of how things work.

Andrew Lunn's suggestion in the patch series from Aspeed was to patch u-boot to not insert clock delays anymore. And then use rgmii-id as the phy mode in u-boot and linux for all new device trees.

I tested this by setting the mac2 clk delays to 0 in the u-boot device tree like this

&scu {
    mac2-clk-delay = <0 0
              0 0
              0 0>;
};

Setting the phy-mode to rgmii-id now gives us working networking in u-boot and linux.

So how do you suggest we proceed here?
1. Add this DT to u-boot now, set phy mode to rgmii-id and set mac2-clk-delay values to 0. Networking will work in u-boot and linux. Update the DT to remove the clk delay values once Aspeed updates u-boot
2. Add this DT to u-boot now. set phy mode to rgmii-id. This means networking won't work in u-boot, but it works once you're in linux
3. Add this DT to u-boot now without networking. Add networking later when Aspeed updates u-boot based on the discussion in that thread.
3. Wait for aspeed to update u-boot, then add this DT to u-boot.

Quoted 5 lines

In any of these cases, we can also now add networking to the linux DT for this card (it's missing currently) with phy-mode set to rgmii-id. No need to wait for Aspeed to update the linux driver (or I think they're not gonna make any updates at all if it's just u-boot that needs fixing).

Working backwards here, yes, I think we should add the correct (but not necessarily yet functional) description to the linux devicetree (probably best to point out the lack of functionality in a comment in the relevant devicetree node).

Quoted 7 lines

Then, do your first option 3 above, except add the description of option 1 in the commit message so people understand how to make networking function for both environments. That way it's apparent that anyone who has enabled networking in u-boot is also aware of the (future) problems of doing so, as they likely will have read that description. Please add links to the relevant discussions between Andrew Lunn and Jacky to the commit message as well.

Sounds good. I'll do things in this manner:
1. I'll send v2 of this u-boot patch without networking support, with a description of how to enable networking in the commit message.
2. I'll send a kernel patch to enable networking with rgmii-id as the phy mode. The commit message will mention that this requires patched u-boot without the clock delays (with a link to the above u-boot patch series).

I'll add links to the discussion between Andrew and Jacky in both. Once aspeed updates u-boot, we can add networking in u-boot.

Quoted 9 lines

Any concerns with that approach?

Quoted 2 lines

Let me know what you think (or if I've gotten any info incorrect here).

That all sounds about right to me.

Andrew

Signature · 2 lines
Regards
Anirudh Srinivasan
#8 lore raw
Quoted 69 lines · Anirudh Srinivasan

Hi Andrew

Quoted 49 lines · Andrew Jeffery

Hi Anirudh,

Sorry for the delay in reply to this thread.

Quoted 32 lines · Anirudh Srinivasan

Helo Andrew,

After doing some more reading and experimentation, I think I might have a clearer understanding of how things work.

Andrew Lunn's suggestion in the patch series from Aspeed was to patch u-boot to not insert clock delays anymore. And then use rgmii-id as the phy mode in u-boot and linux for all new device trees.

I tested this by setting the mac2 clk delays to 0 in the u-boot device tree like this

&scu {
    mac2-clk-delay = <0 0
              0 0
              0 0>;
};

Setting the phy-mode to rgmii-id now gives us working networking in u-boot and linux.

So how do you suggest we proceed here?
1. Add this DT to u-boot now, set phy mode to rgmii-id and set mac2-clk-delay values to 0. Networking will work in u-boot and linux. Update the DT to remove the clk delay values once Aspeed updates u-boot
2. Add this DT to u-boot now. set phy mode to rgmii-id. This means networking won't work in u-boot, but it works once you're in linux
3. Add this DT to u-boot now without networking. Add networking later when Aspeed updates u-boot based on the discussion in that thread.
3. Wait for aspeed to update u-boot, then add this DT to u-boot.

Quoted 5 lines

In any of these cases, we can also now add networking to the linux DT for this card (it's missing currently) with phy-mode set to rgmii-id. No need to wait for Aspeed to update the linux driver (or I think they're not gonna make any updates at all if it's just u-boot that needs fixing).

Working backwards here, yes, I think we should add the correct (but not necessarily yet functional) description to the linux devicetree (probably best to point out the lack of functionality in a comment in the relevant devicetree node).

Quoted 7 lines

Then, do your first option 3 above, except add the description of option 1 in the commit message so people understand how to make networking function for both environments. That way it's apparent that anyone who has enabled networking in u-boot is also aware of the (future) problems of doing so, as they likely will have read that description. Please add links to the relevant discussions between Andrew Lunn and Jacky to the commit message as well.

Sounds good. I'll do things in this manner:
1. I'll send v2 of this u-boot patch without networking support, with a description of how to enable networking in the commit message.
2. I'll send a kernel patch to enable networking with rgmii-id as the phy mode. The commit message will mention that this requires patched u-boot without the clock delays (with a link to the above u-boot patch series).

Quoted 2 lines

I'll add links to the discussion between Andrew and Jacky in both. Once aspeed updates u-boot, we can add networking in u-boot.

Sounds good!

Thanks,

Andrew