1
0
Fork 0
mirror of https://github.com/Ysurac/openmptcprouter.git synced 2025-02-12 19:31:52 +00:00

Update Z8102AX DTS

This commit is contained in:
Ycarus (Yannick Chabanois) 2024-02-01 13:56:31 +01:00
parent 3747235464
commit 1a9c5efba9

View file

@ -8,7 +8,7 @@
/ { / {
model = "ZBT Z8102AX"; model = "ZBT Z8102AX";
compatible = "z8102ax", "mediatek,mt7981"; compatible = "z8102ax", "mediatek,mt7981", "zbtlink,zbt-z8102ax";
aliases { aliases {
serial0 = &uart0; serial0 = &uart0;
@ -16,10 +16,12 @@
led-failsafe = &led_status_red; led-failsafe = &led_status_red;
led-running = &led_status_green; led-running = &led_status_green;
led-upgrade = &led_status_green; led-upgrade = &led_status_green;
label-mac-device = &gmac0;
}; };
chosen { chosen {
stdout-path = "serial0:115200n8"; stdout-path = "serial0:115200n8";
bootargs = "earlycon=uart8250,mmio32,0x11002000 console=ttyS0,115200n8 loglevel=8";
}; };
gpio-keys { gpio-keys {
@ -44,43 +46,82 @@
led_status_red: red { led_status_red: red {
label = "red:status"; label = "red:status";
gpios = <&pio 9 GPIO_ACTIVE_LOW>; gpios = <&pio 9 GPIO_ACTIVE_HIGH>;
color = <LED_COLOR_ID_RED>;
function = LED_FUNCTION_STATUS;
}; };
led_status_green: green { led_status_green: green {
label = "green:status"; label = "green:status";
gpios = <&pio 10 GPIO_ACTIVE_LOW>; gpios = <&pio 10 GPIO_ACTIVE_LOW>;
color = <LED_COLOR_ID_GREEN>;
function = LED_FUNCTION_STATUS;
}; };
led_status_blue: blue { led_status_blue: blue {
label = "blue:status"; label = "blue:status";
gpios = <&pio 11 GPIO_ACTIVE_LOW>; gpios = <&pio 11 GPIO_ACTIVE_LOW>;
color = <LED_COLOR_ID_BLUE>;
function = LED_FUNCTION_STATUS;
}; };
led_status_4g: 4g { led_status_modem1: modem1 {
label = "4g:status"; label = "modem1:status";
gpios = <&pio 8 GPIO_ACTIVE_LOW>; gpios = <&pio 8 GPIO_ACTIVE_LOW>;
color = <LED_COLOR_ID_BLUE>;
function = LED_FUNCTION_USB;
function-enumerator = <0>;
}; };
led_status_4g2: 4g2 { led_status_modem2: modem2 {
label = "4g2:status"; label = "modem2:status";
gpios = <&pio 13 GPIO_ACTIVE_LOW>; gpios = <&pio 14 GPIO_ACTIVE_LOW>;
color = <LED_COLOR_ID_BLUE>;
function = LED_FUNCTION_USB;
function-enumerator = <1>;
}; };
}; };
watchdog { watchdog {
compatible = "linux,wdt-gpio"; compatible = "linux,wdt-gpio";
gpios = <&pio 2 GPIO_ACTIVE_HIGH>; gpios = <&pio 2 GPIO_ACTIVE_HIGH>;
hw_algo = "toggle"; hw_algo = "toggle";
hw_margin_ms = <1000>; hw_margin_ms = <1000>;
}; };
usb_vbus: regulator-usb-vbus {
compatible = "regulator-fixed"; gpio-export {
regulator-name = "usb_vbus"; compatible = "gpio-export";
regulator-min-microvolt = <5000000>; #size-cells = <0>;
regulator-max-microvolt = <5000000>;
gpio = <&pio 12 GPIO_ACTIVE_HIGH>; pcie {
enable-active-high; gpio-export,name = "pcie_power";
regulator-boot-on; gpio-export,output = <1>;
gpios = <&pio 3 GPIO_ACTIVE_HIGH>;
};
modem1 {
gpio-export,name = "modem1";
gpio-export,output = <1>;
gpios = <&pio 4 GPIO_ACTIVE_HIGH>;
};
modem2 {
gpio-export,name = "modem2";
gpio-export,output = <1>;
gpios = <&pio 5 GPIO_ACTIVE_HIGH>;
};
sim1 {
gpio-export,name = "sim1";
gpio-export,output = <1>;
gpios = <&pio 6 GPIO_ACTIVE_HIGH>;
};
sim2 {
gpio-export,name = "sim2";
gpio-export,output = <1>;
gpios = <&pio 7 GPIO_ACTIVE_HIGH>;
};
}; };
}; };
@ -136,6 +177,10 @@
spi-tx-buswidth = <4>; spi-tx-buswidth = <4>;
spi-rx-buswidth = <4>; spi-rx-buswidth = <4>;
mediatek,nmbm;
mediatek,bmt-max-ratio = <1>;
mediatek,bmt-max-reserved-blocks = <64>;
partitions { partitions {
compatible = "fixed-partitions"; compatible = "fixed-partitions";
#address-cells = <1>; #address-cells = <1>;
@ -159,7 +204,7 @@
}; };
partition@380000 { partition@380000 {
label = "fip"; label = "FIP";
reg = <0x0380000 0x0200000>; reg = <0x0380000 0x0200000>;
read-only; read-only;
}; };
@ -179,37 +224,26 @@
port@0 { port@0 {
reg = <0>; reg = <0>;
label = "lan1"; label = "lan1";
nvmem-cell-names = "mac-address";
nvmem-cells = <&macaddr_factory_004>;
mac-address-increment = <2>;
}; };
port@1 { port@1 {
reg = <1>; reg = <1>;
label = "lan2"; label = "lan2";
nvmem-cell-names = "mac-address";
nvmem-cells = <&macaddr_factory_004>;
mac-address-increment = <2>;
}; };
port@2 { port@2 {
reg = <2>; reg = <2>;
label = "lan3"; label = "lan3";
nvmem-cell-names = "mac-address";
nvmem-cells = <&macaddr_factory_004>;
mac-address-increment = <2>;
}; };
port@3 { port@3 {
reg = <3>; reg = <3>;
label = "lan4"; label = "lan4";
nvmem-cell-names = "mac-address";
nvmem-cells = <&macaddr_factory_004>;
mac-address-increment = <2>;
}; };
port@6 { port@6 {
reg = <6>; reg = <6>;
label = "cpu";
ethernet = <&gmac0>; ethernet = <&gmac0>;
phy-mode = "2500base-x"; phy-mode = "2500base-x";
@ -223,6 +257,23 @@
}; };
&pio { &pio {
gpio-line-names =
"wps",
"reset",
"watchdog",
"pcie",
"modem1",
"modem2",
"sim1",
"sim2",
"modem1_status",
"red_status",
"green_status",
"blue_status",
"",
"",
"modem2_status";
spi0_flash_pins: spi0-pins { spi0_flash_pins: spi0-pins {
mux { mux {
function = "spi"; function = "spi";
@ -251,22 +302,19 @@
status = "okay"; status = "okay";
}; };
&wifi {
status = "okay";
mediatek,mtd-eeprom = <&factory 0x0>;
};
&usb_phy { &usb_phy {
status = "okay"; status = "okay";
}; };
&xhci { &xhci {
vbus-supply = <&usb_vbus>;
status = "okay"; status = "okay";
}; };
&wifi {
status = "okay";
mediatek,mtd-eeprom = <&factory 0x0>;
};
&factory { &factory {
compatible = "nvmem-cells"; compatible = "nvmem-cells";
#address-cells = <1>; #address-cells = <1>;