Maxime Ripard | e476ac8 | 2013-07-17 10:12:16 +0200 | [diff] [blame] | 1 | /* |
| 2 | * Copyright 2013 Maxime Ripard |
| 3 | * |
| 4 | * Maxime Ripard <maxime.ripard@free-electrons.com> |
| 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/; |
Hans de Goede | a6a2d64 | 2014-12-23 11:13:22 +0100 | [diff] [blame] | 15 | #include "sun7i-a20.dtsi" |
| 16 | #include "sunxi-common-regulators.dtsi" |
Maxime Ripard | bca1292 | 2014-12-16 22:59:55 +0100 | [diff] [blame] | 17 | |
| 18 | #include <dt-bindings/gpio/gpio.h> |
Hans de Goede | a6a2d64 | 2014-12-23 11:13:22 +0100 | [diff] [blame] | 19 | #include <dt-bindings/input/input.h> |
Maxime Ripard | a6bac9e | 2014-12-16 22:59:59 +0100 | [diff] [blame^] | 20 | #include <dt-bindings/interrupt-controller/irq.h> |
Maxime Ripard | 092a0c3 | 2014-12-16 22:59:57 +0100 | [diff] [blame] | 21 | #include <dt-bindings/pinctrl/sun4i-a10.h> |
Maxime Ripard | e476ac8 | 2013-07-17 10:12:16 +0200 | [diff] [blame] | 22 | |
| 23 | / { |
| 24 | model = "Olimex A20-Olinuxino Micro"; |
| 25 | compatible = "olimex,a20-olinuxino-micro", "allwinner,sun7i-a20"; |
| 26 | |
Maxime Ripard | d5cf89c | 2014-02-22 22:35:59 +0100 | [diff] [blame] | 27 | aliases { |
| 28 | spi0 = &spi1; |
| 29 | spi1 = &spi2; |
| 30 | }; |
| 31 | |
Maxime Ripard | e476ac8 | 2013-07-17 10:12:16 +0200 | [diff] [blame] | 32 | soc@01c00000 { |
Maxime Ripard | d5cf89c | 2014-02-22 22:35:59 +0100 | [diff] [blame] | 33 | spi1: spi@01c06000 { |
| 34 | pinctrl-names = "default"; |
| 35 | pinctrl-0 = <&spi1_pins_a>; |
| 36 | status = "okay"; |
| 37 | }; |
| 38 | |
Hans de Goede | c621183 | 2014-05-02 17:57:28 +0200 | [diff] [blame] | 39 | mmc0: mmc@01c0f000 { |
| 40 | pinctrl-names = "default"; |
| 41 | pinctrl-0 = <&mmc0_pins_a>, <&mmc0_cd_pin_reference_design>; |
Hans de Goede | 0ed9eab | 2014-05-11 09:46:57 +0200 | [diff] [blame] | 42 | vmmc-supply = <®_vcc3v3>; |
Hans de Goede | c621183 | 2014-05-02 17:57:28 +0200 | [diff] [blame] | 43 | bus-width = <4>; |
Maxime Ripard | bca1292 | 2014-12-16 22:59:55 +0100 | [diff] [blame] | 44 | cd-gpios = <&pio 7 1 GPIO_ACTIVE_HIGH>; /* PH1 */ |
Hans de Goede | c621183 | 2014-05-02 17:57:28 +0200 | [diff] [blame] | 45 | cd-inverted; |
| 46 | status = "okay"; |
| 47 | }; |
| 48 | |
| 49 | mmc3: mmc@01c12000 { |
| 50 | pinctrl-names = "default"; |
| 51 | pinctrl-0 = <&mmc3_pins_a>, <&mmc3_cd_pin_olinuxinom>; |
Hans de Goede | 0ed9eab | 2014-05-11 09:46:57 +0200 | [diff] [blame] | 52 | vmmc-supply = <®_vcc3v3>; |
Hans de Goede | c621183 | 2014-05-02 17:57:28 +0200 | [diff] [blame] | 53 | bus-width = <4>; |
Maxime Ripard | bca1292 | 2014-12-16 22:59:55 +0100 | [diff] [blame] | 54 | cd-gpios = <&pio 7 11 GPIO_ACTIVE_HIGH>; /* PH11 */ |
Hans de Goede | c621183 | 2014-05-02 17:57:28 +0200 | [diff] [blame] | 55 | cd-inverted; |
| 56 | status = "okay"; |
| 57 | }; |
| 58 | |
Zalan Blenessy | e2f0265 | 2014-03-01 20:26:36 +0100 | [diff] [blame] | 59 | usbphy: phy@01c13400 { |
| 60 | usb1_vbus-supply = <®_usb1_vbus>; |
| 61 | usb2_vbus-supply = <®_usb2_vbus>; |
| 62 | status = "okay"; |
| 63 | }; |
| 64 | |
| 65 | ehci0: usb@01c14000 { |
| 66 | status = "okay"; |
| 67 | }; |
| 68 | |
| 69 | ohci0: usb@01c14400 { |
| 70 | status = "okay"; |
| 71 | }; |
| 72 | |
Maxime Ripard | d5cf89c | 2014-02-22 22:35:59 +0100 | [diff] [blame] | 73 | spi2: spi@01c17000 { |
| 74 | pinctrl-names = "default"; |
| 75 | pinctrl-0 = <&spi2_pins_a>; |
| 76 | status = "okay"; |
| 77 | }; |
| 78 | |
Hans de Goede | 902febf | 2014-03-01 20:26:22 +0100 | [diff] [blame] | 79 | ahci: sata@01c18000 { |
| 80 | target-supply = <®_ahci_5v>; |
| 81 | status = "okay"; |
| 82 | }; |
| 83 | |
Zalan Blenessy | e2f0265 | 2014-03-01 20:26:36 +0100 | [diff] [blame] | 84 | ehci1: usb@01c1c000 { |
| 85 | status = "okay"; |
| 86 | }; |
| 87 | |
| 88 | ohci1: usb@01c1c400 { |
| 89 | status = "okay"; |
| 90 | }; |
| 91 | |
Maxime Ripard | 6e487da | 2013-07-25 00:12:45 +0200 | [diff] [blame] | 92 | pinctrl@01c20800 { |
Hans de Goede | c621183 | 2014-05-02 17:57:28 +0200 | [diff] [blame] | 93 | mmc3_cd_pin_olinuxinom: mmc3_cd_pin@0 { |
| 94 | allwinner,pins = "PH11"; |
| 95 | allwinner,function = "gpio_in"; |
Maxime Ripard | 092a0c3 | 2014-12-16 22:59:57 +0100 | [diff] [blame] | 96 | allwinner,drive = <SUN4I_PINCTRL_10_MA>; |
| 97 | allwinner,pull = <SUN4I_PINCTRL_PULL_UP>; |
Hans de Goede | c621183 | 2014-05-02 17:57:28 +0200 | [diff] [blame] | 98 | }; |
| 99 | |
Maxime Ripard | 6e487da | 2013-07-25 00:12:45 +0200 | [diff] [blame] | 100 | led_pins_olinuxino: led_pins@0 { |
| 101 | allwinner,pins = "PH2"; |
| 102 | allwinner,function = "gpio_out"; |
Maxime Ripard | 092a0c3 | 2014-12-16 22:59:57 +0100 | [diff] [blame] | 103 | allwinner,drive = <SUN4I_PINCTRL_20_MA>; |
| 104 | allwinner,pull = <SUN4I_PINCTRL_NO_PULL>; |
Maxime Ripard | 6e487da | 2013-07-25 00:12:45 +0200 | [diff] [blame] | 105 | }; |
| 106 | }; |
| 107 | |
Hans de Goede | a6a2d64 | 2014-12-23 11:13:22 +0100 | [diff] [blame] | 108 | lradc: lradc@01c22800 { |
| 109 | vref-supply = <®_vcc3v0>; |
| 110 | status = "okay"; |
| 111 | |
| 112 | button@191 { |
| 113 | label = "Volume Up"; |
| 114 | linux,code = <KEY_VOLUMEUP>; |
| 115 | channel = <0>; |
| 116 | voltage = <191274>; |
| 117 | }; |
| 118 | |
| 119 | button@392 { |
| 120 | label = "Volume Down"; |
| 121 | linux,code = <KEY_VOLUMEDOWN>; |
| 122 | channel = <0>; |
| 123 | voltage = <392644>; |
| 124 | }; |
| 125 | |
| 126 | button@601 { |
| 127 | label = "Menu"; |
| 128 | linux,code = <KEY_MENU>; |
| 129 | channel = <0>; |
| 130 | voltage = <601151>; |
| 131 | }; |
| 132 | |
| 133 | button@795 { |
| 134 | label = "Search"; |
| 135 | linux,code = <KEY_SEARCH>; |
| 136 | channel = <0>; |
| 137 | voltage = <795090>; |
| 138 | }; |
| 139 | |
| 140 | button@987 { |
| 141 | label = "Home"; |
| 142 | linux,code = <KEY_HOMEPAGE>; |
| 143 | channel = <0>; |
| 144 | voltage = <987387>; |
| 145 | }; |
| 146 | |
| 147 | button@1184 { |
| 148 | label = "Esc"; |
| 149 | linux,code = <KEY_ESC>; |
| 150 | channel = <0>; |
| 151 | voltage = <1184678>; |
| 152 | }; |
| 153 | |
| 154 | button@1398 { |
| 155 | label = "Enter"; |
| 156 | linux,code = <KEY_ENTER>; |
| 157 | channel = <0>; |
| 158 | voltage = <1398804>; |
| 159 | }; |
| 160 | }; |
| 161 | |
Maxime Ripard | e476ac8 | 2013-07-17 10:12:16 +0200 | [diff] [blame] | 162 | uart0: serial@01c28000 { |
Maxime Ripard | 2fff6ac | 2013-07-25 00:10:53 +0200 | [diff] [blame] | 163 | pinctrl-names = "default"; |
| 164 | pinctrl-0 = <&uart0_pins_a>; |
Maxime Ripard | e476ac8 | 2013-07-17 10:12:16 +0200 | [diff] [blame] | 165 | status = "okay"; |
| 166 | }; |
| 167 | |
| 168 | uart6: serial@01c29800 { |
Maxime Ripard | 2fff6ac | 2013-07-25 00:10:53 +0200 | [diff] [blame] | 169 | pinctrl-names = "default"; |
| 170 | pinctrl-0 = <&uart6_pins_a>; |
Maxime Ripard | e476ac8 | 2013-07-17 10:12:16 +0200 | [diff] [blame] | 171 | status = "okay"; |
| 172 | }; |
| 173 | |
| 174 | uart7: serial@01c29c00 { |
Maxime Ripard | 2fff6ac | 2013-07-25 00:10:53 +0200 | [diff] [blame] | 175 | pinctrl-names = "default"; |
| 176 | pinctrl-0 = <&uart7_pins_a>; |
Maxime Ripard | e476ac8 | 2013-07-17 10:12:16 +0200 | [diff] [blame] | 177 | status = "okay"; |
| 178 | }; |
Maxime Ripard | d6d3f9e | 2013-08-31 23:14:19 +0200 | [diff] [blame] | 179 | |
| 180 | i2c0: i2c@01c2ac00 { |
| 181 | pinctrl-names = "default"; |
| 182 | pinctrl-0 = <&i2c0_pins_a>; |
| 183 | status = "okay"; |
Carlo Caione | ec0c933 | 2014-06-30 23:57:53 +0200 | [diff] [blame] | 184 | |
| 185 | axp209: pmic@34 { |
| 186 | compatible = "x-powers,axp209"; |
| 187 | reg = <0x34>; |
| 188 | interrupt-parent = <&nmi_intc>; |
Maxime Ripard | a6bac9e | 2014-12-16 22:59:59 +0100 | [diff] [blame^] | 189 | interrupts = <0 IRQ_TYPE_LEVEL_LOW>; |
Carlo Caione | ec0c933 | 2014-06-30 23:57:53 +0200 | [diff] [blame] | 190 | |
| 191 | interrupt-controller; |
| 192 | #interrupt-cells = <1>; |
| 193 | }; |
Maxime Ripard | d6d3f9e | 2013-08-31 23:14:19 +0200 | [diff] [blame] | 194 | }; |
| 195 | |
| 196 | i2c1: i2c@01c2b000 { |
| 197 | pinctrl-names = "default"; |
| 198 | pinctrl-0 = <&i2c1_pins_a>; |
| 199 | status = "okay"; |
| 200 | }; |
| 201 | |
| 202 | i2c2: i2c@01c2b400 { |
| 203 | pinctrl-names = "default"; |
| 204 | pinctrl-0 = <&i2c2_pins_a>; |
| 205 | status = "okay"; |
| 206 | }; |
Chen-Yu Tsai | 7164318 | 2014-02-10 18:35:53 +0800 | [diff] [blame] | 207 | |
| 208 | gmac: ethernet@01c50000 { |
| 209 | pinctrl-names = "default"; |
| 210 | pinctrl-0 = <&gmac_pins_mii_a>; |
| 211 | phy = <&phy1>; |
| 212 | phy-mode = "mii"; |
| 213 | status = "okay"; |
| 214 | |
| 215 | phy1: ethernet-phy@1 { |
| 216 | reg = <1>; |
| 217 | }; |
| 218 | }; |
Maxime Ripard | e476ac8 | 2013-07-17 10:12:16 +0200 | [diff] [blame] | 219 | }; |
Maxime Ripard | 6e487da | 2013-07-25 00:12:45 +0200 | [diff] [blame] | 220 | |
| 221 | leds { |
| 222 | compatible = "gpio-leds"; |
| 223 | pinctrl-names = "default"; |
| 224 | pinctrl-0 = <&led_pins_olinuxino>; |
| 225 | |
| 226 | green { |
| 227 | label = "a20-olinuxino-micro:green:usr"; |
Maxime Ripard | bca1292 | 2014-12-16 22:59:55 +0100 | [diff] [blame] | 228 | gpios = <&pio 7 2 GPIO_ACTIVE_HIGH>; |
Maxime Ripard | 6e487da | 2013-07-25 00:12:45 +0200 | [diff] [blame] | 229 | default-state = "on"; |
| 230 | }; |
| 231 | }; |
Hans de Goede | 902febf | 2014-03-01 20:26:22 +0100 | [diff] [blame] | 232 | |
| 233 | reg_ahci_5v: ahci-5v { |
| 234 | status = "okay"; |
| 235 | }; |
Zalan Blenessy | e2f0265 | 2014-03-01 20:26:36 +0100 | [diff] [blame] | 236 | |
| 237 | reg_usb1_vbus: usb1-vbus { |
| 238 | status = "okay"; |
| 239 | }; |
| 240 | |
| 241 | reg_usb2_vbus: usb2-vbus { |
| 242 | status = "okay"; |
| 243 | }; |
Maxime Ripard | e476ac8 | 2013-07-17 10:12:16 +0200 | [diff] [blame] | 244 | }; |