summaryrefslogtreecommitdiff
path: root/hw/xfree86/common/xf86Helper.c
diff options
context:
space:
mode:
Diffstat (limited to 'hw/xfree86/common/xf86Helper.c')
-rw-r--r--hw/xfree86/common/xf86Helper.c13
1 files changed, 12 insertions, 1 deletions
diff --git a/hw/xfree86/common/xf86Helper.c b/hw/xfree86/common/xf86Helper.c
index 6a3525052..359bac762 100644
--- a/hw/xfree86/common/xf86Helper.c
+++ b/hw/xfree86/common/xf86Helper.c
@@ -1369,7 +1369,7 @@ xf86MatchDevice(const char *drivername, GDevPtr ** sectlist)
{
GDevPtr gdp, *pgdp = NULL;
confScreenPtr screensecptr;
- int i, j;
+ int i, j, k;
if (sectlist)
*sectlist = NULL;
@@ -1413,6 +1413,17 @@ xf86MatchDevice(const char *drivername, GDevPtr ** sectlist)
pgdp = xnfreallocarray(pgdp, i + 2, sizeof(GDevPtr));
pgdp[i++] = screensecptr->device;
}
+ for (k = 0; k < screensecptr->num_gpu_devices; k++) {
+ if ((screensecptr->gpu_devices[k]->driver != NULL)
+ && (xf86NameCmp(screensecptr->gpu_devices[k]->driver, drivername) == 0)
+ && (!screensecptr->gpu_devices[k]->claimed)) {
+ /*
+ * we have a matching driver that wasn't claimed, yet
+ */
+ pgdp = xnfrealloc(pgdp, (i + 2) * sizeof(GDevPtr));
+ pgdp[i++] = screensecptr->gpu_devices[k];
+ }
+ }
}
/* Then handle the inactive devices */