ipq806x: set v4.9 as default
[openwrt/openwrt.git] / target / linux / ipq806x / patches-4.4 / 707-ARM-dts-qcom-add-mdio-nodes-to-ap148-db149.patch
1 From e81de9d28bd0421c236df322872e64edf4ee1852 Mon Sep 17 00:00:00 2001
2 From: Mathieu Olivari <mathieu@codeaurora.org>
3 Date: Mon, 11 May 2015 16:32:09 -0700
4 Subject: [PATCH 7/8] ARM: dts: qcom: add mdio nodes to ap148 & db149
5
6 Signed-off-by: Mathieu Olivari <mathieu@codeaurora.org>
7 ---
8 arch/arm/boot/dts/qcom-ipq8064-ap148.dts | 40 ++++++++++++++++++++++++++-
9 arch/arm/boot/dts/qcom-ipq8064-db149.dts | 46 ++++++++++++++++++++++++++++++++
10 2 files changed, 85 insertions(+), 1 deletion(-)
11
12 --- a/arch/arm/boot/dts/qcom-ipq8064-ap148.dts
13 +++ b/arch/arm/boot/dts/qcom-ipq8064-ap148.dts
14 @@ -19,8 +19,9 @@
15 };
16 };
17
18 - alias {
19 + aliases {
20 serial0 = &uart4;
21 + mdio-gpio0 = &mdio0;
22 };
23
24 chosen {
25 @@ -65,6 +66,15 @@
26 bias-bus-hold;
27 };
28 };
29 +
30 + mdio0_pins: mdio0_pins {
31 + mux {
32 + pins = "gpio0", "gpio1";
33 + function = "gpio";
34 + drive-strength = <8>;
35 + bias-disable;
36 + };
37 + };
38 };
39
40 gsbi@16300000 {
41 @@ -160,6 +170,34 @@
42
43 linux,part-probe = "qcom-smem";
44 };
45 +
46 + mdio0: mdio {
47 + compatible = "virtual,mdio-gpio";
48 + #address-cells = <1>;
49 + #size-cells = <0>;
50 + gpios = <&qcom_pinmux 1 0 &qcom_pinmux 0 0>;
51 + pinctrl-0 = <&mdio0_pins>;
52 + pinctrl-names = "default";
53 +
54 + phy0: ethernet-phy@0 {
55 + device_type = "ethernet-phy";
56 + reg = <0>;
57 + qca,ar8327-initvals = <
58 + 0x00004 0x7600000 /* PAD0_MODE */
59 + 0x00008 0x1000000 /* PAD5_MODE */
60 + 0x0000c 0x80 /* PAD6_MODE */
61 + 0x000e4 0x6a545 /* MAC_POWER_SEL */
62 + 0x000e0 0xc74164de /* SGMII_CTRL */
63 + 0x0007c 0x4e /* PORT0_STATUS */
64 + 0x00094 0x4e /* PORT6_STATUS */
65 + >;
66 + };
67 +
68 + phy4: ethernet-phy@4 {
69 + device_type = "ethernet-phy";
70 + reg = <4>;
71 + };
72 + };
73 };
74 };
75
76 --- a/arch/arm/boot/dts/qcom-ipq8064-db149.dts
77 +++ b/arch/arm/boot/dts/qcom-ipq8064-db149.dts
78 @@ -16,6 +16,7 @@
79
80 alias {
81 serial0 = &uart2;
82 + mdio-gpio0 = &mdio0;
83 };
84
85 chosen {
86 @@ -38,6 +39,15 @@
87 bias-none;
88 };
89 };
90 +
91 + mdio0_pins: mdio0_pins {
92 + mux {
93 + pins = "gpio0", "gpio1";
94 + function = "gpio";
95 + drive-strength = <8>;
96 + bias-disable;
97 + };
98 + };
99 };
100
101 gsbi2: gsbi@12480000 {
102 @@ -140,5 +150,44 @@
103 pcie2: pci@1b900000 {
104 status = "ok";
105 };
106 +
107 + mdio0: mdio {
108 + compatible = "virtual,mdio-gpio";
109 + #address-cells = <1>;
110 + #size-cells = <0>;
111 + gpios = <&qcom_pinmux 1 0 &qcom_pinmux 0 0>;
112 +
113 + pinctrl-0 = <&mdio0_pins>;
114 + pinctrl-names = "default";
115 +
116 + phy0: ethernet-phy@0 {
117 + device_type = "ethernet-phy";
118 + reg = <0>;
119 + qca,ar8327-initvals = <
120 + 0x00004 0x7600000 /* PAD0_MODE */
121 + 0x00008 0x1000000 /* PAD5_MODE */
122 + 0x0000c 0x80 /* PAD6_MODE */
123 + 0x000e4 0x6a545 /* MAC_POWER_SEL */
124 + 0x000e0 0xc74164de /* SGMII_CTRL */
125 + 0x0007c 0x4e /* PORT0_STATUS */
126 + 0x00094 0x4e /* PORT6_STATUS */
127 + >;
128 + };
129 +
130 + phy4: ethernet-phy@4 {
131 + device_type = "ethernet-phy";
132 + reg = <4>;
133 + };
134 +
135 + phy6: ethernet-phy@6 {
136 + device_type = "ethernet-phy";
137 + reg = <6>;
138 + };
139 +
140 + phy7: ethernet-phy@7 {
141 + device_type = "ethernet-phy";
142 + reg = <7>;
143 + };
144 + };
145 };
146 };