ramips: move partitions into partition table node
[openwrt/staging/wigyori.git] / target / linux / ramips / dts / TL-WR840NV5.dts
1 /dts-v1/;
2
3 #include "mt7628an.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 compatible = "tplink,tl-wr840n-v5", "mediatek,mt7628an-soc";
10 model = "TP-Link TL-WR840N v5";
11
12 aliases {
13 led-status = &led_power_green;
14 };
15
16 chosen {
17 bootargs = "console=ttyS0,115200";
18 };
19
20 memory@0 {
21 device_type = "memory";
22 reg = <0x0 0x4000000>;
23 };
24
25 gpio-keys-polled {
26 compatible = "gpio-keys-polled";
27 poll-interval = <20>;
28
29 reset {
30 label = "reset";
31 gpios = <&gpio1 6 GPIO_ACTIVE_LOW>;
32 linux,code = <KEY_RESTART>;
33 };
34 };
35 /* LED used is dual-color,dual lead LED */
36 gpio-leds {
37 compatible = "gpio-leds";
38
39 led_power_green: power {
40 label = "tl-wr840n-v5:green:power";
41 gpios = <&gpio1 9 GPIO_ACTIVE_LOW>;
42 };
43
44 orange {
45 label = "tl-wr840n-v5:orange:power";
46 gpios = <&gpio1 11 GPIO_ACTIVE_LOW>;
47 };
48 };
49 };
50
51 &spi0 {
52 status = "okay";
53
54 m25p80@0 {
55 compatible = "jedec,spi-nor";
56 reg = <0>;
57 spi-max-frequency = <10000000>;
58 m25p,chunked-io = <32>;
59
60 partitions {
61 compatible = "fixed-partitions";
62 #address-cells = <1>;
63 #size-cells = <1>;
64
65 partition@0 {
66 label = "boot";
67 reg = <0x0 0x20000>;
68 read-only;
69 };
70
71 partition@20000 {
72 label = "firmware";
73 reg = <0x20000 0x3d0000>;
74 };
75
76 factory: partition@3f0000 {
77 label = "factory";
78 reg = <0x3f0000 0x10000>;
79 read-only;
80 };
81 };
82 };
83 };
84
85 &ehci {
86 status = "disabled";
87 };
88
89 &ohci {
90 status = "disabled";
91 };
92
93 &wmac {
94 status = "okay";
95 mtd-mac-address = <&factory 0xf100>;
96 mediatek,mtd-eeprom = <&factory 0x10000>;
97 };
98
99 &ethernet {
100 mtd-mac-address = <&factory 0xf100>;
101 mediatek,portmap = "wllll";
102 };
103
104 &pinctrl {
105 state_default: pinctrl0 {
106 gpio {
107 ralink,group = "p0led_an", "p2led_an", "perst";
108 ralink,function = "gpio";
109 };
110 };
111 };