ARM: dts: aspeed: Add Facebook Backpack-CMM BMC
Subsystems (3)
PATCH v2 2/2 ARM: dts: aspeed: Add Facebook Backpack-CMM BMC
Add initial version of device tree file for Facebook Backpack CMM (Chasis Management Module) ast2500 BMC.
Note: I2C devices on Backpack Line Cards and Fabric Cards are not listed in the device tree file because Line/Fabric Cards may be unplugged.
---
Changes since v1:
- including "aspeed-bmc-facebook-cmm.dtb" in Makefile.
arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/aspeed-bmc-facebook-cmm.dts | 317 ++++++++++++++++++ 2 files changed, 318 insertions(+) create mode 100644 arch/arm/boot/dts/aspeed-bmc-facebook-cmm.dts
arch/arm/boot/dts/Makefile +1 -0
@@ -1200,6 +1200,7 @@ dtb-$(CONFIG_ARCH_ASPEED) += \ aspeed-ast2500-evb.dtb \ aspeed-bmc-arm-centriq2400-rep.dtb \ aspeed-bmc-arm-stardragon4800-rep2.dtb \ + aspeed-bmc-facebook-cmm.dtb \ aspeed-bmc-facebook-tiogapass.dtb \ aspeed-bmc-intel-s2600wf.dtb \ aspeed-bmc-opp-lanyang.dtb \
arch/arm/boot/dts/aspeed-bmc-facebook-cmm.dts new file +317 -0
317 lines not on this page · raw message
Signature · 1 line
2.17.1
PATCH v2 2/2 ARM: dts: aspeed: Add Facebook Backpack-CMM BMC
Hi Tao,
Quoted 125 lines · Tao Ren
Add initial version of device tree file for Facebook Backpack CMM (Chasis Management Module) ast2500 BMC.
Note: I2C devices on Backpack Line Cards and Fabric Cards are not listed in the device tree file because Line/Fabric Cards may be unplugged.
Signed-off-by Tao Ren <[email protected]>---
Changes since v1:
- including "aspeed-bmc-facebook-cmm.dtb" inMakefile.arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/aspeed-bmc-facebook-cmm.dts | 317 ++++++++++++++++++ 2 files changed, 318 insertions(+) create mode 100644 arch/arm/boot/dts/aspeed-bmc-facebook-cmm.dtsarch/arm/boot/dts/Makefile +1
-0@@ -1200,6 +1200,7 @@ dtb-$(CONFIG_ARCH_ASPEED) += \ aspeed-ast2500-evb.dtb \ aspeed-bmc-arm-centriq2400-rep.dtb \ aspeed-bmc-arm-stardragon4800-rep2.dtb \ + aspeed-bmc-facebook-cmm.dtb \ aspeed-bmc-facebook-tiogapass.dtb \ aspeed-bmc-intel-s2600wf.dtb \ aspeed-bmc-opp-lanyang.dtb \arch/arm/ renamed from arch/arm/boot/dts/aspeed-bmc-facebook-cmm.dts +0
-0
boot/dts/aspeed-bmc-facebook-cmm.dts
new file mode 100644
index 000000000000..a259d8a2426aarch/arm/boot/dts/aspeed-bmc-facebook-cmm.dts new file +62
-0@@ -0,0 +1,317 @@ +// SPDX-License-Identifier: GPL-2.0+ +// Copyright (c) 2018 Facebook Inc. +/dts-v1/; + +#include "aspeed-g5.dtsi" + +/ { + model = "Facebook Backpack CMM BMC"; + compatible = "facebook,cmm-bmc", "aspeed,ast2500"; + + aliases { + /* + * Override the default uart aliases to avoid breaking + * the legacy applications. + */ + serial0 = &uart5; + serial1 = &uart1; + serial2 = &uart3; + serial3 = &uart4; + + /* + * Hardcode the bus number of i2c switches' channels to + * avoid breaking the legacy applications. + */ + i2c16 = &imux16; + i2c17 = &imux17; + i2c18 = &imux18; + i2c19 = &imux19; + i2c20 = &imux20; + i2c21 = &imux21; + i2c22 = &imux22; + i2c23 = &imux23; + i2c24 = &imux24; + i2c25 = &imux25; + i2c26 = &imux26; + i2c27 = &imux27; + i2c28 = &imux28; + i2c29 = &imux29; + i2c30 = &imux30; + i2c31 = &imux31; + i2c32 = &imux32; + i2c33 = &imux33; + i2c34 = &imux34; + i2c35 = &imux35; + i2c36 = &imux36; + i2c37 = &imux37; + i2c38 = &imux38; + i2c39 = &imux39; + }; + + chosen { + stdout-path = &uart1; + bootargs = "console=ttyS1,9600n8 root=/dev/ram rw earlyprintk"; + }; + + memory at 80000000 { + reg = <0x80000000 0x20000000>; + }; +}; + +/* + * Update reset type to "system" (full chip) to fix warm reboot hangissue
+ * when reset type is set to default ("soc", gated by reset mask registers).
+ */
+&wdt1 {arch/arm/boot/dts/aspeed-bmc-facebook-cmm.dts new file +22
-0+ status = "okay"; + aspeed,reset-type = "system"; +}; + +/* + * wdt2 is not used by Backpack CMM. + */ +&wdt2 { + status = "disabled"; +}; + +&fmc { + status = "okay"; + flash at 0 { + status = "okay"; + m25p,fast-read; + label = "bmc"; +#include "facebook-bmc-flash-layout.dtsi" + }; +}; + +&uart1 {
arch/arm/boot/dts/aspeed-bmc-facebook-cmm.dts line 97
Quoted 10 lines
arch/arm/boot/dts/aspeed-bmc-facebook-cmm.dts new file +10
-0+ status = "okay"; +}; + +&uart3 { + status = "okay"; +}; + +&uart4 { + status = "okay"; +};
UARTs 1-4 should be explicitly pinmuxed. It's a bit fiddly as each of the UART lines has its own mux configuration, but it at least allows some flexibility (i.e. whether you just want Rx/Tx, or something more). See e.g. the uart1 node in arch/arm/boot/dts/aspeed-bmc-opp-romulus.dts.
Speaking of pinctrl, as it's an AST2500 system you'll probably want to add the following to ensure you have full control of the pinmux configuration:
&pinctrl {
aspeed,external-nodes = <&gfx &lhc>;
};arch/arm/boot/dts/aspeed-bmc-facebook-cmm.dts line 101
Quoted 4 lines
arch/arm/boot/dts/aspeed-bmc-facebook-cmm.dts new file +4
-0+ +&uart5 { + status = "okay"; +};
UART5 has fixed pins, so no pinctrl necessary here.
Quoted 202 lines
arch/arm/boot/dts/aspeed-bmc-facebook-cmm.dts new file +202
-0+ +&mac1 { + status = "okay"; + no-hw-checksum; + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_rgmii2_default &pinctrl_mdio2_default>; +}; + +&i2c0 { + status = "okay"; +}; + +&i2c1 { + status = "okay"; + + i2c-switch at 77 { + compatible = "nxp,pca9548"; + #address-cells = <1>; + #size-cells = <0>; + reg = <0x77>; + + imux16: i2c at 0 { + #address-cells = <1>; + #size-cells = <0>; + reg = <0>; + }; + + imux17: i2c at 1 { + #address-cells = <1>; + #size-cells = <0>; + reg = <1>; + }; + + imux18: i2c at 2 { + #address-cells = <1>; + #size-cells = <0>; + reg = <2>; + }; + + imux19: i2c at 3 { + #address-cells = <1>; + #size-cells = <0>; + reg = <3>; + }; + + imux20: i2c at 4 { + #address-cells = <1>; + #size-cells = <0>; + reg = <4>; + }; + + imux21: i2c at 5 { + #address-cells = <1>; + #size-cells = <0>; + reg = <5>; + }; + + imux22: i2c at 6 { + #address-cells = <1>; + #size-cells = <0>; + reg = <6>; + }; + + imux23: i2c at 7 { + #address-cells = <1>; + #size-cells = <0>; + reg = <7>; + }; + }; +}; + +&i2c2 { + status = "okay"; + + i2c-switch at 71 { + compatible = "nxp,pca9548"; + #address-cells = <1>; + #size-cells = <0>; + reg = <0x71>; + + imux24: i2c at 0 { + #address-cells = <1>; + #size-cells = <0>; + reg = <0>; + }; + + imux25: i2c at 1 { + #address-cells = <1>; + #size-cells = <0>; + reg = <1>; + }; + + imux26: i2c at 2 { + #address-cells = <1>; + #size-cells = <0>; + reg = <2>; + }; + + imux27: i2c at 3 { + #address-cells = <1>; + #size-cells = <0>; + reg = <3>; + }; + + imux28: i2c at 4 { + #address-cells = <1>; + #size-cells = <0>; + reg = <4>; + }; + + imux29: i2c at 5 { + #address-cells = <1>; + #size-cells = <0>; + reg = <5>; + }; + + imux30: i2c at 6 { + #address-cells = <1>; + #size-cells = <0>; + reg = <6>; + }; + + imux31: i2c at 7 { + #address-cells = <1>; + #size-cells = <0>; + reg = <7>; + }; + }; +}; + +&i2c3 { + status = "okay"; +}; + +&i2c4 { + status = "okay"; +}; + +&i2c5 { + status = "okay"; +}; + +&i2c6 { + status = "okay"; +}; + +&i2c7 { + status = "okay"; +}; + +&i2c8 { + status = "okay"; + + i2c-switch at 77 { + compatible = "nxp,pca9548"; + #address-cells = <1>; + #size-cells = <0>; + reg = <0x77>; + + imux32: i2c at 0 { + #address-cells = <1>; + #size-cells = <0>; + reg = <0>; + }; + + imux33: i2c at 1 { + #address-cells = <1>; + #size-cells = <0>; + reg = <1>; + }; + + imux34: i2c at 2 { + #address-cells = <1>; + #size-cells = <0>; + reg = <2>; + }; + + imux35: i2c at 3 { + #address-cells = <1>; + #size-cells = <0>; + reg = <3>; + }; + + imux36: i2c at 4 { + #address-cells = <1>; + #size-cells = <0>; + reg = <4>; + }; + + imux37: i2c at 5 { + #address-cells = <1>; + #size-cells = <0>; + reg = <5>; + }; + + imux38: i2c at 6 { + #address-cells = <1>; + #size-cells = <0>; + reg = <6>; + }; + + imux39: i2c at 7 {
arch/arm/boot/dts/aspeed-bmc-facebook-cmm.dts line 313
Quoted 10 lines
arch/arm/boot/dts/aspeed-bmc-facebook-cmm.dts new file +10
-0+ #address-cells = <1>; + #size-cells = <0>; + reg = <7>; + }; + }; +}; + +&i2c13 { + status = "okay"; +};
You said this in the commit message:
Quoted 3 lines
Note: I2C devices on Backpack Line Cards and Fabric Cards are not listed in the device tree file because Line/Fabric Cards may be unplugged.
It's not clear to me what this actually means, and I'm trying to reconcile it with enabling all of the i2c buses as I'm curious as to whether that's necessary.
Cheers,
Andrew
Quoted 7 lines
arch/arm/boot/dts/aspeed-bmc-facebook-cmm.dts new file +4
-0+ +&adc { + status = "okay"; +};Signature · 1 line
2.17.1
Quoted 5 lines · Andrew Jeffery
Quoted 5 lines
+&uart1 {
arch/arm/boot/dts/aspeed-bmc-facebook-cmm.dts new file +4
-0+ status = "okay"; +}; + +&uart3 {
Quoted 8 lines
arch/arm/boot/dts/aspeed-bmc-facebook-cmm.dts line 97
Quoted 6 lines
arch/arm/boot/dts/aspeed-bmc-facebook-cmm.dts new file +6
-0+ status = "okay"; +}; + +&uart4 { + status = "okay"; +};UARTs 1-4 should be explicitly pinmuxed. It's a bit fiddly as each of the UART lines has its own mux configuration, but it at least allows some flexibility (i.e. whether you just want Rx/Tx, or something more). See e.g. the uart1 node in
arch/arm/boot/dts/aspeed-bmc-opp-romulus.dts.
Thank you for pointing it out and I will fix it.
Quoted 6 lines
Speaking of pinctrl, as it's an AST2500 system you'll probably want to add the following to ensure you have full control of the pinmux configuration:
&pinctrl { aspeed,external-nodes = <&gfx &lhc>; };
Quoted 6 lines
arch/arm/boot/dts/aspeed-bmc-facebook-cmm.dts line 101
Quoted 4 lines
arch/arm/boot/dts/aspeed-bmc-facebook-cmm.dts new file +4
-0+ +&uart5 { + status = "okay"; +};UART5 has fixed pins, so no pinctrl necessary here.
Got it. Thank you.
Quoted 7 lines
You said this in the commit message:
Quoted 3 lines
Note: I2C devices on Backpack Line Cards and Fabric Cards are not listed in the device tree file because Line/Fabric Cards may be unplugged.
It's not clear to me what this actually means, and I'm trying to reconcile it with enabling all of the i2c buses as I'm curious as to whether that's necessary.
Sorry for the confusion. In general, all the i2c buses are initialized in device tree, but i2c leaf devices are created from user space because these i2c devices may be unplugged at boot time (which causes driver_probe failures). Let me refine the commit message and will send out updated patch soon.
Thanks,
Tao Ren
Quoted 40 lines · Tao Ren
Quoted 5 lines · Andrew Jeffery
Quoted 5 lines
+&uart1 {
arch/arm/boot/dts/aspeed-bmc-facebook-cmm.dts new file +4
-0+ status = "okay"; +}; + +&uart3 {Quoted 8 lines
arch/arm/boot/dts/aspeed-bmc-facebook-cmm.dts line 97
Quoted 6 lines
arch/arm/boot/dts/aspeed-bmc-facebook-cmm.dts new file +6
-0+ status = "okay"; +}; + +&uart4 { + status = "okay"; +};UARTs 1-4 should be explicitly pinmuxed. It's a bit fiddly as each of the UART lines has its own mux configuration, but it at least allows some flexibility (i.e. whether you just want Rx/Tx, or something more). See e.g. the uart1 node in
arch/arm/boot/dts/aspeed-bmc-opp-romulus.dts.Thank you for pointing it out and I will fix it.
Quoted 6 lines
Speaking of pinctrl, as it's an AST2500 system you'll probably want to add the following to ensure you have full control of the pinmux configuration:
&pinctrl { aspeed,external-nodes = <&gfx &lhc>; };Quoted 6 lines
arch/arm/boot/dts/aspeed-bmc-facebook-cmm.dts line 101
Quoted 4 lines
arch/arm/boot/dts/aspeed-bmc-facebook-cmm.dts new file +4
-0+ +&uart5 { + status = "okay"; +};UART5 has fixed pins, so no pinctrl necessary here.
Got it. Thank you.
Quoted 6 lines
You said this in the commit message:
Quoted 3 lines
Note: I2C devices on Backpack Line Cards and Fabric Cards are not listed in the device tree file because Line/Fabric Cards may be unplugged.
Quoted 6 lines
Quoted 1 line
It's not clear to me what this actually means, and I'm trying to reconcile it with enabling all of the i2c buses as I'm curious as to whether that's necessary.
Sorry for the confusion. In general, all the i2c buses are initialized in device tree, but i2c leaf devices are created from user space because these i2c devices may be unplugged at boot time (which causes
driver_probefailures).
This is what I was thinking, was just after some clarification.
Quoted 2 lines
Let me refine the commit message and will send
out updated patch soon.
Thanks.
Andrew
Quoted 3 lines
Thanks,
Tao Ren