1/* 2 * Copyright (C) 2017 Stefan Wahren <stefan.wahren@i2se.com> 3 * 4 * The code contained herein is licensed under the GNU General Public 5 * License. You may obtain a copy of the GNU General Public License 6 * Version 2 or later at the following locations: 7 * 8 * http://www.opensource.org/licenses/gpl-license.html 9 * http://www.gnu.org/copyleft/gpl.html 10 */ 11 12/dts-v1/; 13#include "bcm2835.dtsi" 14#include "bcm2835-rpi.dtsi" 15#include "bcm283x-rpi-usb-otg.dtsi" 16 17/ { 18 compatible = "raspberrypi,model-zero-w", "brcm,bcm2835"; 19 model = "Raspberry Pi Zero W"; 20 21 chosen { 22 /* 8250 auxiliary UART instead of pl011 */ 23 stdout-path = "serial1:115200n8"; 24 }; 25 26 leds { 27 act { 28 gpios = <&gpio 47 GPIO_ACTIVE_LOW>; 29 }; 30 }; 31 32 wifi_pwrseq: wifi-pwrseq { 33 compatible = "mmc-pwrseq-simple"; 34 pinctrl-names = "default"; 35 pinctrl-0 = <&wl_on>; 36 reset-gpios = <&gpio 41 GPIO_ACTIVE_LOW>; 37 }; 38}; 39 40&gpio { 41 /* 42 * This is based on the official GPU firmware DT blob. 43 * 44 * Legend: 45 * "NC" = not connected (no rail from the SoC) 46 * "FOO" = GPIO line named "FOO" on the schematic 47 * "FOO_N" = GPIO line named "FOO" on schematic, active low 48 */ 49 gpio-line-names = "GPIO0", 50 "GPIO1", 51 "SDA1", 52 "SCL1", 53 "GPIO_GCLK", 54 "GPIO5", 55 "GPIO6", 56 "SPI_CE1_N", 57 "SPI_CE0_N", 58 "SPI_MISO", 59 "SPI_MOSI", 60 "SPI_SCLK", 61 "GPIO12", 62 "GPIO13", 63 /* Serial port */ 64 "TXD0", 65 "RXD0", 66 "GPIO16", 67 "GPIO17", 68 "GPIO18", 69 "GPIO19", 70 "GPIO20", 71 "GPIO21", 72 "GPIO22", 73 "GPIO23", 74 "GPIO24", 75 "GPIO25", 76 "GPIO26", 77 "GPIO27", 78 "SDA0", 79 "SCL0", 80 "NC", /* GPIO30 */ 81 "NC", /* GPIO31 */ 82 "NC", /* GPIO32 */ 83 "NC", /* GPIO33 */ 84 "NC", /* GPIO34 */ 85 "NC", /* GPIO35 */ 86 "NC", /* GPIO36 */ 87 "NC", /* GPIO37 */ 88 "NC", /* GPIO38 */ 89 "NC", /* GPIO39 */ 90 "CAM_GPIO1", /* GPIO40 */ 91 "WL_ON", /* GPIO41 */ 92 "NC", /* GPIO42 */ 93 "WIFI_CLK", /* GPIO43 */ 94 "CAM_GPIO0", /* GPIO44 */ 95 "BT_ON", /* GPIO45 */ 96 "HDMI_HPD_N", 97 "STATUS_LED_N", 98 /* Used by SD Card */ 99 "SD_CLK_R", 100 "SD_CMD_R", 101 "SD_DATA0_R", 102 "SD_DATA1_R", 103 "SD_DATA2_R", 104 "SD_DATA3_R"; 105 106 pinctrl-0 = <&gpioout &alt0>; 107 108 wl_on: wl-on { 109 brcm,pins = <41>; 110 brcm,function = <BCM2835_FSEL_GPIO_OUT>; 111 }; 112}; 113 114&hdmi { 115 hpd-gpios = <&gpio 46 GPIO_ACTIVE_LOW>; 116}; 117 118&sdhci { 119 #address-cells = <1>; 120 #size-cells = <0>; 121 pinctrl-names = "default"; 122 pinctrl-0 = <&emmc_gpio34 &gpclk2_gpio43>; 123 mmc-pwrseq = <&wifi_pwrseq>; 124 non-removable; 125 status = "okay"; 126 127 brcmf: wifi@1 { 128 reg = <1>; 129 compatible = "brcm,bcm4329-fmac"; 130 }; 131}; 132 133&uart0 { 134 pinctrl-names = "default"; 135 pinctrl-0 = <&uart0_gpio32 &uart0_ctsrts_gpio30>; 136 status = "okay"; 137 138 bluetooth { 139 compatible = "brcm,bcm43438-bt"; 140 max-speed = <2000000>; 141 shutdown-gpios = <&gpio 45 GPIO_ACTIVE_HIGH>; 142 }; 143}; 144 145&uart1 { 146 pinctrl-names = "default"; 147 pinctrl-0 = <&uart1_gpio14>; 148 status = "okay"; 149}; 150