bcm53xx: backport BCM5301X patches
[openwrt/staging/dedeckeh.git] / target / linux / bcm53xx / patches-4.4 / 047-0016-ARM-dts-BCM5301X-Add-support-for-TP-LINK-Archer-C5-V.patch
1 From d6661da842bbeec2082b7263c9e682792e7951a9 Mon Sep 17 00:00:00 2001
2 From: =?UTF-8?q?Rafa=C5=82=20Mi=C5=82ecki?= <rafal@milecki.pl>
3 Date: Tue, 14 Mar 2017 11:39:41 +0100
4 Subject: [PATCH] ARM: dts: BCM5301X: Add support for TP-LINK Archer C5 V2
5 MIME-Version: 1.0
6 Content-Type: text/plain; charset=UTF-8
7 Content-Transfer-Encoding: 8bit
8
9 This is BCM47081A0 based home router with BCM43217 and BCM4352 wireless
10 chipsets.
11
12 Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
13 Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
14 ---
15 arch/arm/boot/dts/Makefile | 1 +
16 arch/arm/boot/dts/bcm47081-tplink-archer-c5-v2.dts | 98 ++++++++++++++++++++++
17 2 files changed, 99 insertions(+)
18 create mode 100644 arch/arm/boot/dts/bcm47081-tplink-archer-c5-v2.dts
19
20 --- a/arch/arm/boot/dts/Makefile
21 +++ b/arch/arm/boot/dts/Makefile
22 @@ -76,6 +76,7 @@ dtb-$(CONFIG_ARCH_BCM_5301X) += \
23 bcm47081-buffalo-wzr-900dhp.dtb \
24 bcm47081-luxul-xap-1410.dtb \
25 bcm47081-luxul-xwr-1200.dtb \
26 + bcm47081-tplink-archer-c5-v2.dtb \
27 bcm4709-asus-rt-ac87u.dtb \
28 bcm4709-buffalo-wxr-1900dhp.dtb \
29 bcm4709-linksys-ea9200.dtb \
30 --- /dev/null
31 +++ b/arch/arm/boot/dts/bcm47081-tplink-archer-c5-v2.dts
32 @@ -0,0 +1,98 @@
33 +/*
34 + * Copyright (C) 2017 Rafał Miłecki <rafal@milecki.pl>
35 + *
36 + * Licensed under the ISC license.
37 + */
38 +
39 +/dts-v1/;
40 +
41 +#include "bcm47081.dtsi"
42 +
43 +/ {
44 + compatible = "tplink,archer-c5-v2", "brcm,bcm47081", "brcm,bcm4708";
45 + model = "TP-LINK Archer C5 V2";
46 +
47 + chosen {
48 + bootargs = "earlycon";
49 + };
50 +
51 + memory {
52 + reg = <0x00000000 0x08000000>;
53 + };
54 +
55 + leds {
56 + compatible = "gpio-leds";
57 +
58 + 2ghz {
59 + label = "bcm53xx:green:2ghz";
60 + gpios = <&chipcommon 0 GPIO_ACTIVE_HIGH>;
61 + };
62 +
63 + lan {
64 + label = "bcm53xx:green:lan";
65 + gpios = <&chipcommon 1 GPIO_ACTIVE_HIGH>;
66 + };
67 +
68 + usb2-port1 {
69 + label = "bcm53xx:green:usb2-port1";
70 + gpios = <&chipcommon 2 GPIO_ACTIVE_HIGH>;
71 + };
72 +
73 + power {
74 + label = "bcm53xx:green:power";
75 + gpios = <&chipcommon 4 GPIO_ACTIVE_HIGH>;
76 + linux,default-trigger = "default-on";
77 + };
78 +
79 + wan-green {
80 + label = "bcm53xx:green:wan";
81 + gpios = <&chipcommon 5 GPIO_ACTIVE_HIGH>;
82 + };
83 +
84 + wps {
85 + label = "bcm53xx:green:wps";
86 + gpios = <&chipcommon 6 GPIO_ACTIVE_HIGH>;
87 + };
88 +
89 + wan-amber {
90 + label = "bcm53xx:amber:wan";
91 + gpios = <&chipcommon 8 GPIO_ACTIVE_HIGH>;
92 + };
93 +
94 + 5ghz {
95 + label = "bcm53xx:green:5ghz";
96 + gpios = <&chipcommon 12 GPIO_ACTIVE_HIGH>;
97 + };
98 +
99 + usb2-port2 {
100 + label = "bcm53xx:green:usb2-port2";
101 + gpios = <&chipcommon 13 GPIO_ACTIVE_HIGH>;
102 + };
103 + };
104 +
105 + gpio-keys {
106 + compatible = "gpio-keys";
107 + #address-cells = <1>;
108 + #size-cells = <0>;
109 +
110 + rfkill {
111 + label = "WiFi";
112 + linux,code = <KEY_RFKILL>;
113 + gpios = <&chipcommon 3 GPIO_ACTIVE_LOW>;
114 + };
115 +
116 + restart {
117 + label = "Reset";
118 + linux,code = <KEY_RESTART>;
119 + gpios = <&chipcommon 7 GPIO_ACTIVE_LOW>;
120 + };
121 + };
122 +};
123 +
124 +&spi_nor {
125 + status = "okay";
126 +};
127 +
128 +&usb2 {
129 + vcc-gpio = <&chipcommon 9 GPIO_ACTIVE_HIGH>;
130 +};