]>
Commit | Line | Data |
---|---|---|
461fadcb AF |
1 | /* |
2 | * Copyright 2014 Zoltan HERPAI | |
3 | * Zoltan HERPAI <wigyori@uid0.hu> | |
c1c5269b | 4 | * Arne Fitzenreiter <arne_f@ipfire.org> |
461fadcb AF |
5 | * |
6 | * The code contained herein is licensed under the GNU General Public | |
7 | * License. You may obtain a copy of the GNU General Public License | |
8 | * Version 2 or later at the following locations: | |
9 | * | |
10 | * http://www.opensource.org/licenses/gpl-license.html | |
11 | * http://www.gnu.org/copyleft/gpl.html | |
12 | */ | |
13 | ||
14 | /dts-v1/; | |
15 | /include/ "sun7i-a20.dtsi" | |
d3e8b2a0 | 16 | /include/ "sunxi-common-regulators.dtsi" |
461fadcb AF |
17 | #include <dt-bindings/input/input.h> |
18 | ||
19 | / { | |
c1c5269b | 20 | model = "LeMaker BananaPi"; |
461fadcb AF |
21 | compatible = "lemaker,bananapi", "allwinner,sun7i-a20"; |
22 | ||
23 | aliases { | |
24 | spi0 = &spi1; | |
25 | spi1 = &spi2; | |
26 | }; | |
27 | ||
28 | soc@01c00000 { | |
29 | spi1: spi@01c06000 { | |
30 | pinctrl-names = "default"; | |
31 | pinctrl-0 = <&spi1_pins_a>; | |
32 | status = "okay"; | |
33 | }; | |
34 | ||
35 | spi2: spi@01c17000 { | |
36 | pinctrl-names = "default"; | |
37 | pinctrl-0 = <&spi2_pins_a>; | |
38 | status = "okay"; | |
39 | }; | |
40 | ||
41 | mmc0: mmc@01c0f000 { | |
42 | pinctrl-names = "default", "default"; | |
43 | pinctrl-0 = <&mmc0_pins_a>; | |
44 | pinctrl-1 = <&mmc0_cd_pin_bananapi>; | |
45 | cd-gpios = <&pio 7 10 0>; /* PH10 */ | |
46 | status = "okay"; | |
47 | }; | |
48 | ||
49 | usbphy: phy@01c13400 { | |
50 | usb1_vbus-supply = <®_usb1_vbus>; | |
51 | usb2_vbus-supply = <®_usb2_vbus>; | |
52 | status = "okay"; | |
53 | }; | |
54 | ||
55 | ehci0: usb@01c14000 { | |
56 | status = "okay"; | |
57 | }; | |
58 | ||
59 | ohci0: usb@01c14400 { | |
60 | status = "okay"; | |
61 | }; | |
62 | ||
63 | ahci: sata@01c18000 { | |
64 | target-supply = <®_ahci_5v>; | |
65 | status = "okay"; | |
66 | }; | |
67 | ||
68 | ehci1: usb@01c1c000 { | |
69 | status = "okay"; | |
70 | }; | |
71 | ||
72 | ohci1: usb@01c1c400 { | |
73 | status = "okay"; | |
74 | }; | |
75 | ||
76 | pinctrl@01c20800 { | |
77 | led_pins_bananapi: led_pins@0 { | |
c1c5269b | 78 | allwinner,pins = "PH24"; |
461fadcb | 79 | allwinner,function = "gpio_out"; |
c1c5269b | 80 | allwinner,drive = <0>; |
461fadcb AF |
81 | allwinner,pull = <0>; |
82 | }; | |
83 | ||
84 | mmc0_cd_pin_bananapi: mmc0_cd_pin@0 { | |
85 | allwinner,pins = "PH10"; | |
86 | allwinner,function = "gpio_in"; | |
87 | allwinner,drive = <0>; | |
88 | allwinner,pull = <1>; | |
89 | }; | |
d01c0e2d IO |
90 | |
91 | gmac_power_pin_bananapi: gmac_power_pin@0 { | |
92 | allwinner,pins = "PH23"; | |
93 | allwinner,function = "gpio_out"; | |
94 | allwinner,drive = <0>; | |
95 | allwinner,pull = <0>; | |
96 | }; | |
461fadcb AF |
97 | }; |
98 | ||
99 | lradc: lradc@01c22800 { | |
100 | allwinner,chan0-step = <200>; | |
101 | linux,chan0-keycodes = <KEY_VOLUMEUP KEY_VOLUMEDOWN | |
102 | KEY_MENU KEY_SEARCH KEY_HOME | |
103 | KEY_ESC KEY_ENTER>; | |
104 | status = "okay"; | |
105 | }; | |
106 | ||
b8605392 AB |
107 | ir0: ir@01c21800 { |
108 | pinctrl-names = "default"; | |
109 | pinctrl-0 = <&ir0_pins_a>; | |
110 | status = "okay"; | |
111 | }; | |
112 | ||
461fadcb AF |
113 | uart0: serial@01c28000 { |
114 | pinctrl-names = "default"; | |
115 | pinctrl-0 = <&uart0_pins_a>; | |
116 | status = "okay"; | |
117 | }; | |
118 | ||
119 | uart6: serial@01c29800 { | |
120 | pinctrl-names = "default"; | |
121 | pinctrl-0 = <&uart6_pins_a>; | |
122 | status = "okay"; | |
123 | }; | |
124 | ||
125 | uart7: serial@01c29c00 { | |
126 | pinctrl-names = "default"; | |
127 | pinctrl-0 = <&uart7_pins_a>; | |
128 | status = "okay"; | |
129 | }; | |
130 | ||
131 | i2c0: i2c@01c2ac00 { | |
132 | pinctrl-names = "default"; | |
133 | pinctrl-0 = <&i2c0_pins_a>; | |
134 | status = "okay"; | |
ec3c9b04 IO |
135 | |
136 | axp: axp20x@34 { | |
137 | reg = <0x34>; | |
138 | interrupt-parent = <&nmi_intc>; | |
139 | interrupts = <0 8>; | |
140 | axp,system-power-controller; | |
141 | /include/ "x-powers-axp209.dtsi" | |
142 | }; | |
461fadcb AF |
143 | }; |
144 | ||
145 | i2c1: i2c@01c2b000 { | |
146 | pinctrl-names = "default"; | |
147 | pinctrl-0 = <&i2c1_pins_a>; | |
148 | status = "okay"; | |
149 | }; | |
150 | ||
151 | i2c2: i2c@01c2b400 { | |
152 | pinctrl-names = "default"; | |
153 | pinctrl-0 = <&i2c2_pins_a>; | |
154 | status = "okay"; | |
155 | }; | |
156 | ||
157 | gmac: ethernet@01c50000 { | |
158 | pinctrl-names = "default"; | |
d01c0e2d | 159 | pinctrl-0 = <&gmac_pins_rgmii_a>; |
461fadcb | 160 | phy = <&phy1>; |
d01c0e2d IO |
161 | phy-mode = "rgmii"; |
162 | phy-supply = <®_gmac_3v3>; | |
461fadcb AF |
163 | status = "okay"; |
164 | ||
165 | phy1: ethernet-phy@1 { | |
166 | reg = <1>; | |
167 | }; | |
168 | }; | |
169 | }; | |
170 | ||
171 | leds { | |
172 | compatible = "gpio-leds"; | |
173 | pinctrl-names = "default"; | |
174 | pinctrl-0 = <&led_pins_bananapi>; | |
175 | ||
176 | green { | |
177 | label = "bananapi:green:usr"; | |
c1c5269b AF |
178 | gpios = <&pio 7 24 0>; |
179 | linux,default-trigger = "heartbeat"; | |
461fadcb AF |
180 | }; |
181 | }; | |
6d9bdb6f IO |
182 | |
183 | reg_ahci_5v: ahci-5v { | |
184 | status = "okay"; | |
185 | }; | |
186 | ||
187 | reg_usb1_vbus: usb1-vbus { | |
188 | status = "okay"; | |
189 | }; | |
190 | ||
191 | reg_usb2_vbus: usb2-vbus { | |
192 | status = "okay"; | |
193 | }; | |
194 | ||
d01c0e2d IO |
195 | reg_gmac_3v3: gmac-3v3 { |
196 | compatible = "regulator-fixed"; | |
197 | pinctrl-names = "default"; | |
198 | pinctrl-0 = <&gmac_power_pin_bananapi>; | |
199 | regulator-name = "gmac-3v3"; | |
200 | regulator-min-microvolt = <3300000>; | |
201 | regulator-max-microvolt = <3300000>; | |
202 | startup-delay-us = <50000>; | |
203 | enable-active-high; | |
204 | gpio = <&pio 7 23 0>; | |
205 | status = "okay"; | |
206 | }; | |
461fadcb | 207 | }; |