384e1467c234303bc211f8ce97a2190ccd617291
[openwrt/openwrt.git] / target / linux / ramips / dts / rt3050_jcg_jhr-n805r.dts
1 #include "rt3050.dtsi"
2
3 #include <dt-bindings/gpio/gpio.h>
4 #include <dt-bindings/input/input.h>
5
6 / {
7 compatible = "jcg,jhr-n805r", "ralink,rt3050-soc";
8 model = "JCG JHR-N805R";
9
10 aliases {
11 led-boot = &led_system;
12 led-failsafe = &led_system;
13 led-running = &led_system;
14 led-upgrade = &led_system;
15 };
16
17 leds {
18 compatible = "gpio-leds";
19
20 led_system: system {
21 label = "blue:system";
22 gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
23 };
24 };
25
26 keys {
27 compatible = "gpio-keys-polled";
28 poll-interval = <20>;
29
30 reset {
31 label = "reset";
32 gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
33 linux,code = <KEY_RESTART>;
34 };
35 };
36 };
37
38 &state_default {
39 gpio {
40 groups = "i2c", "jtag", "rgmii", "mdio", "uartf";
41 function = "gpio";
42 };
43 };
44
45 &spi0 {
46 status = "okay";
47
48 flash@0 {
49 compatible = "jedec,spi-nor";
50 reg = <0>;
51 spi-max-frequency = <10000000>;
52
53 partitions {
54 compatible = "fixed-partitions";
55 #address-cells = <1>;
56 #size-cells = <1>;
57
58 partition@0 {
59 label = "u-boot";
60 reg = <0x0 0x30000>;
61 read-only;
62 };
63
64 partition@30000 {
65 label = "u-boot-env";
66 reg = <0x30000 0x10000>;
67 read-only;
68 };
69
70 factory: partition@40000 {
71 compatible = "nvmem-cells";
72 label = "factory";
73 reg = <0x40000 0x10000>;
74 #address-cells = <1>;
75 #size-cells = <1>;
76 read-only;
77
78 eeprom_factory_0: eeprom@0 {
79 reg = <0x0 0x200>;
80 };
81
82 macaddr_factory_2e: macaddr@2e {
83 reg = <0x2e 0x6>;
84 };
85 };
86
87 partition@50000 {
88 compatible = "denx,uimage";
89 label = "firmware";
90 reg = <0x50000 0x3b0000>;
91 };
92 };
93 };
94 };
95
96 &ethernet {
97 nvmem-cells = <&macaddr_factory_2e>;
98 nvmem-cell-names = "mac-address";
99 };
100
101 &esw {
102 mediatek,portmap = <0x3e>;
103 };
104
105 &wmac {
106 nvmem-cells = <&eeprom_factory_0>;
107 nvmem-cell-names = "eeprom";
108 };