1// SPDX-License-Identifier: GPL-2.0 2/dts-v1/; 3#include "bcm2837.dtsi" 4#include "bcm2836-rpi.dtsi" 5#include "bcm283x-rpi-smsc9514.dtsi" 6#include "bcm283x-rpi-usb-host.dtsi" 7 8/ { 9 compatible = "raspberrypi,3-model-b", "brcm,bcm2837"; 10 model = "Raspberry Pi 3 Model B"; 11 12 chosen { 13 /* 8250 auxiliary UART instead of pl011 */ 14 stdout-path = "serial1:115200n8"; 15 }; 16 17 memory@0 { 18 reg = <0 0x40000000>; 19 }; 20 21 leds { 22 act { 23 gpios = <&expgpio 2 GPIO_ACTIVE_HIGH>; 24 }; 25 }; 26 27 wifi_pwrseq: wifi-pwrseq { 28 compatible = "mmc-pwrseq-simple"; 29 reset-gpios = <&expgpio 1 GPIO_ACTIVE_LOW>; 30 }; 31}; 32 33&firmware { 34 expgpio: gpio { 35 compatible = "raspberrypi,firmware-gpio"; 36 gpio-controller; 37 #gpio-cells = <2>; 38 gpio-line-names = "BT_ON", 39 "WL_ON", 40 "STATUS_LED", 41 "LAN_RUN", 42 "HDMI_HPD_N", 43 "CAM_GPIO0", 44 "CAM_GPIO1", 45 "PWR_LOW_N"; 46 status = "okay"; 47 }; 48}; 49 50&gpio { 51 /* 52 * Taken from rpi_SCH_3b_1p2_reduced.pdf and 53 * the official GPU firmware DT blob. 54 * 55 * Legend: 56 * "NC" = not connected (no rail from the SoC) 57 * "FOO" = GPIO line named "FOO" on the schematic 58 * "FOO_N" = GPIO line named "FOO" on schematic, active low 59 */ 60 gpio-line-names = "ID_SDA", 61 "ID_SCL", 62 "SDA1", 63 "SCL1", 64 "GPIO_GCLK", 65 "GPIO5", 66 "GPIO6", 67 "SPI_CE1_N", 68 "SPI_CE0_N", 69 "SPI_MISO", 70 "SPI_MOSI", 71 "SPI_SCLK", 72 "GPIO12", 73 "GPIO13", 74 /* Serial port */ 75 "TXD1", 76 "RXD1", 77 "GPIO16", 78 "GPIO17", 79 "GPIO18", 80 "GPIO19", 81 "GPIO20", 82 "GPIO21", 83 "GPIO22", 84 "GPIO23", 85 "GPIO24", 86 "GPIO25", 87 "GPIO26", 88 "GPIO27", 89 "", /* GPIO 28 */ 90 "LAN_RUN_BOOT", 91 /* Used by BT module */ 92 "CTS0", 93 "RTS0", 94 "TXD0", 95 "RXD0", 96 /* Used by Wifi */ 97 "SD1_CLK", 98 "SD1_CMD", 99 "SD1_DATA0", 100 "SD1_DATA1", 101 "SD1_DATA2", 102 "SD1_DATA3", 103 "PWM0_OUT", 104 "PWM1_OUT", 105 "ETHCLK", 106 "WIFI_CLK", 107 "SDA0", 108 "SCL0", 109 "SMPS_SCL", 110 "SMPS_SDA", 111 /* Used by SD Card */ 112 "SD_CLK_R", 113 "SD_CMD_R", 114 "SD_DATA0_R", 115 "SD_DATA1_R", 116 "SD_DATA2_R", 117 "SD_DATA3_R"; 118}; 119 120&pwm { 121 pinctrl-names = "default"; 122 pinctrl-0 = <&pwm0_gpio40 &pwm1_gpio41>; 123 status = "okay"; 124}; 125 126&hdmi { 127 hpd-gpios = <&expgpio 4 GPIO_ACTIVE_LOW>; 128}; 129 130/* uart0 communicates with the BT module */ 131&uart0 { 132 pinctrl-names = "default"; 133 pinctrl-0 = <&uart0_gpio32 &gpclk2_gpio43>; 134 status = "okay"; 135 136 bluetooth { 137 compatible = "brcm,bcm43438-bt"; 138 max-speed = <2000000>; 139 shutdown-gpios = <&expgpio 0 GPIO_ACTIVE_HIGH>; 140 }; 141}; 142 143/* uart1 is mapped to the pin header */ 144&uart1 { 145 pinctrl-names = "default"; 146 pinctrl-0 = <&uart1_gpio14>; 147 status = "okay"; 148}; 149 150/* SDHCI is used to control the SDIO for wireless */ 151&sdhci { 152 #address-cells = <1>; 153 #size-cells = <0>; 154 pinctrl-names = "default"; 155 pinctrl-0 = <&emmc_gpio34>; 156 status = "okay"; 157 bus-width = <4>; 158 non-removable; 159 mmc-pwrseq = <&wifi_pwrseq>; 160 161 brcmf: wifi@1 { 162 reg = <1>; 163 compatible = "brcm,bcm4329-fmac"; 164 }; 165}; 166 167/* SDHOST is used to drive the SD card */ 168&sdhost { 169 pinctrl-names = "default"; 170 pinctrl-0 = <&sdhost_gpio48>; 171 status = "okay"; 172 bus-width = <4>; 173}; 174