0001 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
0002 /*
0003 * DTSI for Emlid Neutis SoMs.
0004 *
0005 * Copyright (C) 2019 Georgii Staroselskii <georgii.staroselskii@emlid.com>
0006 */
0007
0008 #include "sunxi-common-regulators.dtsi"
0009
0010 #include <dt-bindings/gpio/gpio.h>
0011
0012 / {
0013 aliases {
0014 serial0 = &uart0;
0015 };
0016
0017 chosen {
0018 stdout-path = "serial0:115200n8";
0019 };
0020
0021 wifi_pwrseq: wifi_pwrseq {
0022 compatible = "mmc-pwrseq-simple";
0023 reset-gpios = <&pio 2 7 GPIO_ACTIVE_LOW>; /* PC7 */
0024 post-power-on-delay-ms = <200>;
0025 clocks = <&rtc CLK_OSC32K_FANOUT>;
0026 clock-names = "ext_clock";
0027 };
0028 };
0029
0030 &cpu0 {
0031 cpu-supply = <&vdd_cpux>;
0032 };
0033
0034 ®_usb0_vbus {
0035 gpio = <&r_pio 0 9 GPIO_ACTIVE_HIGH>; /* PL9 */
0036 status = "okay";
0037 };
0038
0039
0040 &de {
0041 status = "okay";
0042 };
0043
0044 &ohci0 {
0045 status = "okay";
0046 };
0047
0048 &ohci1 {
0049 status = "okay";
0050 };
0051
0052 &ohci2 {
0053 status = "okay";
0054 };
0055
0056 &ohci3 {
0057 status = "okay";
0058 };
0059
0060
0061 &ehci0 {
0062 status = "okay";
0063 };
0064
0065 &ehci1 {
0066 status = "okay";
0067 };
0068
0069 &ehci2 {
0070 status = "okay";
0071 };
0072
0073 &ehci3 {
0074 status = "okay";
0075 };
0076
0077 &mmc0 {
0078 vmmc-supply = <®_vcc3v3>;
0079 bus-width = <4>;
0080 cd-gpios = <&pio 5 6 GPIO_ACTIVE_LOW>; /* PF6 */
0081 status = "okay";
0082 };
0083
0084
0085 &mmc1 {
0086 vmmc-supply = <®_vcc3v3>;
0087 vqmmc-supply = <®_vcc3v3>;
0088 mmc-pwrseq = <&wifi_pwrseq>;
0089 bus-width = <4>;
0090 non-removable;
0091 status = "okay";
0092
0093 brcmf: wifi@1 {
0094 reg = <1>;
0095 compatible = "brcm,bcm4329-fmac";
0096 interrupt-parent = <&r_pio>;
0097 interrupts = <0 5 IRQ_TYPE_LEVEL_LOW>; /* PL5 */
0098 interrupt-names = "host-wake";
0099 };
0100 };
0101
0102 &mmc2 {
0103 pinctrl-names = "default";
0104 pinctrl-0 = <&mmc2_8bit_pins>;
0105 vmmc-supply = <®_vcc3v3>;
0106 bus-width = <8>;
0107 non-removable;
0108 cap-mmc-hw-reset;
0109 status = "okay";
0110 };
0111
0112 &uart0 {
0113 pinctrl-names = "default";
0114 pinctrl-0 = <&uart0_pa_pins>;
0115 status = "okay";
0116 };
0117
0118
0119 &uart1 {
0120 pinctrl-names = "default";
0121 pinctrl-0 = <&uart1_pins>, <&uart1_rts_cts_pins>;
0122 uart-has-rtscts;
0123 status = "okay";
0124
0125 bluetooth {
0126 compatible = "brcm,bcm43438-bt";
0127 clocks = <&rtc CLK_OSC32K_FANOUT>;
0128 clock-names = "lpo";
0129 vbat-supply = <®_vcc3v3>;
0130 vddio-supply = <®_vcc3v3>;
0131 shutdown-gpios = <&pio 2 4 GPIO_ACTIVE_HIGH>; /* PC4 */
0132 device-wakeup-gpios = <&r_pio 0 7 GPIO_ACTIVE_HIGH>; /* PL7 */
0133 };
0134 };
0135
0136 &uart2 {
0137 pinctrl-names = "default";
0138 pinctrl-0 = <&uart2_pins>;
0139 status = "okay";
0140 };
0141
0142 &uart3 {
0143 pinctrl-names = "default";
0144 pinctrl-0 = <&uart3_pins>;
0145 status = "okay";
0146 };
0147
0148 &usbphy {
0149 usb0_id_det-gpios = <&r_pio 0 8 GPIO_ACTIVE_HIGH>; /* PL8 */
0150 usb0_vbus-supply = <®_usb0_vbus>;
0151 status = "okay";
0152 };
0153
0154 &usb_otg {
0155 dr_mode = "otg";
0156 status = "okay";
0157 };
0158
0159 &codec {
0160 allwinner,audio-routing =
0161 "Line Out", "LINEOUT",
0162 "LINEIN", "Line In",
0163 "MIC1", "Mic",
0164 "MIC2", "Mic",
0165 "Mic", "MBIAS";
0166 };
0167
0168 &i2c0 {
0169 status = "okay";
0170 };