| b.liu | e958203 | 2025-04-17 19:18:16 +0800 | [diff] [blame] | 1 | #include "mt7620a.dtsi" |
| 2 | |
| 3 | #include <dt-bindings/gpio/gpio.h> |
| 4 | #include <dt-bindings/input/input.h> |
| 5 | |
| 6 | / { |
| 7 | compatible = "microduino,microwrt", "ralink,mt7620a-soc"; |
| 8 | model = "Microduino MicroWRT"; |
| 9 | |
| 10 | chosen { |
| 11 | bootargs = "console=ttyS0,115200"; |
| 12 | }; |
| 13 | |
| 14 | keys { |
| 15 | compatible = "gpio-keys"; |
| 16 | |
| 17 | reset { |
| 18 | label = "reset"; |
| 19 | gpios = <&gpio0 1 GPIO_ACTIVE_LOW>; |
| 20 | linux,code = <KEY_RESTART>; |
| 21 | }; |
| 22 | |
| 23 | wps { |
| 24 | label = "wps"; |
| 25 | gpios = <&gpio0 2 GPIO_ACTIVE_LOW>; |
| 26 | linux,code = <KEY_WPS_BUTTON>; |
| 27 | }; |
| 28 | }; |
| 29 | }; |
| 30 | |
| 31 | &spi0 { |
| 32 | status = "okay"; |
| 33 | |
| 34 | flash@0 { |
| 35 | compatible = "jedec,spi-nor"; |
| 36 | reg = <0>; |
| 37 | spi-max-frequency = <10000000>; |
| 38 | |
| 39 | partitions { |
| 40 | compatible = "fixed-partitions"; |
| 41 | #address-cells = <1>; |
| 42 | #size-cells = <1>; |
| 43 | |
| 44 | partition@0 { |
| 45 | label = "u-boot"; |
| 46 | reg = <0x0 0x20000>; |
| 47 | read-only; |
| 48 | }; |
| 49 | |
| 50 | partition@20000 { |
| 51 | label = "u-boot-env"; |
| 52 | reg = <0x20000 0x10000>; |
| 53 | read-only; |
| 54 | }; |
| 55 | |
| 56 | factory: partition@30000 { |
| 57 | label = "factory"; |
| 58 | reg = <0x30000 0x10000>; |
| 59 | read-only; |
| 60 | }; |
| 61 | |
| 62 | partition@40000 { |
| 63 | compatible = "denx,uimage"; |
| 64 | label = "firmware"; |
| 65 | reg = <0x40000 0xfc0000>; |
| 66 | }; |
| 67 | }; |
| 68 | }; |
| 69 | }; |
| 70 | |
| 71 | &ehci { |
| 72 | status = "okay"; |
| 73 | }; |
| 74 | |
| 75 | &ohci { |
| 76 | status = "okay"; |
| 77 | }; |
| 78 | |
| 79 | ðernet { |
| 80 | pinctrl-names = "default"; |
| 81 | pinctrl-0 = <&ephy_pins>; |
| 82 | |
| 83 | mtd-mac-address = <&factory 0x4>; |
| 84 | |
| 85 | mediatek,portmap = "llllw"; |
| 86 | }; |
| 87 | |
| 88 | &wmac { |
| 89 | ralink,mtd-eeprom = <&factory 0x0>; |
| 90 | }; |
| 91 | |
| 92 | &state_default { |
| 93 | default { |
| 94 | groups = "wled", "i2c", "wdt", "uartf"; |
| 95 | function = "gpio"; |
| 96 | }; |
| 97 | }; |