Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

Merge tag 'tags/bcm2835-dt-next-2019-02-01' into devicetree/next

This pull request adds support for the new Raspberry Pi 3 A+ and
the missing GPIO labels for RPi 2/3. Additionally it contains
some minor DT fixes.

Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>

+401 -24
+4
Documentation/devicetree/bindings/arm/bcm/brcm,bcm2835.txt
··· 30 30 Required root node properties: 31 31 compatible = "raspberrypi,2-model-b", "brcm,bcm2836"; 32 32 33 + Raspberry Pi 3 Model A+ 34 + Required root node properties: 35 + compatible = "raspberrypi,3-model-a-plus", "brcm,bcm2837"; 36 + 33 37 Raspberry Pi 3 Model B 34 38 Required root node properties: 35 39 compatible = "raspberrypi,3-model-b", "brcm,bcm2837";
+1
arch/arm/boot/dts/Makefile
··· 79 79 bcm2835-rpi-a-plus.dtb \ 80 80 bcm2835-rpi-cm1-io1.dtb \ 81 81 bcm2836-rpi-2-b.dtb \ 82 + bcm2837-rpi-3-a-plus.dtb \ 82 83 bcm2837-rpi-3-b.dtb \ 83 84 bcm2837-rpi-3-b-plus.dtb \ 84 85 bcm2837-rpi-cm3-io3.dtb \
+2 -2
arch/arm/boot/dts/bcm2835-rpi-a-plus.dts
··· 31 31 * "FOO" = GPIO line named "FOO" on the schematic 32 32 * "FOO_N" = GPIO line named "FOO" on schematic, active low 33 33 */ 34 - gpio-line-names = "SDA0", 35 - "SCL0", 34 + gpio-line-names = "ID_SDA", 35 + "ID_SCL", 36 36 "SDA1", 37 37 "SCL1", 38 38 "GPIO_GCLK",
+2 -2
arch/arm/boot/dts/bcm2835-rpi-b-plus.dts
··· 33 33 * "FOO" = GPIO line named "FOO" on the schematic 34 34 * "FOO_N" = GPIO line named "FOO" on schematic, active low 35 35 */ 36 - gpio-line-names = "SDA0", 37 - "SCL0", 36 + gpio-line-names = "ID_SDA", 37 + "ID_SCL", 38 38 "SDA1", 39 39 "SCL1", 40 40 "GPIO_GCLK",
+2 -9
arch/arm/boot/dts/bcm2835-rpi-zero-w.dts
··· 25 25 26 26 wifi_pwrseq: wifi-pwrseq { 27 27 compatible = "mmc-pwrseq-simple"; 28 - pinctrl-names = "default"; 29 - pinctrl-0 = <&wl_on>; 30 28 reset-gpios = <&gpio 41 GPIO_ACTIVE_LOW>; 31 29 }; 32 30 }; ··· 38 40 * "FOO" = GPIO line named "FOO" on the schematic 39 41 * "FOO_N" = GPIO line named "FOO" on schematic, active low 40 42 */ 41 - gpio-line-names = "GPIO0", 42 - "GPIO1", 43 + gpio-line-names = "ID_SDA", 44 + "ID_SCL", 43 45 "SDA1", 44 46 "SCL1", 45 47 "GPIO_GCLK", ··· 96 98 "SD_DATA3_R"; 97 99 98 100 pinctrl-0 = <&gpioout &alt0>; 99 - 100 - wl_on: wl-on { 101 - brcm,pins = <41>; 102 - brcm,function = <BCM2835_FSEL_GPIO_OUT>; 103 - }; 104 101 }; 105 102 106 103 &hdmi {
+2 -2
arch/arm/boot/dts/bcm2835-rpi-zero.dts
··· 28 28 * "FOO" = GPIO line named "FOO" on the schematic 29 29 * "FOO_N" = GPIO line named "FOO" on schematic, active low 30 30 */ 31 - gpio-line-names = "SDA0", 32 - "SCL0", 31 + gpio-line-names = "ID_SDA", 32 + "ID_SCL", 33 33 "SDA1", 34 34 "SCL1", 35 35 "GPIO_GCLK",
+1 -3
arch/arm/boot/dts/bcm2835-rpi.dtsi
··· 1 1 #include <dt-bindings/power/raspberrypi-power.h> 2 2 3 3 / { 4 - memory { 4 + memory@0 { 5 5 device_type = "memory"; 6 6 reg = <0 0x10000000>; 7 7 }; ··· 19 19 soc { 20 20 firmware: firmware { 21 21 compatible = "raspberrypi,bcm2835-firmware", "simple-bus"; 22 - #address-cells = <0>; 23 - #size-cells = <0>; 24 22 mboxes = <&mailbox>; 25 23 }; 26 24
+67 -1
arch/arm/boot/dts/bcm2836-rpi-2-b.dts
··· 9 9 compatible = "raspberrypi,2-model-b", "brcm,bcm2836"; 10 10 model = "Raspberry Pi 2 Model B"; 11 11 12 - memory { 12 + memory@0 { 13 13 reg = <0 0x40000000>; 14 14 }; 15 15 ··· 28 28 }; 29 29 30 30 &gpio { 31 + /* 32 + * Taken from rpi_SCH_2b_1p2_reduced.pdf and 33 + * the official GPU firmware DT blob. 34 + * 35 + * Legend: 36 + * "NC" = not connected (no rail from the SoC) 37 + * "FOO" = GPIO line named "FOO" on the schematic 38 + * "FOO_N" = GPIO line named "FOO" on schematic, active low 39 + */ 40 + gpio-line-names = "ID_SDA", 41 + "ID_SCL", 42 + "SDA1", 43 + "SCL1", 44 + "GPIO_GCLK", 45 + "GPIO5", 46 + "GPIO6", 47 + "SPI_CE1_N", 48 + "SPI_CE0_N", 49 + "SPI_MISO", 50 + "SPI_MOSI", 51 + "SPI_SCLK", 52 + "GPIO12", 53 + "GPIO13", 54 + /* Serial port */ 55 + "TXD0", 56 + "RXD0", 57 + "GPIO16", 58 + "GPIO17", 59 + "GPIO18", 60 + "GPIO19", 61 + "GPIO20", 62 + "GPIO21", 63 + "GPIO22", 64 + "GPIO23", 65 + "GPIO24", 66 + "GPIO25", 67 + "GPIO26", 68 + "GPIO27", 69 + "SDA0", 70 + "SCL0", 71 + "", /* GPIO30 */ 72 + "LAN_RUN", 73 + "CAM_GPIO1", 74 + "", /* GPIO33 */ 75 + "", /* GPIO34 */ 76 + "PWR_LOW_N", 77 + "", /* GPIO36 */ 78 + "", /* GPIO37 */ 79 + "USB_LIMIT", 80 + "", /* GPIO39 */ 81 + "PWM0_OUT", 82 + "CAM_GPIO0", 83 + "SMPS_SCL", 84 + "SMPS_SDA", 85 + "ETHCLK", 86 + "PWM1_OUT", 87 + "HDMI_HPD_N", 88 + "STATUS_LED", 89 + /* Used by SD Card */ 90 + "SD_CLK_R", 91 + "SD_CMD_R", 92 + "SD_DATA0_R", 93 + "SD_DATA1_R", 94 + "SD_DATA2_R", 95 + "SD_DATA3_R"; 96 + 31 97 pinctrl-0 = <&gpioout &alt0 &i2s_alt0>; 32 98 33 99 /* I2S interface */
+175
arch/arm/boot/dts/bcm2837-rpi-3-a-plus.dts
··· 1 + // SPDX-License-Identifier: GPL-2.0 2 + /dts-v1/; 3 + #include "bcm2837.dtsi" 4 + #include "bcm2836-rpi.dtsi" 5 + #include "bcm283x-rpi-usb-host.dtsi" 6 + 7 + / { 8 + compatible = "raspberrypi,3-model-a-plus", "brcm,bcm2837"; 9 + model = "Raspberry Pi 3 Model A+"; 10 + 11 + chosen { 12 + /* 8250 auxiliary UART instead of pl011 */ 13 + stdout-path = "serial1:115200n8"; 14 + }; 15 + 16 + memory@0 { 17 + reg = <0 0x20000000>; 18 + }; 19 + 20 + leds { 21 + act { 22 + gpios = <&gpio 29 GPIO_ACTIVE_HIGH>; 23 + }; 24 + 25 + pwr { 26 + label = "PWR"; 27 + gpios = <&expgpio 2 GPIO_ACTIVE_LOW>; 28 + }; 29 + }; 30 + }; 31 + 32 + &firmware { 33 + expgpio: gpio { 34 + compatible = "raspberrypi,firmware-gpio"; 35 + gpio-controller; 36 + #gpio-cells = <2>; 37 + gpio-line-names = "", 38 + "BT_WL_ON", 39 + "STATUS_LED_R", 40 + "", 41 + "", 42 + "CAM_GPIO0", 43 + "CAM_GPIO1", 44 + ""; 45 + status = "okay"; 46 + }; 47 + }; 48 + 49 + &gpio { 50 + /* 51 + * This is mostly based on the official GPU firmware DT blob. 52 + * 53 + * Legend: 54 + * "NC" = not connected (no rail from the SoC) 55 + * "FOO" = GPIO line named "FOO" on the schematic 56 + * "FOO_N" = GPIO line named "FOO" on schematic, active low 57 + */ 58 + gpio-line-names = "ID_SDA", 59 + "ID_SCL", 60 + "SDA1", 61 + "SCL1", 62 + "GPIO_GCLK", 63 + "GPIO5", 64 + "GPIO6", 65 + "SPI_CE1_N", 66 + "SPI_CE0_N", 67 + "SPI_MISO", 68 + "SPI_MOSI", 69 + "SPI_SCLK", 70 + "GPIO12", 71 + "GPIO13", 72 + /* Serial port */ 73 + "TXD1", 74 + "RXD1", 75 + "GPIO16", 76 + "GPIO17", 77 + "GPIO18", 78 + "GPIO19", 79 + "GPIO20", 80 + "GPIO21", 81 + "GPIO22", 82 + "GPIO23", 83 + "GPIO24", 84 + "GPIO25", 85 + "GPIO26", 86 + "GPIO27", 87 + "HDMI_HPD_N", 88 + "STATUS_LED_G", 89 + /* Used by BT module */ 90 + "CTS0", 91 + "RTS0", 92 + "TXD0", 93 + "RXD0", 94 + /* Used by Wifi */ 95 + "SD1_CLK", 96 + "SD1_CMD", 97 + "SD1_DATA0", 98 + "SD1_DATA1", 99 + "SD1_DATA2", 100 + "SD1_DATA3", 101 + "PWM0_OUT", 102 + "PWM1_OUT", 103 + "", /* GPIO42 */ 104 + "WIFI_CLK", 105 + "SDA0", 106 + "SCL0", 107 + "SMPS_SCL", 108 + "SMPS_SDA", 109 + /* Used by SD Card */ 110 + "SD_CLK_R", 111 + "SD_CMD_R", 112 + "SD_DATA0_R", 113 + "SD_DATA1_R", 114 + "SD_DATA2_R", 115 + "SD_DATA3_R"; 116 + }; 117 + 118 + &hdmi { 119 + hpd-gpios = <&gpio 28 GPIO_ACTIVE_LOW>; 120 + }; 121 + 122 + &pwm { 123 + pinctrl-names = "default"; 124 + pinctrl-0 = <&pwm0_gpio40 &pwm1_gpio41>; 125 + status = "okay"; 126 + }; 127 + 128 + /* 129 + * SDHCI is used to control the SDIO for wireless 130 + * 131 + * WL_REG_ON and BT_REG_ON of the CYW43455 Wifi/BT module are driven 132 + * by a single GPIO. We can't give GPIO control to one of the drivers, 133 + * otherwise the other part would get unexpectedly disturbed. 134 + */ 135 + &sdhci { 136 + #address-cells = <1>; 137 + #size-cells = <0>; 138 + pinctrl-names = "default"; 139 + pinctrl-0 = <&emmc_gpio34>; 140 + status = "okay"; 141 + bus-width = <4>; 142 + non-removable; 143 + 144 + brcmf: wifi@1 { 145 + reg = <1>; 146 + compatible = "brcm,bcm4329-fmac"; 147 + }; 148 + }; 149 + 150 + /* SDHOST is used to drive the SD card */ 151 + &sdhost { 152 + pinctrl-names = "default"; 153 + pinctrl-0 = <&sdhost_gpio48>; 154 + status = "okay"; 155 + bus-width = <4>; 156 + }; 157 + 158 + /* uart0 communicates with the BT module */ 159 + &uart0 { 160 + pinctrl-names = "default"; 161 + pinctrl-0 = <&uart0_ctsrts_gpio30 &uart0_gpio32 &gpclk2_gpio43>; 162 + status = "okay"; 163 + 164 + bluetooth { 165 + compatible = "brcm,bcm43438-bt"; 166 + max-speed = <2000000>; 167 + }; 168 + }; 169 + 170 + /* uart1 is mapped to the pin header */ 171 + &uart1 { 172 + pinctrl-names = "default"; 173 + pinctrl-0 = <&uart1_gpio14>; 174 + status = "okay"; 175 + };
+72 -2
arch/arm/boot/dts/bcm2837-rpi-3-b-plus.dts
··· 14 14 stdout-path = "serial1:115200n8"; 15 15 }; 16 16 17 - memory { 17 + memory@0 { 18 18 reg = <0 0x40000000>; 19 19 }; 20 20 ··· 42 42 #gpio-cells = <2>; 43 43 gpio-line-names = "BT_ON", 44 44 "WL_ON", 45 - "STATUS_LED", 45 + "STATUS_LED_R", 46 46 "LAN_RUN", 47 47 "", 48 48 "CAM_GPIO0", ··· 50 50 ""; 51 51 status = "okay"; 52 52 }; 53 + }; 54 + 55 + &gpio { 56 + /* 57 + * Taken from rpi_SCH_3bplus_1p0_reduced.pdf and 58 + * the official GPU firmware DT blob. 59 + * 60 + * Legend: 61 + * "NC" = not connected (no rail from the SoC) 62 + * "FOO" = GPIO line named "FOO" on the schematic 63 + * "FOO_N" = GPIO line named "FOO" on schematic, active low 64 + */ 65 + gpio-line-names = "ID_SDA", 66 + "ID_SCL", 67 + "SDA1", 68 + "SCL1", 69 + "GPIO_GCLK", 70 + "GPIO5", 71 + "GPIO6", 72 + "SPI_CE1_N", 73 + "SPI_CE0_N", 74 + "SPI_MISO", 75 + "SPI_MOSI", 76 + "SPI_SCLK", 77 + "GPIO12", 78 + "GPIO13", 79 + /* Serial port */ 80 + "TXD1", 81 + "RXD1", 82 + "GPIO16", 83 + "GPIO17", 84 + "GPIO18", 85 + "GPIO19", 86 + "GPIO20", 87 + "GPIO21", 88 + "GPIO22", 89 + "GPIO23", 90 + "GPIO24", 91 + "GPIO25", 92 + "GPIO26", 93 + "GPIO27", 94 + "HDMI_HPD_N", 95 + "STATUS_LED_G", 96 + /* Used by BT module */ 97 + "CTS0", 98 + "RTS0", 99 + "TXD0", 100 + "RXD0", 101 + /* Used by Wifi */ 102 + "SD1_CLK", 103 + "SD1_CMD", 104 + "SD1_DATA0", 105 + "SD1_DATA1", 106 + "SD1_DATA2", 107 + "SD1_DATA3", 108 + "PWM0_OUT", 109 + "PWM1_OUT", 110 + "ETHCLK", 111 + "WIFI_CLK", 112 + "SDA0", 113 + "SCL0", 114 + "SMPS_SCL", 115 + "SMPS_SDA", 116 + /* Used by SD Card */ 117 + "SD_CLK_R", 118 + "SD_CMD_R", 119 + "SD_DATA0_R", 120 + "SD_DATA1_R", 121 + "SD_DATA2_R", 122 + "SD_DATA3_R"; 53 123 }; 54 124 55 125 &hdmi {
+72 -2
arch/arm/boot/dts/bcm2837-rpi-3-b.dts
··· 14 14 stdout-path = "serial1:115200n8"; 15 15 }; 16 16 17 - memory { 17 + memory@0 { 18 18 reg = <0 0x40000000>; 19 19 }; 20 20 ··· 39 39 "WL_ON", 40 40 "STATUS_LED", 41 41 "LAN_RUN", 42 - "HPD_N", 42 + "HDMI_HPD_N", 43 43 "CAM_GPIO0", 44 44 "CAM_GPIO1", 45 45 "PWR_LOW_N"; 46 46 status = "okay"; 47 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"; 48 118 }; 49 119 50 120 &pwm {
+1 -1
arch/arm/boot/dts/bcm2837-rpi-cm3.dtsi
··· 4 4 #include "bcm2836-rpi.dtsi" 5 5 6 6 / { 7 - memory { 7 + memory@0 { 8 8 reg = <0 0x40000000>; 9 9 }; 10 10