summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2012-09-07 14:31:52 +0100
committerChris Wilson <chris@chris-wilson.co.uk>2012-09-07 14:37:38 +0100
commit448808d8a4e78afa7fe90e318d6d7afdbff66190 (patch)
tree0a08cf70a11090b3e2195ed74f6e5f4db6d9818d
parent3dce661ef3df5558fe9c9d85324ab3395a37b7ea (diff)
prime: Allocate a GPU_SCREEN when not primary to fulfil the output sink role
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
-rw-r--r--src/intel_module.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/intel_module.c b/src/intel_module.c
index a5d071b1..b4f0ad28 100644
--- a/src/intel_module.c
+++ b/src/intel_module.c
@@ -538,14 +538,22 @@ intel_platform_probe(DriverPtr driver,
{
ScrnInfoPtr scrn = NULL;
char *path = xf86_get_platform_device_attrib(dev, ODEV_ATTRIB_PATH);
+ unsigned scrn_flags = 0;
if (!dev->pdev)
return FALSE;
+
+ /* Allow ourselves to act as a slaved output if not primary */
+ if (flags & PLATFORM_PROBE_GPU_SCREEN) {
+ flags &= ~PLATFORM_PROBE_GPU_SCREEN;
+ scrn_flags |= XF86_ALLOCATE_GPU_SCREEN;
+ }
+
/* if we get any flags we don't understand fail to probe for now */
if (flags)
return FALSE;
- scrn = xf86AllocateScreen(driver, 0);
+ scrn = xf86AllocateScreen(driver, scrn_flags);
if (scrn == NULL)
return FALSE;