2015-12-11 15:04:13 +00:00
|
|
|
#include "mt7621.dtsi"
|
|
|
|
|
2017-07-29 10:14:07 +08:00
|
|
|
#include <dt-bindings/gpio/gpio.h>
|
2016-11-11 22:43:08 +01:00
|
|
|
#include <dt-bindings/input/input.h>
|
|
|
|
|
2015-12-11 15:04:13 +00:00
|
|
|
/ {
|
2017-07-28 00:49:06 +08:00
|
|
|
compatible = "mqmaker,witi", "mediatek,mt7621-soc";
|
2019-07-10 23:57:36 +08:00
|
|
|
model = "MQmaker WiTi";
|
2015-12-11 15:04:13 +00:00
|
|
|
|
2018-12-30 12:17:25 +01:00
|
|
|
keys {
|
2019-09-20 14:03:02 +02:00
|
|
|
compatible = "gpio-keys";
|
2015-12-11 15:04:13 +00:00
|
|
|
|
|
|
|
reset {
|
|
|
|
label = "reset";
|
2020-03-04 05:22:24 +08:00
|
|
|
gpios = <&gpio 18 GPIO_ACTIVE_LOW>;
|
2016-11-11 22:43:08 +01:00
|
|
|
linux,code = <KEY_RESTART>;
|
2015-12-11 15:04:13 +00:00
|
|
|
};
|
|
|
|
};
|
2016-05-10 13:41:46 +03:00
|
|
|
};
|
2015-12-11 15:04:13 +00:00
|
|
|
|
2020-05-08 21:00:48 +09:00
|
|
|
&i2c {
|
|
|
|
status = "okay";
|
|
|
|
|
|
|
|
rtc@51 {
|
|
|
|
status = "okay";
|
|
|
|
compatible = "nxp,pcf8563";
|
|
|
|
reg = <0x51>;
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2016-05-10 13:41:46 +03:00
|
|
|
&sdhci {
|
|
|
|
status = "okay";
|
|
|
|
};
|
|
|
|
|
|
|
|
&spi0 {
|
|
|
|
status = "okay";
|
|
|
|
|
2020-05-07 23:15:27 +09:00
|
|
|
flash@0 {
|
2016-05-10 13:41:46 +03:00
|
|
|
compatible = "jedec,spi-nor";
|
2016-05-14 19:22:08 +02:00
|
|
|
reg = <0>;
|
2016-05-10 13:41:46 +03:00
|
|
|
spi-max-frequency = <10000000>;
|
|
|
|
|
2018-08-01 21:32:34 +01:00
|
|
|
partitions {
|
|
|
|
compatible = "fixed-partitions";
|
|
|
|
#address-cells = <1>;
|
|
|
|
#size-cells = <1>;
|
2016-05-10 13:41:46 +03:00
|
|
|
|
2018-08-01 21:32:34 +01:00
|
|
|
partition@0 {
|
|
|
|
label = "u-boot";
|
|
|
|
reg = <0x0 0x30000>;
|
|
|
|
read-only;
|
|
|
|
};
|
2016-05-10 13:41:46 +03:00
|
|
|
|
2018-08-01 21:32:34 +01:00
|
|
|
partition@30000 {
|
|
|
|
label = "u-boot-env";
|
|
|
|
reg = <0x30000 0x10000>;
|
|
|
|
read-only;
|
|
|
|
};
|
|
|
|
|
2024-02-17 22:10:10 +08:00
|
|
|
partition@40000 {
|
2018-08-01 21:32:34 +01:00
|
|
|
label = "factory";
|
|
|
|
reg = <0x40000 0x10000>;
|
2023-10-02 10:12:02 +08:00
|
|
|
|
2023-11-07 15:55:58 -08:00
|
|
|
nvmem-layout {
|
|
|
|
compatible = "fixed-layout";
|
|
|
|
#address-cells = <1>;
|
|
|
|
#size-cells = <1>;
|
2023-10-02 10:12:02 +08:00
|
|
|
|
2023-11-07 15:55:58 -08:00
|
|
|
eeprom_factory_0: eeprom@0 {
|
|
|
|
reg = <0x0 0x200>;
|
|
|
|
};
|
|
|
|
|
|
|
|
eeprom_factory_8000: eeprom@8000 {
|
|
|
|
reg = <0x8000 0x200>;
|
|
|
|
};
|
2023-10-02 10:12:02 +08:00
|
|
|
|
2023-11-07 15:55:58 -08:00
|
|
|
macaddr_factory_e000: macaddr@e000 {
|
2023-11-07 19:39:00 -08:00
|
|
|
compatible = "mac-base";
|
2023-11-07 15:55:58 -08:00
|
|
|
reg = <0xe000 0x6>;
|
2023-11-07 19:39:00 -08:00
|
|
|
#nvmem-cell-cells = <1>;
|
2023-11-07 15:55:58 -08:00
|
|
|
};
|
2023-10-02 10:12:02 +08:00
|
|
|
};
|
2018-08-01 21:32:34 +01:00
|
|
|
};
|
2016-05-10 13:41:46 +03:00
|
|
|
|
2018-08-01 21:32:34 +01:00
|
|
|
partition@50000 {
|
2018-11-28 12:28:35 +09:00
|
|
|
compatible = "denx,uimage";
|
2018-08-01 21:32:34 +01:00
|
|
|
label = "firmware";
|
|
|
|
reg = <0x50000 0xfb0000>;
|
|
|
|
};
|
2016-05-10 13:41:46 +03:00
|
|
|
};
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
&pcie {
|
|
|
|
status = "okay";
|
2018-07-21 16:19:46 +02:00
|
|
|
};
|
2016-05-10 13:41:46 +03:00
|
|
|
|
2018-07-21 16:19:46 +02:00
|
|
|
&pcie0 {
|
|
|
|
mt76@0,0 {
|
|
|
|
reg = <0x0000 0 0 0 0>;
|
|
|
|
ieee80211-freq-limit = <5000000 6000000>;
|
2023-11-07 19:39:00 -08:00
|
|
|
nvmem-cells = <&eeprom_factory_8000>, <&macaddr_factory_e000 0>;
|
2023-10-02 10:12:02 +08:00
|
|
|
nvmem-cell-names = "eeprom", "mac-address";
|
2016-05-10 13:41:46 +03:00
|
|
|
};
|
2018-07-21 16:19:46 +02:00
|
|
|
};
|
2016-05-10 13:41:46 +03:00
|
|
|
|
2018-07-21 16:19:46 +02:00
|
|
|
&pcie1 {
|
|
|
|
mt76@0,0 {
|
|
|
|
reg = <0x0000 0 0 0 0>;
|
|
|
|
ieee80211-freq-limit = <2400000 2500000>;
|
2023-11-07 19:39:00 -08:00
|
|
|
nvmem-cells = <&eeprom_factory_0>, <&macaddr_factory_e000 0>;
|
2023-10-02 10:12:02 +08:00
|
|
|
nvmem-cell-names = "eeprom", "mac-address";
|
2016-05-10 13:41:46 +03:00
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2020-03-18 23:38:58 +08:00
|
|
|
&gmac0 {
|
2023-11-07 19:39:00 -08:00
|
|
|
nvmem-cells = <&macaddr_factory_e000 0>;
|
2021-04-02 23:50:02 +02:00
|
|
|
nvmem-cell-names = "mac-address";
|
2016-05-10 13:41:46 +03:00
|
|
|
};
|
|
|
|
|
2022-07-06 01:20:32 +03:00
|
|
|
&gmac1 {
|
|
|
|
status = "okay";
|
2023-06-17 21:59:26 +03:00
|
|
|
label = "wan2";
|
|
|
|
phy-mode = "rgmii-rxid";
|
|
|
|
phy-handle = <ðphy5>;
|
2022-07-06 01:20:32 +03:00
|
|
|
|
2023-11-07 19:39:00 -08:00
|
|
|
nvmem-cells = <&macaddr_factory_e000 1>;
|
2022-07-06 01:20:32 +03:00
|
|
|
nvmem-cell-names = "mac-address";
|
|
|
|
};
|
|
|
|
|
|
|
|
&mdio {
|
2023-06-17 21:59:26 +03:00
|
|
|
ethphy5: ethernet-phy@5 {
|
|
|
|
reg = <5>;
|
2022-07-06 01:20:32 +03:00
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2020-03-18 23:38:58 +08:00
|
|
|
&switch0 {
|
|
|
|
ports {
|
|
|
|
port@0 {
|
|
|
|
status = "okay";
|
|
|
|
label = "lan1";
|
|
|
|
};
|
|
|
|
|
|
|
|
port@1 {
|
|
|
|
status = "okay";
|
|
|
|
label = "lan2";
|
|
|
|
};
|
|
|
|
|
|
|
|
port@2 {
|
|
|
|
status = "okay";
|
|
|
|
label = "lan3";
|
|
|
|
};
|
|
|
|
|
|
|
|
port@3 {
|
|
|
|
status = "okay";
|
|
|
|
label = "lan4";
|
|
|
|
};
|
2023-06-17 21:59:26 +03:00
|
|
|
|
|
|
|
port@4 {
|
|
|
|
status = "okay";
|
|
|
|
label = "wan1";
|
|
|
|
|
2023-11-07 19:39:00 -08:00
|
|
|
nvmem-cells = <&macaddr_factory_e000 1>;
|
2023-06-17 21:59:26 +03:00
|
|
|
nvmem-cell-names = "mac-address";
|
|
|
|
};
|
2020-03-18 23:38:58 +08:00
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2019-12-22 21:26:01 +01:00
|
|
|
&state_default {
|
|
|
|
gpio {
|
2020-04-04 14:52:12 +08:00
|
|
|
groups = "wdt";
|
2020-03-13 21:27:03 +08:00
|
|
|
function = "gpio";
|
2015-12-11 15:04:13 +00:00
|
|
|
};
|
|
|
|
};
|