diff options
-rw-r--r-- | src/radeon_probe.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/src/radeon_probe.c b/src/radeon_probe.c index 42e72596..1429835e 100644 --- a/src/radeon_probe.c +++ b/src/radeon_probe.c @@ -183,13 +183,9 @@ radeon_get_scrninfo(int entity_num, void *pci_dev) pPriv = xf86GetEntityPrivate(pEnt->index, gRADEONEntityIndex); - if (!pPriv->ptr) { - int j; - int instance = xf86GetNumEntityInstances(pEnt->index); - - for (j = 0; j < instance; j++) - xf86SetEntityInstanceForScreen(pScrn, pEnt->index, j); + xf86SetEntityInstanceForScreen(pScrn, pEnt->index, xf86GetNumEntityInstances(pEnt->index) - 1); + if (!pPriv->ptr) { pPriv->ptr = xnfcalloc(sizeof(RADEONEntRec), 1); pRADEONEnt = pPriv->ptr; pRADEONEnt->HasSecondary = FALSE; |