1 From 7802e183f782f20a30d629cef099c911c07e0e4d Mon Sep 17 00:00:00 2001
2 From: Eric Anholt <eric@anholt.net>
3 Date: Fri, 6 May 2016 11:48:35 -0700
4 Subject: [PATCH] BCM270X_DT: Move vc4 node contents to bcm2708_common.dtsi.
6 This should clarify what's going on with the overlay: The hardware is
7 always present, we're just enabling the DT node so that the vc4 driver
10 The interrupts are left in the overlay, because the firmware doesn't
11 check node status before masking out the vc4 interrupts.
13 By having the nodes in the common file, we'll be able to correctly
14 connect the HDMI HPD GPIO so that we can detect whether an HDMI
17 Signed-off-by: Eric Anholt <eric@anholt.net>
19 arch/arm/boot/dts/bcm2708_common.dtsi | 51 +++++++
20 arch/arm/boot/dts/overlays/vc4-kms-v3d-overlay.dts | 160 ++++++++++-----------
21 2 files changed, 129 insertions(+), 82 deletions(-)
23 --- a/arch/arm/boot/dts/bcm2708_common.dtsi
24 +++ b/arch/arm/boot/dts/bcm2708_common.dtsi
26 +#include "dt-bindings/clock/bcm2835.h"
27 #include <dt-bindings/clock/bcm2835-aux.h>
28 +#include "dt-bindings/power/raspberrypi-power.h"
29 +#include "dt-bindings/gpio/gpio.h"
30 #include "skeleton.dtsi"
37 + pixelvalve0: pixelvalve@7e206000 {
38 + compatible = "brcm,bcm2835-pixelvalve0";
39 + reg = <0x7e206000 0x100>;
40 + status = "disabled";
43 + pixelvalve1: pixelvalve@7e207000 {
44 + compatible = "brcm,bcm2835-pixelvalve1";
45 + reg = <0x7e207000 0x100>;
46 + status = "disabled";
50 compatible = "brcm,bcm2835-pwm";
51 reg = <0x7e20c000 0x28>;
57 + compatible = "brcm,bcm2835-hvs";
58 + reg = <0x7e400000 0x6000>;
59 + status = "disabled";
63 compatible = "brcm,bcm2708-i2c";
64 reg = <0x7e804000 0x1000>;
69 + pixelvalve2: pixelvalve@7e807000 {
70 + compatible = "brcm,bcm2835-pixelvalve2";
71 + reg = <0x7e807000 0x100>;
72 + status = "disabled";
75 + hdmi: hdmi@7e902000 {
76 + compatible = "brcm,bcm2835-hdmi";
77 + reg = <0x7e902000 0x600>,
80 + hpd-gpios = <&gpio 46 GPIO_ACTIVE_HIGH>;
81 + clocks = <&cprman BCM2835_PLLH_PIX>,
82 + <&cprman BCM2835_CLOCK_HSM>;
83 + clock-names = "pixel", "hdmi";
84 + power-domains = <&power RPI_POWER_DOMAIN_HDMI>;
85 + status = "disabled";
89 compatible = "brcm,bcm2708-usb";
90 reg = <0x7e980000 0x10000>,
96 + compatible = "brcm,vc4-v3d";
97 + reg = <0x7ec00000 0x1000>;
98 + status = "disabled";
102 compatible = "raspberrypi,bcm2835-firmware";
105 firmware = <&firmware>;
109 + compatible = "brcm,bcm2835-vc4";
110 + status = "disabled";
115 compatible = "brcm,bcm2835-audio";
116 --- a/arch/arm/boot/dts/overlays/vc4-kms-v3d-overlay.dts
117 +++ b/arch/arm/boot/dts/overlays/vc4-kms-v3d-overlay.dts
122 -#include "dt-bindings/clock/bcm2835.h"
123 -#include "dt-bindings/power/raspberrypi-power.h"
124 -#include "dt-bindings/gpio/gpio.h"
127 compatible = "brcm,bcm2835", "brcm,bcm2708", "brcm,bcm2709";
130 + target-path = "/chosen";
132 + bootargs = "cma=256M@256M";
137 + target-path = "/chosen";
139 + bootargs = "cma=192M@256M";
144 + target-path = "/chosen";
146 + bootargs = "cma=128M@128M";
151 + target-path = "/chosen";
153 + bootargs = "cma=96M@128M";
158 + target-path = "/chosen";
160 + bootargs = "cma=64M@64M";
190 + target = <&pixelvalve0>;
192 - #address-cells = <1>;
194 + interrupts = <2 13>; /* pwa0 */
199 - pixelvalve@7e206000 {
200 - compatible = "brcm,bcm2835-pixelvalve0";
201 - reg = <0x7e206000 0x100>;
202 - interrupts = <2 13>; /* pwa0 */
205 - pixelvalve@7e207000 {
206 - compatible = "brcm,bcm2835-pixelvalve1";
207 - reg = <0x7e207000 0x100>;
208 - interrupts = <2 14>; /* pwa1 */
212 - compatible = "brcm,bcm2835-hvs";
213 - reg = <0x7e400000 0x6000>;
214 - interrupts = <2 1>;
217 - pixelvalve@7e807000 {
218 - compatible = "brcm,bcm2835-pixelvalve2";
219 - reg = <0x7e807000 0x100>;
220 - interrupts = <2 10>; /* pixelvalve */
224 - compatible = "brcm,bcm2835-hdmi";
225 - reg = <0x7e902000 0x600>,
226 - <0x7e808000 0x100>;
227 - interrupts = <2 8>, <2 9>;
229 - hpd-gpios = <&gpio 46 GPIO_ACTIVE_HIGH>;
230 - clocks = <&cprman BCM2835_PLLH_PIX>,
231 - <&cprman BCM2835_CLOCK_HSM>;
232 - clock-names = "pixel", "hdmi";
233 - power-domains = <&power RPI_POWER_DOMAIN_HDMI>;
237 - compatible = "brcm,vc4-v3d";
238 - reg = <0x7ec00000 0x1000>;
239 - interrupts = <1 10>;
243 - compatible = "brcm,bcm2835-vc4";
246 + target = <&pixelvalve1>;
248 + interrupts = <2 14>; /* pwa1 */
254 - target-path = "/chosen";
256 - bootargs = "cma=256M@256M";
258 + target = <&pixelvalve2>;
260 + interrupts = <2 10>; /* pixelvalve */
266 - target-path = "/chosen";
268 - bootargs = "cma=192M@256M";
272 + interrupts = <2 1>;
278 - target-path = "/chosen";
280 - bootargs = "cma=128M@128M";
284 + interrupts = <2 8>, <2 9>;
290 - target-path = "/chosen";
292 - bootargs = "cma=96M@128M";
296 + interrupts = <1 10>;
302 - target-path = "/chosen";
304 - bootargs = "cma=64M@64M";
313 - cma-256 = <0>,"+4-5-6-7-8";
314 - cma-192 = <0>,"-4+5-6-7-8";
315 - cma-128 = <0>,"-4-5+6-7-8";
316 - cma-96 = <0>,"-4-5-6+7-8";
317 - cma-64 = <0>,"-4-5-6-7+8";
318 + cma-256 = <0>,"+0-1-2-3-4";
319 + cma-192 = <0>,"-0+1-2-3-4";
320 + cma-128 = <0>,"-0-1+2-3-4";
321 + cma-96 = <0>,"-0-1-2+3-4";
322 + cma-64 = <0>,"-0-1-2-3+4";