summaryrefslogtreecommitdiff
path: root/drivers/gpu
diff options
context:
space:
mode:
authorArnd Bergmann <arnd@arndb.de>2016-04-24 23:56:38 +0200
committerArnd Bergmann <arnd@arndb.de>2016-04-24 23:56:38 +0200
commit312ce1d19155a20c6d829b6e9fc028d4b0238c2b (patch)
treec1f57cc3f4fcaa191038b2faf251052cd49f9e7a /drivers/gpu
parent1ea7c8b6fb23f5a8afec7c7ddc5776550331a2bf (diff)
parent3db62afd11738f896ef83132022a40be74961860 (diff)
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
Diffstat (limited to 'drivers/gpu')
-rw-r--r--drivers/gpu/drm/vc4/vc4_drv.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/drivers/gpu/drm/vc4/vc4_drv.c b/drivers/gpu/drm/vc4/vc4_drv.c
index b7d2ff0e6e1f..109b10651959 100644
--- a/drivers/gpu/drm/vc4/vc4_drv.c
+++ b/drivers/gpu/drm/vc4/vc4_drv.c
@@ -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)
{
struct platform_device *pdev = to_platform_device(dev);
@@ -186,6 +204,8 @@ static int vc4_drm_bind(struct device *dev)
if (ret)
goto gem_destroy;
+ vc4_kick_out_firmware_fb();
+
ret = drm_dev_register(drm, 0);
if (ret < 0)
goto unbind_all;