Oliver Schinagl | 01ed663 | 2013-10-08 10:22:32 +0200 | [diff] [blame] | 1 | /* |
| 2 | * Copyright 2013 Oliver Schinagl |
| 3 | * |
| 4 | * Oliver Schinagl <oliver@schinagl.nl> |
| 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/; |
Maxime Ripard | 7145570 | 2014-12-16 22:59:54 +0100 | [diff] [blame] | 15 | #include "sun7i-a20.dtsi" |
| 16 | #include "sunxi-common-regulators.dtsi" |
Oliver Schinagl | 01ed663 | 2013-10-08 10:22:32 +0200 | [diff] [blame] | 17 | |
Maxime Ripard | bca1292 | 2014-12-16 22:59:55 +0100 | [diff] [blame] | 18 | #include <dt-bindings/gpio/gpio.h> |
Maxime Ripard | 092a0c3 | 2014-12-16 22:59:57 +0100 | [diff] [blame^] | 19 | #include <dt-bindings/pinctrl/sun4i-a10.h> |
Maxime Ripard | bca1292 | 2014-12-16 22:59:55 +0100 | [diff] [blame] | 20 | |
Oliver Schinagl | 01ed663 | 2013-10-08 10:22:32 +0200 | [diff] [blame] | 21 | / { |
| 22 | model = "Cubietech Cubietruck"; |
| 23 | compatible = "cubietech,cubietruck", "allwinner,sun7i-a20"; |
| 24 | |
| 25 | soc@01c00000 { |
Hans de Goede | c621183 | 2014-05-02 17:57:28 +0200 | [diff] [blame] | 26 | mmc0: mmc@01c0f000 { |
| 27 | pinctrl-names = "default"; |
| 28 | pinctrl-0 = <&mmc0_pins_a>, <&mmc0_cd_pin_reference_design>; |
Hans de Goede | 0ed9eab | 2014-05-11 09:46:57 +0200 | [diff] [blame] | 29 | vmmc-supply = <®_vcc3v3>; |
Hans de Goede | c621183 | 2014-05-02 17:57:28 +0200 | [diff] [blame] | 30 | bus-width = <4>; |
Maxime Ripard | bca1292 | 2014-12-16 22:59:55 +0100 | [diff] [blame] | 31 | cd-gpios = <&pio 7 1 GPIO_ACTIVE_HIGH>; /* PH1 */ |
Hans de Goede | c621183 | 2014-05-02 17:57:28 +0200 | [diff] [blame] | 32 | cd-inverted; |
| 33 | status = "okay"; |
| 34 | }; |
| 35 | |
Chen-Yu Tsai | 3906c0a | 2014-05-02 17:57:29 +0200 | [diff] [blame] | 36 | mmc3: mmc@01c12000 { |
| 37 | pinctrl-names = "default"; |
| 38 | pinctrl-0 = <&mmc3_pins_a>; |
| 39 | vmmc-supply = <®_vmmc3>; |
Hans de Goede | c5b7261 | 2014-05-21 19:43:30 +0200 | [diff] [blame] | 40 | bus-width = <4>; |
Chen-Yu Tsai | 3906c0a | 2014-05-02 17:57:29 +0200 | [diff] [blame] | 41 | non-removable; |
| 42 | status = "okay"; |
| 43 | }; |
| 44 | |
Hans de Goede | a415eef | 2014-03-01 20:26:34 +0100 | [diff] [blame] | 45 | usbphy: phy@01c13400 { |
Roman Byshko | a7679b6 | 2014-11-10 19:55:10 +0100 | [diff] [blame] | 46 | usb0_vbus-supply = <®_usb0_vbus>; |
Hans de Goede | a415eef | 2014-03-01 20:26:34 +0100 | [diff] [blame] | 47 | usb1_vbus-supply = <®_usb1_vbus>; |
| 48 | usb2_vbus-supply = <®_usb2_vbus>; |
| 49 | status = "okay"; |
| 50 | }; |
| 51 | |
| 52 | ehci0: usb@01c14000 { |
| 53 | status = "okay"; |
| 54 | }; |
| 55 | |
| 56 | ohci0: usb@01c14400 { |
| 57 | status = "okay"; |
| 58 | }; |
| 59 | |
Hans de Goede | 902febf | 2014-03-01 20:26:22 +0100 | [diff] [blame] | 60 | ahci: sata@01c18000 { |
| 61 | target-supply = <®_ahci_5v>; |
| 62 | status = "okay"; |
| 63 | }; |
| 64 | |
Hans de Goede | a415eef | 2014-03-01 20:26:34 +0100 | [diff] [blame] | 65 | ehci1: usb@01c1c000 { |
| 66 | status = "okay"; |
| 67 | }; |
| 68 | |
| 69 | ohci1: usb@01c1c400 { |
| 70 | status = "okay"; |
| 71 | }; |
| 72 | |
Oliver Schinagl | 01ed663 | 2013-10-08 10:22:32 +0200 | [diff] [blame] | 73 | pinctrl@01c20800 { |
Chen-Yu Tsai | 3906c0a | 2014-05-02 17:57:29 +0200 | [diff] [blame] | 74 | mmc3_pins_a: mmc3@0 { |
| 75 | /* AP6210 requires pull-up */ |
Maxime Ripard | 092a0c3 | 2014-12-16 22:59:57 +0100 | [diff] [blame^] | 76 | allwinner,pull = <SUN4I_PINCTRL_PULL_UP>; |
Chen-Yu Tsai | 3906c0a | 2014-05-02 17:57:29 +0200 | [diff] [blame] | 77 | }; |
| 78 | |
| 79 | vmmc3_pin_cubietruck: vmmc3_pin@0 { |
| 80 | allwinner,pins = "PH9"; |
| 81 | allwinner,function = "gpio_out"; |
Maxime Ripard | 092a0c3 | 2014-12-16 22:59:57 +0100 | [diff] [blame^] | 82 | allwinner,drive = <SUN4I_PINCTRL_10_MA>; |
| 83 | allwinner,pull = <SUN4I_PINCTRL_NO_PULL>; |
Chen-Yu Tsai | 3906c0a | 2014-05-02 17:57:29 +0200 | [diff] [blame] | 84 | }; |
| 85 | |
Hans de Goede | 902febf | 2014-03-01 20:26:22 +0100 | [diff] [blame] | 86 | ahci_pwr_pin_cubietruck: ahci_pwr_pin@1 { |
| 87 | allwinner,pins = "PH12"; |
| 88 | allwinner,function = "gpio_out"; |
Maxime Ripard | 092a0c3 | 2014-12-16 22:59:57 +0100 | [diff] [blame^] | 89 | allwinner,drive = <SUN4I_PINCTRL_10_MA>; |
| 90 | allwinner,pull = <SUN4I_PINCTRL_NO_PULL>; |
Hans de Goede | 902febf | 2014-03-01 20:26:22 +0100 | [diff] [blame] | 91 | }; |
| 92 | |
Oliver Schinagl | 01ed663 | 2013-10-08 10:22:32 +0200 | [diff] [blame] | 93 | led_pins_cubietruck: led_pins@0 { |
| 94 | allwinner,pins = "PH7", "PH11", "PH20", "PH21"; |
| 95 | allwinner,function = "gpio_out"; |
Maxime Ripard | 092a0c3 | 2014-12-16 22:59:57 +0100 | [diff] [blame^] | 96 | allwinner,drive = <SUN4I_PINCTRL_10_MA>; |
| 97 | allwinner,pull = <SUN4I_PINCTRL_NO_PULL>; |
Oliver Schinagl | 01ed663 | 2013-10-08 10:22:32 +0200 | [diff] [blame] | 98 | }; |
Roman Byshko | 9eb1e27 | 2014-11-10 19:55:09 +0100 | [diff] [blame] | 99 | |
| 100 | usb0_vbus_pin_a: usb0_vbus_pin@0 { |
| 101 | allwinner,pins = "PH17"; |
| 102 | allwinner,function = "gpio_out"; |
Maxime Ripard | 092a0c3 | 2014-12-16 22:59:57 +0100 | [diff] [blame^] | 103 | allwinner,drive = <SUN4I_PINCTRL_10_MA>; |
| 104 | allwinner,pull = <SUN4I_PINCTRL_NO_PULL>; |
Roman Byshko | 9eb1e27 | 2014-11-10 19:55:09 +0100 | [diff] [blame] | 105 | }; |
Oliver Schinagl | 01ed663 | 2013-10-08 10:22:32 +0200 | [diff] [blame] | 106 | }; |
| 107 | |
Alexandre Belloni | 96ac3b3 | 2014-04-28 18:17:14 +0200 | [diff] [blame] | 108 | pwm: pwm@01c20e00 { |
| 109 | pinctrl-names = "default"; |
| 110 | pinctrl-0 = <&pwm0_pins_a>, <&pwm1_pins_a>; |
| 111 | status = "okay"; |
| 112 | }; |
| 113 | |
Alexander Bersenev | 0256452 | 2014-06-09 00:08:13 +0600 | [diff] [blame] | 114 | ir0: ir@01c21800 { |
| 115 | pinctrl-names = "default"; |
| 116 | pinctrl-0 = <&ir0_pins_a>; |
| 117 | status = "okay"; |
| 118 | }; |
| 119 | |
Oliver Schinagl | 01ed663 | 2013-10-08 10:22:32 +0200 | [diff] [blame] | 120 | uart0: serial@01c28000 { |
| 121 | pinctrl-names = "default"; |
| 122 | pinctrl-0 = <&uart0_pins_a>; |
| 123 | status = "okay"; |
| 124 | }; |
Chen-Yu Tsai | 6267355 | 2014-01-06 13:58:12 +0800 | [diff] [blame] | 125 | |
| 126 | i2c0: i2c@01c2ac00 { |
| 127 | pinctrl-names = "default"; |
| 128 | pinctrl-0 = <&i2c0_pins_a>; |
| 129 | status = "okay"; |
Carlo Caione | ec0c933 | 2014-06-30 23:57:53 +0200 | [diff] [blame] | 130 | |
| 131 | axp209: pmic@34 { |
| 132 | compatible = "x-powers,axp209"; |
| 133 | reg = <0x34>; |
| 134 | interrupt-parent = <&nmi_intc>; |
| 135 | interrupts = <0 8>; |
| 136 | |
| 137 | interrupt-controller; |
| 138 | #interrupt-cells = <1>; |
| 139 | }; |
Chen-Yu Tsai | 6267355 | 2014-01-06 13:58:12 +0800 | [diff] [blame] | 140 | }; |
| 141 | |
| 142 | i2c1: i2c@01c2b000 { |
| 143 | pinctrl-names = "default"; |
| 144 | pinctrl-0 = <&i2c1_pins_a>; |
| 145 | status = "okay"; |
| 146 | }; |
| 147 | |
| 148 | i2c2: i2c@01c2b400 { |
| 149 | pinctrl-names = "default"; |
| 150 | pinctrl-0 = <&i2c2_pins_a>; |
| 151 | status = "okay"; |
| 152 | }; |
Chen-Yu Tsai | 67073d9 | 2014-02-10 18:35:51 +0800 | [diff] [blame] | 153 | |
| 154 | gmac: ethernet@01c50000 { |
| 155 | pinctrl-names = "default"; |
| 156 | pinctrl-0 = <&gmac_pins_rgmii_a>; |
| 157 | phy = <&phy1>; |
| 158 | phy-mode = "rgmii"; |
| 159 | status = "okay"; |
| 160 | |
| 161 | phy1: ethernet-phy@1 { |
| 162 | reg = <1>; |
| 163 | }; |
| 164 | }; |
Oliver Schinagl | 01ed663 | 2013-10-08 10:22:32 +0200 | [diff] [blame] | 165 | }; |
| 166 | |
| 167 | leds { |
| 168 | compatible = "gpio-leds"; |
| 169 | pinctrl-names = "default"; |
| 170 | pinctrl-0 = <&led_pins_cubietruck>; |
| 171 | |
| 172 | blue { |
| 173 | label = "cubietruck:blue:usr"; |
Maxime Ripard | bca1292 | 2014-12-16 22:59:55 +0100 | [diff] [blame] | 174 | gpios = <&pio 7 21 GPIO_ACTIVE_HIGH>; |
Oliver Schinagl | 01ed663 | 2013-10-08 10:22:32 +0200 | [diff] [blame] | 175 | }; |
| 176 | |
| 177 | orange { |
| 178 | label = "cubietruck:orange:usr"; |
Maxime Ripard | bca1292 | 2014-12-16 22:59:55 +0100 | [diff] [blame] | 179 | gpios = <&pio 7 20 GPIO_ACTIVE_HIGH>; |
Oliver Schinagl | 01ed663 | 2013-10-08 10:22:32 +0200 | [diff] [blame] | 180 | }; |
| 181 | |
| 182 | white { |
| 183 | label = "cubietruck:white:usr"; |
Maxime Ripard | bca1292 | 2014-12-16 22:59:55 +0100 | [diff] [blame] | 184 | gpios = <&pio 7 11 GPIO_ACTIVE_HIGH>; |
Oliver Schinagl | 01ed663 | 2013-10-08 10:22:32 +0200 | [diff] [blame] | 185 | }; |
| 186 | |
| 187 | green { |
| 188 | label = "cubietruck:green:usr"; |
Maxime Ripard | bca1292 | 2014-12-16 22:59:55 +0100 | [diff] [blame] | 189 | gpios = <&pio 7 7 GPIO_ACTIVE_HIGH>; |
Oliver Schinagl | 01ed663 | 2013-10-08 10:22:32 +0200 | [diff] [blame] | 190 | }; |
| 191 | }; |
Hans de Goede | 902febf | 2014-03-01 20:26:22 +0100 | [diff] [blame] | 192 | |
| 193 | reg_ahci_5v: ahci-5v { |
| 194 | pinctrl-0 = <&ahci_pwr_pin_cubietruck>; |
Maxime Ripard | bca1292 | 2014-12-16 22:59:55 +0100 | [diff] [blame] | 195 | gpio = <&pio 7 12 GPIO_ACTIVE_HIGH>; |
Hans de Goede | 902febf | 2014-03-01 20:26:22 +0100 | [diff] [blame] | 196 | status = "okay"; |
| 197 | }; |
Hans de Goede | a415eef | 2014-03-01 20:26:34 +0100 | [diff] [blame] | 198 | |
Roman Byshko | 9eb1e27 | 2014-11-10 19:55:09 +0100 | [diff] [blame] | 199 | reg_usb0_vbus: usb0-vbus { |
| 200 | pinctrl-0 = <&usb0_vbus_pin_a>; |
Maxime Ripard | bca1292 | 2014-12-16 22:59:55 +0100 | [diff] [blame] | 201 | gpio = <&pio 7 17 GPIO_ACTIVE_HIGH>; |
Roman Byshko | 9eb1e27 | 2014-11-10 19:55:09 +0100 | [diff] [blame] | 202 | status = "okay"; |
| 203 | }; |
| 204 | |
Hans de Goede | a415eef | 2014-03-01 20:26:34 +0100 | [diff] [blame] | 205 | reg_usb1_vbus: usb1-vbus { |
| 206 | status = "okay"; |
| 207 | }; |
| 208 | |
| 209 | reg_usb2_vbus: usb2-vbus { |
| 210 | status = "okay"; |
| 211 | }; |
Chen-Yu Tsai | 3906c0a | 2014-05-02 17:57:29 +0200 | [diff] [blame] | 212 | |
| 213 | reg_vmmc3: vmmc3 { |
| 214 | compatible = "regulator-fixed"; |
| 215 | pinctrl-names = "default"; |
| 216 | pinctrl-0 = <&vmmc3_pin_cubietruck>; |
| 217 | regulator-name = "vmmc3"; |
| 218 | regulator-min-microvolt = <3300000>; |
| 219 | regulator-max-microvolt = <3300000>; |
| 220 | enable-active-high; |
Maxime Ripard | bca1292 | 2014-12-16 22:59:55 +0100 | [diff] [blame] | 221 | gpio = <&pio 7 9 GPIO_ACTIVE_HIGH>; |
Chen-Yu Tsai | 3906c0a | 2014-05-02 17:57:29 +0200 | [diff] [blame] | 222 | }; |
Oliver Schinagl | 01ed663 | 2013-10-08 10:22:32 +0200 | [diff] [blame] | 223 | }; |