sun50i-a64-pinebook.dts revision 1.7
11.7Sjmcneill/* $NetBSD: sun50i-a64-pinebook.dts,v 1.7 2018/05/05 11:16:30 jmcneill Exp $ */
21.1Sjmcneill
31.1Sjmcneill/*-
41.1Sjmcneill * Copyright (c) 2017 Jared McNeill <jmcneill@invisible.ca>
51.1Sjmcneill * All rights reserved.
61.1Sjmcneill *
71.1Sjmcneill * Redistribution and use in source and binary forms, with or without
81.1Sjmcneill * modification, are permitted provided that the following conditions
91.1Sjmcneill * are met:
101.1Sjmcneill * 1. Redistributions of source code must retain the above copyright
111.1Sjmcneill *    notice, this list of conditions and the following disclaimer.
121.1Sjmcneill * 2. Redistributions in binary form must reproduce the above copyright
131.1Sjmcneill *    notice, this list of conditions and the following disclaimer in the
141.1Sjmcneill *    documentation and/or other materials provided with the distribution.
151.1Sjmcneill *
161.1Sjmcneill * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
171.1Sjmcneill * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
181.1Sjmcneill * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
191.1Sjmcneill * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
201.1Sjmcneill * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
211.1Sjmcneill * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
221.1Sjmcneill * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
231.1Sjmcneill * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
241.1Sjmcneill * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
251.1Sjmcneill * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
261.1Sjmcneill * SUCH DAMAGE.
271.1Sjmcneill */
281.1Sjmcneill
291.5Sjmcneill/dts-v1/;
301.5Sjmcneill
311.5Sjmcneill#include "../../../external/gpl2/dts/dist/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi"
321.1Sjmcneill#include "sun50i-a64.dtsi"
331.1Sjmcneill
341.5Sjmcneill#include <dt-bindings/gpio/gpio.h>
351.4Sjmcneill#include <dt-bindings/input/linux-event-codes.h>
361.5Sjmcneill#include <dt-bindings/interrupt-controller/irq.h>
371.4Sjmcneill
381.2Sjmcneill/ {
391.2Sjmcneill	model = "Pine64 Pinebook";
401.2Sjmcneill	compatible = "pine64,pinebook", "allwinner,sun50i-a64";
411.3Sjmcneill
421.5Sjmcneill	aliases {
431.5Sjmcneill		serial0 = &uart0;
441.5Sjmcneill	};
451.5Sjmcneill
461.3Sjmcneill	chosen {
471.5Sjmcneill		stdout-path = "serial0:115200n8";
481.5Sjmcneill
491.3Sjmcneill		framebuffer@0 {
501.3Sjmcneill			allwinner,pipeline = "mixer0-lcd0";
511.3Sjmcneill		};
521.3Sjmcneill	};
531.2Sjmcneill
541.4Sjmcneill	gpio_keys {
551.4Sjmcneill		compatible = "gpio-keys";
561.4Sjmcneill
571.4Sjmcneill		lid_switch {
581.4Sjmcneill			label = "Lid Switch";
591.4Sjmcneill			gpios = <&pio 7 10 GPIO_ACTIVE_LOW>;	/* PH10 */
601.4Sjmcneill			linux,input-type = <EV_SW>;
611.4Sjmcneill			linux,code = <SW_LID>;
621.4Sjmcneill			linux,can-disable;
631.4Sjmcneill		};
641.4Sjmcneill	};
651.5Sjmcneill
661.5Sjmcneill	reg_vcc3v3: vcc3v3 {
671.5Sjmcneill		regulator-fixed;
681.5Sjmcneill		regulator-name = "vcc3v3";
691.5Sjmcneill		regulator-min-microvolt = <3300000>;
701.5Sjmcneill		regulator-max-microvolt = <3300000>;
711.5Sjmcneill	};
721.5Sjmcneill};
731.5Sjmcneill
741.7Sjmcneill&ehci0 {
751.7Sjmcneill	status = "okay";
761.7Sjmcneill};
771.7Sjmcneill
781.5Sjmcneill&ehci1 {
791.5Sjmcneill	status = "okay";
801.5Sjmcneill};
811.5Sjmcneill
821.7Sjmcneill&ohci0 {
831.7Sjmcneill	status = "okay";
841.7Sjmcneill};
851.7Sjmcneill
861.5Sjmcneill&ohci1 {
871.5Sjmcneill	status = "okay";
881.5Sjmcneill};
891.5Sjmcneill
901.5Sjmcneill&usb_otg {
911.5Sjmcneill	dr_mode = "host";
921.5Sjmcneill	status = "okay";
931.5Sjmcneill};
941.5Sjmcneill
951.5Sjmcneill&usbphy {
961.5Sjmcneill	status = "okay";
971.5Sjmcneill};
981.5Sjmcneill
991.5Sjmcneill&mmc0 {
1001.5Sjmcneill	pinctrl-names = "default";
1011.5Sjmcneill	pinctrl-0 = <&mmc0_pins>;
1021.5Sjmcneill	vmmc-supply = <&reg_vcc3v3>;
1031.5Sjmcneill	cd-gpios = <&pio 5 6 GPIO_ACTIVE_LOW>;
1041.5Sjmcneill	disable-wp;
1051.5Sjmcneill	bus-width = <4>;
1061.5Sjmcneill	status = "okay";
1071.1Sjmcneill};
1081.1Sjmcneill
1091.6Sjmcneill&mmc1 {
1101.6Sjmcneill	pinctrl-names = "default";
1111.6Sjmcneill	pinctrl-0 = <&mmc1_pins>;
1121.6Sjmcneill	vmmc-supply = <&reg_dldo4>;
1131.6Sjmcneill	vqmmc-supply = <&reg_eldo1>;
1141.6Sjmcneill	bus-width = <4>;
1151.6Sjmcneill	non-removable;
1161.6Sjmcneill	status = "okay";
1171.6Sjmcneill
1181.6Sjmcneill	rtl8723cs: wifi@1 {
1191.6Sjmcneill		reg = <1>;
1201.6Sjmcneill	};
1211.6Sjmcneill};
1221.6Sjmcneill
1231.4Sjmcneill&mmc2 {
1241.4Sjmcneill	pinctrl-names = "default";
1251.4Sjmcneill	pinctrl-0 = <&mmc2_pins>;
1261.4Sjmcneill	vmmc-supply = <&reg_dcdc1>;
1271.4Sjmcneill	bus-width = <8>;
1281.4Sjmcneill	non-removable;
1291.4Sjmcneill	cap-mmc-hw-reset;
1301.1Sjmcneill	status = "okay";
1311.1Sjmcneill};
1321.5Sjmcneill
1331.5Sjmcneill&uart0 {
1341.5Sjmcneill	pinctrl-names = "default";
1351.5Sjmcneill	pinctrl-0 = <&uart0_pins_a>;
1361.5Sjmcneill	status = "okay";
1371.5Sjmcneill};
1381.5Sjmcneill
1391.5Sjmcneill&r_rsb {
1401.5Sjmcneill	status = "okay";
1411.5Sjmcneill
1421.5Sjmcneill	axp803: pmic@3a3 {
1431.5Sjmcneill		compatible = "x-powers,axp803";
1441.5Sjmcneill		reg = <0x3a3>;
1451.5Sjmcneill		interrupt-parent = <&r_intc>;
1461.5Sjmcneill		interrupts = <0 IRQ_TYPE_LEVEL_LOW>;
1471.5Sjmcneill	};
1481.5Sjmcneill};
1491.5Sjmcneill
1501.5Sjmcneill#include "axp803.dtsi"
151