Commit 312ce1d1 authored by Arnd Bergmann's avatar Arnd Bergmann

Merge tag 'arm-soc/for-4.7/devicetree' of http://github.com/Broadcom/stblinux into next/dt

Merge "Broadcom ARM-based SoC Device Tree changes" from Florian Fainelli:

- Rafal adds proper VCC GPIO to be fed to the USB host controllers for known
  BCM5301x devices needing that, he also enables earlycon, and enables the
  SPI-NOR flashes on relevant devices

- Eric adds the VideoCore 4 Device Tree nodes to the BCM283x Device Tree and
  provides a DRM patch to kick out the simplefb framebuffer to avoid conflicts

- Stephan adds proper CPU nodes for the ARM processor on the BCM2835 SoC Device
  Tree

- Martin provides a binding fix for the DMA channel interrupt numbers and
  description

* tag 'arm-soc/for-4.7/devicetree' of http://github.com/Broadcom/stblinux:
  ARM: BCM5301X: Add DT entry for SPI controller and NOR flash
  dt/bindings: bcm2835: correct description for DMA-int
  ARM: bcm2835: add CPU node for ARM core
  ARM: bcm2835: Add VC4 to the device tree.
  drm/vc4: Kick out the simplefb framebuffer before we set up KMS.
  ARM: BCM5301X: Enable earlycon on tested devices
  ARM: BCM5301X: Set vcc-gpio for USB controllers of few devices
