Back to home page

OSCL-LXR

 
 

    


0001 // SPDX-License-Identifier: GPL-2.0
0002 /dts-v1/;
0003 #include "bcm2837.dtsi"
0004 #include "bcm2836-rpi.dtsi"
0005 #include "bcm283x-rpi-lan7515.dtsi"
0006 #include "bcm283x-rpi-usb-host.dtsi"
0007 #include "bcm283x-rpi-wifi-bt.dtsi"
0008 
0009 / {
0010         compatible = "raspberrypi,3-model-b-plus", "brcm,bcm2837";
0011         model = "Raspberry Pi 3 Model B+";
0012 
0013         chosen {
0014                 /* 8250 auxiliary UART instead of pl011 */
0015                 stdout-path = "serial1:115200n8";
0016         };
0017 
0018         memory@0 {
0019                 device_type = "memory";
0020                 reg = <0 0x40000000>;
0021         };
0022 
0023         leds {
0024                 led-act {
0025                         gpios = <&gpio 29 GPIO_ACTIVE_HIGH>;
0026                 };
0027 
0028                 led-pwr {
0029                         label = "PWR";
0030                         gpios = <&expgpio 2 GPIO_ACTIVE_LOW>;
0031                         default-state = "keep";
0032                         linux,default-trigger = "default-on";
0033                 };
0034         };
0035 };
0036 
0037 &bt {
0038         shutdown-gpios = <&expgpio 0 GPIO_ACTIVE_HIGH>;
0039 };
0040 
0041 &firmware {
0042         expgpio: gpio {
0043                 compatible = "raspberrypi,firmware-gpio";
0044                 gpio-controller;
0045                 #gpio-cells = <2>;
0046                 gpio-line-names = "BT_ON",
0047                                   "WL_ON",
0048                                   "PWR_LED_R",
0049                                   "LAN_RUN",
0050                                   "",
0051                                   "CAM_GPIO0",
0052                                   "CAM_GPIO1",
0053                                   "";
0054                 status = "okay";
0055         };
0056 };
0057 
0058 &gpio {
0059         /*
0060          * Taken from rpi_SCH_3bplus_1p0_reduced.pdf and
0061          * the official GPU firmware DT blob.
0062          *
0063          * Legend:
0064          * "FOO" = GPIO line named "FOO" on the schematic
0065          * "FOO_N" = GPIO line named "FOO" on schematic, active low
0066          */
0067         gpio-line-names = "ID_SDA",
0068                           "ID_SCL",
0069                           "SDA1",
0070                           "SCL1",
0071                           "GPIO_GCLK",
0072                           "GPIO5",
0073                           "GPIO6",
0074                           "SPI_CE1_N",
0075                           "SPI_CE0_N",
0076                           "SPI_MISO",
0077                           "SPI_MOSI",
0078                           "SPI_SCLK",
0079                           "GPIO12",
0080                           "GPIO13",
0081                           /* Serial port */
0082                           "TXD1",
0083                           "RXD1",
0084                           "GPIO16",
0085                           "GPIO17",
0086                           "GPIO18",
0087                           "GPIO19",
0088                           "GPIO20",
0089                           "GPIO21",
0090                           "GPIO22",
0091                           "GPIO23",
0092                           "GPIO24",
0093                           "GPIO25",
0094                           "GPIO26",
0095                           "GPIO27",
0096                           "HDMI_HPD_N",
0097                           "STATUS_LED_G",
0098                           /* Used by BT module */
0099                           "CTS0",
0100                           "RTS0",
0101                           "TXD0",
0102                           "RXD0",
0103                           /* Used by Wifi */
0104                           "SD1_CLK",
0105                           "SD1_CMD",
0106                           "SD1_DATA0",
0107                           "SD1_DATA1",
0108                           "SD1_DATA2",
0109                           "SD1_DATA3",
0110                           "PWM0_OUT",
0111                           "PWM1_OUT",
0112                           "ETH_CLK",
0113                           "WIFI_CLK",
0114                           "SDA0",
0115                           "SCL0",
0116                           "SMPS_SCL",
0117                           "SMPS_SDA",
0118                           /* Used by SD Card */
0119                           "SD_CLK_R",
0120                           "SD_CMD_R",
0121                           "SD_DATA0_R",
0122                           "SD_DATA1_R",
0123                           "SD_DATA2_R",
0124                           "SD_DATA3_R";
0125 };
0126 
0127 &hdmi {
0128         hpd-gpios = <&gpio 28 GPIO_ACTIVE_LOW>;
0129         power-domains = <&power RPI_POWER_DOMAIN_HDMI>;
0130         status = "okay";
0131 };
0132 
0133 &pwm {
0134         pinctrl-names = "default";
0135         pinctrl-0 = <&pwm0_gpio40 &pwm1_gpio41>;
0136         status = "okay";
0137 };
0138 
0139 /* SDHOST is used to drive the SD card */
0140 &sdhost {
0141         pinctrl-names = "default";
0142         pinctrl-0 = <&sdhost_gpio48>;
0143         status = "okay";
0144         bus-width = <4>;
0145 };
0146 
0147 /* uart0 communicates with the BT module */
0148 &uart0 {
0149         pinctrl-names = "default";
0150         pinctrl-0 = <&uart0_ctsrts_gpio30 &uart0_gpio32 &gpclk2_gpio43>;
0151 };
0152 
0153 /* uart1 is mapped to the pin header */
0154 &uart1 {
0155         pinctrl-names = "default";
0156         pinctrl-0 = <&uart1_gpio14>;
0157         status = "okay";
0158 };
0159 
0160 &wifi_pwrseq {
0161         reset-gpios = <&expgpio 1 GPIO_ACTIVE_LOW>;
0162 };