bcm53xx: basic support for Seama format in sysupgrade
[oweals/openwrt.git] / target / linux / bcm53xx / patches-4.4 / 130-ARM-BCM5301X-Add-DT-for-D-Link-DIR-885L.patch
1 From 3ea03a9d512ca19d59315492230e954a1653ff6e Mon Sep 17 00:00:00 2001
2 From: =?UTF-8?q?Rafa=C5=82=20Mi=C5=82ecki?= <zajec5@gmail.com>
3 Date: Tue, 26 Jan 2016 23:35:16 +0100
4 Subject: [PATCH] ARM: BCM5301X: Add DT for D-Link DIR-885L
5 MIME-Version: 1.0
6 Content-Type: text/plain; charset=UTF-8
7 Content-Transfer-Encoding: 8bit
8
9 It's device based on BCM47094 which is quite similar to BCM4709 except
10 for higher CPU frequency. This device has 2 flash memories, it boots
11 from serial one and stores firmware on NAND. Other than that we define
12 standard stuff like LEDs, buttons and UART.
13
14 Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
15 Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
16 ---
17  arch/arm/boot/dts/Makefile                    |   1 +
18  arch/arm/boot/dts/bcm47094-dlink-dir-885l.dts | 111 ++++++++++++++++++++++++++
19  2 files changed, 112 insertions(+)
20  create mode 100644 arch/arm/boot/dts/bcm47094-dlink-dir-885l.dts
21
22 --- a/arch/arm/boot/dts/Makefile
23 +++ b/arch/arm/boot/dts/Makefile
24 @@ -76,6 +76,7 @@ dtb-$(CONFIG_ARCH_BCM_5301X) += \
25         bcm4709-buffalo-wxr-1900dhp.dtb \
26         bcm4709-netgear-r7000.dtb \
27         bcm4709-netgear-r8000.dtb \
28 +       bcm47094-dlink-dir-885l.dtb \
29         bcm94708.dtb \
30         bcm94709.dtb \
31         bcm953012k.dtb
32 --- /dev/null
33 +++ b/arch/arm/boot/dts/bcm47094-dlink-dir-885l.dts
34 @@ -0,0 +1,111 @@
35 +/*
36 + * Broadcom BCM470X / BCM5301X ARM platform code.
37 + * DTS for D-Link DIR-885L
38 + *
39 + * Copyright (C) 2016 Rafał Miłecki <zajec5@gmail.com>
40 + *
41 + * Licensed under the GNU/GPL. See COPYING for details.
42 + */
43 +
44 +/dts-v1/;
45 +
46 +#include "bcm4708.dtsi"
47 +#include "bcm5301x-nand-cs0-bch8.dtsi"
48 +
49 +/ {
50 +       compatible = "dlink,dir-885l", "brcm,bcm47094", "brcm,bcm4708";
51 +       model = "D-Link DIR-885L";
52 +
53 +       chosen {
54 +               bootargs = "console=ttyS0,115200";
55 +       };
56 +
57 +       memory {
58 +               reg = <0x00000000 0x08000000>;
59 +       };
60 +
61 +       nand: nand@18028000 {
62 +               nandcs@0 {
63 +                       partition@0 {
64 +                               label = "firmware";
65 +                               reg = <0x00000000 0x08000000>;
66 +                       };
67 +               };
68 +       };
69 +
70 +       leds {
71 +               compatible = "gpio-leds";
72 +
73 +               power-white {
74 +                       label = "bcm53xx:white:power";
75 +                       gpios = <&chipcommon 0 GPIO_ACTIVE_LOW>;
76 +                       linux,default-trigger = "default-on";
77 +               };
78 +
79 +               wan-white {
80 +                       label = "bcm53xx:white:wan";
81 +                       gpios = <&chipcommon 1 GPIO_ACTIVE_LOW>;
82 +                       linux,default-trigger = "default-off";
83 +               };
84 +
85 +               power-amber {
86 +                       label = "bcm53xx:amber:power";
87 +                       gpios = <&chipcommon 2 GPIO_ACTIVE_LOW>;
88 +                       linux,default-trigger = "default-off";
89 +               };
90 +
91 +               wan-amber {
92 +                       label = "bcm53xx:amber:wan";
93 +                       gpios = <&chipcommon 3 GPIO_ACTIVE_LOW>;
94 +                       linux,default-trigger = "default-off";
95 +               };
96 +
97 +               usb3-white {
98 +                       label = "bcm53xx:white:usb3";
99 +                       gpios = <&chipcommon 8 GPIO_ACTIVE_LOW>;
100 +                       linux,default-trigger = "default-off";
101 +               };
102 +
103 +               2ghz {
104 +                       label = "bcm53xx:white:2ghz";
105 +                       gpios = <&chipcommon 13 GPIO_ACTIVE_LOW>;
106 +                       linux,default-trigger = "default-off";
107 +               };
108 +
109 +               5ghz {
110 +                       label = "bcm53xx:white:5ghz";
111 +                       gpios = <&chipcommon 14 GPIO_ACTIVE_LOW>;
112 +                       linux,default-trigger = "default-off";
113 +               };
114 +       };
115 +
116 +       gpio-keys {
117 +               compatible = "gpio-keys";
118 +               #address-cells = <1>;
119 +               #size-cells = <0>;
120 +
121 +               wps {
122 +                       label = "WPS";
123 +                       linux,code = <KEY_WPS_BUTTON>;
124 +                       gpios = <&chipcommon 7 GPIO_ACTIVE_LOW>;
125 +               };
126 +
127 +               /* Switch: router / extender */
128 +               extender {
129 +                       label = "Extender";
130 +                       linux,code = <BTN_0>;
131 +                       gpios = <&chipcommon 10 GPIO_ACTIVE_LOW>;
132 +               };
133 +
134 +               restart {
135 +                       label = "Reset";
136 +                       linux,code = <KEY_RESTART>;
137 +                       gpios = <&chipcommon 17 GPIO_ACTIVE_LOW>;
138 +               };
139 +       };
140 +};
141 +
142 +&uart0 {
143 +       status = "okay";
144 +       clock-frequency = <125000000>;
145 +};