parents 1ea7c8b6 3db62afd
...@@ -71,8 +71,8 @@ Bank 1: ...@@ -71,8 +71,8 @@ Bank 1:
24: DMA8 24: DMA8
25: DMA9 25: DMA9
26: DMA10 26: DMA10
27: DMA11 27: DMA11-14 - shared interrupt for DMA 11 to 14
28: DMA12 28: DMAALL - triggers on all dma interrupts (including chanel 15)
29: AUX 29: AUX
30: ARM 30: ARM
31: VPUDMA 31: VPUDMA
......
...@@ -29,3 +29,7 @@ i2s_alt0: i2s_alt0 { ...@@ -29,3 +29,7 @@ i2s_alt0: i2s_alt0 {
brcm,function = <BCM2835_FSEL_ALT0>; brcm,function = <BCM2835_FSEL_ALT0>;
}; };
}; };
&hdmi {
hpd-gpios = <&gpio 46 GPIO_ACTIVE_LOW>;
};
...@@ -22,3 +22,7 @@ i2s_alt2: i2s_alt2 { ...@@ -22,3 +22,7 @@ i2s_alt2: i2s_alt2 {
brcm,function = <BCM2835_FSEL_ALT2>; brcm,function = <BCM2835_FSEL_ALT2>;
}; };
}; };
&hdmi {
hpd-gpios = <&gpio 46 GPIO_ACTIVE_HIGH>;
};
...@@ -29,3 +29,7 @@ i2s_alt0: i2s_alt0 { ...@@ -29,3 +29,7 @@ i2s_alt0: i2s_alt0 {
brcm,function = <BCM2835_FSEL_ALT0>; brcm,function = <BCM2835_FSEL_ALT0>;
}; };
}; };
&hdmi {
hpd-gpios = <&gpio 46 GPIO_ACTIVE_LOW>;
};
...@@ -22,3 +22,7 @@ i2s_alt2: i2s_alt2 { ...@@ -22,3 +22,7 @@ i2s_alt2: i2s_alt2 {
brcm,function = <BCM2835_FSEL_ALT2>; brcm,function = <BCM2835_FSEL_ALT2>;
}; };
}; };
&hdmi {
hpd-gpios = <&gpio 46 GPIO_ACTIVE_LOW>;
};
...@@ -16,3 +16,7 @@ act { ...@@ -16,3 +16,7 @@ act {
&gpio { &gpio {
pinctrl-0 = <&gpioout &alt0 &alt3>; pinctrl-0 = <&gpioout &alt0 &alt3>;
}; };
&hdmi {
hpd-gpios = <&gpio 46 GPIO_ACTIVE_HIGH>;
};
...@@ -74,3 +74,12 @@ &pwm { ...@@ -74,3 +74,12 @@ &pwm {
&usb { &usb {
power-domains = <&power RPI_POWER_DOMAIN_USB>; power-domains = <&power RPI_POWER_DOMAIN_USB>;
}; };
&v3d {
power-domains = <&power RPI_POWER_DOMAIN_V3D>;
};
&hdmi {
power-domains = <&power RPI_POWER_DOMAIN_HDMI>;
status = "okay";
};
...@@ -3,6 +3,17 @@ ...@@ -3,6 +3,17 @@
/ { / {
compatible = "brcm,bcm2835"; compatible = "brcm,bcm2835";
cpus {
#address-cells = <1>;
#size-cells = <0>;
cpu@0 {
device_type = "cpu";
compatible = "arm,arm1176jzf-s";
reg = <0x0>;
};
};
soc { soc {
ranges = <0x7e000000 0x20000000 0x02000000>; ranges = <0x7e000000 0x20000000 0x02000000>;
dma-ranges = <0x40000000 0x00000000 0x20000000>; dma-ranges = <0x40000000 0x00000000 0x20000000>;
......
...@@ -33,3 +33,7 @@ i2s_alt0: i2s_alt0 { ...@@ -33,3 +33,7 @@ i2s_alt0: i2s_alt0 {
brcm,function = <BCM2835_FSEL_ALT0>; brcm,function = <BCM2835_FSEL_ALT0>;
}; };
}; };
&hdmi {
hpd-gpios = <&gpio 46 GPIO_ACTIVE_LOW>;
};
#include <dt-bindings/pinctrl/bcm2835.h> #include <dt-bindings/pinctrl/bcm2835.h>
#include <dt-bindings/clock/bcm2835.h> #include <dt-bindings/clock/bcm2835.h>
#include <dt-bindings/clock/bcm2835-aux.h> #include <dt-bindings/clock/bcm2835-aux.h>
#include <dt-bindings/gpio/gpio.h>
#include "skeleton.dtsi" #include "skeleton.dtsi"
/* This include file covers the common peripherals and configuration between /* This include file covers the common peripherals and configuration between
...@@ -153,6 +154,18 @@ i2c0: i2c@7e205000 { ...@@ -153,6 +154,18 @@ i2c0: i2c@7e205000 {
status = "disabled"; status = "disabled";
}; };
pixelvalve@7e206000 {
compatible = "brcm,bcm2835-pixelvalve0";
reg = <0x7e206000 0x100>;
interrupts = <2 13>; /* pwa0 */
};
pixelvalve@7e207000 {
compatible = "brcm,bcm2835-pixelvalve1";
reg = <0x7e207000 0x100>;
interrupts = <2 14>; /* pwa1 */
};
aux: aux@0x7e215000 { aux: aux@0x7e215000 {
compatible = "brcm,bcm2835-aux"; compatible = "brcm,bcm2835-aux";
#clock-cells = <1>; #clock-cells = <1>;
...@@ -206,6 +219,12 @@ sdhci: sdhci@7e300000 { ...@@ -206,6 +219,12 @@ sdhci: sdhci@7e300000 {
status = "disabled"; status = "disabled";
}; };
hvs@7e400000 {
compatible = "brcm,bcm2835-hvs";
reg = <0x7e400000 0x6000>;
interrupts = <2 1>;
};
i2c1: i2c@7e804000 { i2c1: i2c@7e804000 {
compatible = "brcm,bcm2835-i2c"; compatible = "brcm,bcm2835-i2c";
reg = <0x7e804000 0x1000>; reg = <0x7e804000 0x1000>;
...@@ -226,11 +245,39 @@ i2c2: i2c@7e805000 { ...@@ -226,11 +245,39 @@ i2c2: i2c@7e805000 {
status = "disabled"; status = "disabled";
}; };
pixelvalve@7e807000 {
compatible = "brcm,bcm2835-pixelvalve2";
reg = <0x7e807000 0x100>;
interrupts = <2 10>; /* pixelvalve */
};
hdmi: hdmi@7e902000 {
compatible = "brcm,bcm2835-hdmi";
reg = <0x7e902000 0x600>,
<0x7e808000 0x100>;
interrupts = <2 8>, <2 9>;
ddc = <&i2c2>;
clocks = <&clocks BCM2835_PLLH_PIX>,
<&clocks BCM2835_CLOCK_HSM>;
clock-names = "pixel", "hdmi";
status = "disabled";
};
usb: usb@7e980000 { usb: usb@7e980000 {
compatible = "brcm,bcm2835-usb"; compatible = "brcm,bcm2835-usb";
reg = <0x7e980000 0x10000>; reg = <0x7e980000 0x10000>;
interrupts = <1 9>; interrupts = <1 9>;
}; };
v3d: v3d@7ec00000 {
compatible = "brcm,bcm2835-v3d";
reg = <0x7ec00000 0x1000>;
interrupts = <1 10>;
};
vc4: gpu {
compatible = "brcm,bcm2835-vc4";
};
}; };
clocks { clocks {
......
...@@ -17,7 +17,7 @@ / { ...@@ -17,7 +17,7 @@ / {
model = "Buffalo WZR-1750DHP (BCM4708)"; model = "Buffalo WZR-1750DHP (BCM4708)";
chosen { chosen {
bootargs = "console=ttyS0,115200"; bootargs = "console=ttyS0,115200 earlycon";
}; };
memory { memory {
...@@ -139,3 +139,11 @@ eject { ...@@ -139,3 +139,11 @@ eject {
&uart0 { &uart0 {
status = "okay"; status = "okay";
}; };
&usb2 {
vcc-gpio = <&chipcommon 9 GPIO_ACTIVE_HIGH>;
};
&usb3 {
vcc-gpio = <&chipcommon 10 GPIO_ACTIVE_LOW>;
};
...@@ -17,7 +17,7 @@ / { ...@@ -17,7 +17,7 @@ / {
model = "Luxul XWC-1000 (BCM4708)"; model = "Luxul XWC-1000 (BCM4708)";
chosen { chosen {
bootargs = "console=ttyS0,115200"; bootargs = "console=ttyS0,115200 earlycon";
}; };
memory { memory {
...@@ -59,3 +59,7 @@ restart { ...@@ -59,3 +59,7 @@ restart {
&uart0 { &uart0 {
status = "okay"; status = "okay";
}; };
&spi_nor {
status = "okay";
};
...@@ -17,24 +17,13 @@ / { ...@@ -17,24 +17,13 @@ / {
model = "Netgear R6250 V1 (BCM4708)"; model = "Netgear R6250 V1 (BCM4708)";
chosen { chosen {
bootargs = "console=ttyS0,115200"; bootargs = "console=ttyS0,115200 earlycon";
}; };
memory { memory {
reg = <0x00000000 0x08000000>; reg = <0x00000000 0x08000000>;
}; };
axi@18000000 {
usb3@23000 {
reg = <0x00023000 0x1000>;
#address-cells = <1>;
#size-cells = <1>;
vcc-gpio = <&chipcommon 0 GPIO_ACTIVE_HIGH>;
};
};
leds { leds {
compatible = "gpio-leds"; compatible = "gpio-leds";
...@@ -97,3 +86,7 @@ restart { ...@@ -97,3 +86,7 @@ restart {
&uart0 { &uart0 {
status = "okay"; status = "okay";
}; };
&usb3 {
vcc-gpio = <&chipcommon 0 GPIO_ACTIVE_HIGH>;
};
...@@ -17,7 +17,7 @@ / { ...@@ -17,7 +17,7 @@ / {
model = "SmartRG SR400ac"; model = "SmartRG SR400ac";
chosen { chosen {
bootargs = "console=ttyS0,115200"; bootargs = "console=ttyS0,115200 earlycon";
}; };
memory { memory {
...@@ -122,3 +122,7 @@ restart { ...@@ -122,3 +122,7 @@ restart {
&uart0 { &uart0 {
status = "okay"; status = "okay";
}; };
&spi_nor {
status = "okay";
};
...@@ -17,7 +17,7 @@ / { ...@@ -17,7 +17,7 @@ / {
model = "Buffalo WZR-600DHP2 (BCM47081)"; model = "Buffalo WZR-600DHP2 (BCM47081)";
chosen { chosen {
bootargs = "console=ttyS0,115200"; bootargs = "console=ttyS0,115200 earlycon";
}; };
memory { memory {
......
...@@ -126,3 +126,8 @@ eject { ...@@ -126,3 +126,8 @@ eject {
}; };
}; };
}; };
&usb2 {
vcc-gpio = <&chipcommon 13 GPIO_ACTIVE_HIGH>;
};
...@@ -106,3 +106,11 @@ restart { ...@@ -106,3 +106,11 @@ restart {
}; };
}; };
}; };
&usb2 {
vcc-gpio = <&chipcommon 0 GPIO_ACTIVE_HIGH>;
};
&usb3 {
vcc-gpio = <&chipcommon 0 GPIO_ACTIVE_HIGH>;
};
...@@ -17,7 +17,7 @@ / { ...@@ -17,7 +17,7 @@ / {
model = "D-Link DIR-885L"; model = "D-Link DIR-885L";
chosen { chosen {
bootargs = "console=ttyS0,115200"; bootargs = "console=ttyS0,115200 earlycon";
}; };
memory { memory {
...@@ -109,3 +109,7 @@ &uart0 { ...@@ -109,3 +109,7 @@ &uart0 {
status = "okay"; status = "okay";
clock-frequency = <125000000>; clock-frequency = <125000000>;
}; };
&usb3 {
vcc-gpio = <&chipcommon 18 GPIO_ACTIVE_HIGH>;
};
...@@ -18,6 +18,10 @@ ...@@ -18,6 +18,10 @@
/ { / {
interrupt-parent = <&gic>; interrupt-parent = <&gic>;
chosen {
stdout-path = &uart0;
};
chipcommonA { chipcommonA {
compatible = "simple-bus"; compatible = "simple-bus";
ranges = <0x00000000 0x18000000 0x00001000>; ranges = <0x00000000 0x18000000 0x00001000>;
...@@ -207,6 +211,34 @@ chipcommon: chipcommon@0 { ...@@ -207,6 +211,34 @@ chipcommon: chipcommon@0 {
gpio-controller; gpio-controller;
#gpio-cells = <2>; #gpio-cells = <2>;
}; };
usb2: usb2@21000 {
reg = <0x00021000 0x1000>;
#address-cells = <1>;
#size-cells = <1>;
};
usb3: usb3@23000 {
reg = <0x00023000 0x1000>;
#address-cells = <1>;
#size-cells = <1>;
};
spi@29000 {
reg = <0x00029000 0x1000>;
#address-cells = <1>;
#size-cells = <0>;
spi_nor: spi-nor@0 {
compatible = "jedec,spi-nor";
reg = <0>;
spi-max-frequency = <20000000>;
linux,part-probe = "ofpart", "bcm47xxpart";
status = "disabled";
};
};
}; };
lcpll0: lcpll0@1800c100 { lcpll0: lcpll0@1800c100 {
......
...@@ -153,6 +153,24 @@ static void vc4_match_add_drivers(struct device *dev, ...@@ -153,6 +153,24 @@ static void vc4_match_add_drivers(struct device *dev,
} }
} }
static void vc4_kick_out_firmware_fb(void)
{
struct apertures_struct *ap;
ap = alloc_apertures(1);
if (!ap)
return;
/* Since VC4 is a UMA device, the simplefb node may have been
* located anywhere in memory.
*/
ap->ranges[0].base = 0;
ap->ranges[0].size = ~0;
remove_conflicting_framebuffers(ap, "vc4drmfb", false);
kfree(ap);
}
static int vc4_drm_bind(struct device *dev) static int vc4_drm_bind(struct device *dev)
{ {
struct platform_device *pdev = to_platform_device(dev); struct platform_device *pdev = to_platform_device(dev);
...@@ -186,6 +204,8 @@ static int vc4_drm_bind(struct device *dev) ...@@ -186,6 +204,8 @@ static int vc4_drm_bind(struct device *dev)
if (ret) if (ret)
goto gem_destroy; goto gem_destroy;
vc4_kick_out_firmware_fb();
ret = drm_dev_register(drm, 0); ret = drm_dev_register(drm, 0);
if (ret < 0) if (ret < 0)
goto unbind_all; goto unbind_all;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment