Don't require that the screen explicitly attach the device section
This will allow the screen to not explicitly have a device section. If this is the case and there is a device section in the xorg.conf, the first one will be used. If there is no device section at all, a default one will be created that loads the automatically determined module.
This commit is contained in:
parent
37898b824f
commit
8665cf3327
|
@ -1939,11 +1939,20 @@ configScreen(confScreenPtr screenp, XF86ConfScreenPtr conf_screen, int scrnum,
|
|||
if (!configMonitor(screenp->monitor,conf_screen->scrn_monitor))
|
||||
return FALSE;
|
||||
}
|
||||
/* Configure the device. If there isn't one configured, attach to the
|
||||
* first inactive one that we can configure. If there's none that work,
|
||||
* set it to NULL so that the section can be autoconfigured later */
|
||||
screenp->device = xnfcalloc(1, sizeof(GDevRec));
|
||||
if (configDevice(screenp->device,conf_screen->scrn_device, TRUE))
|
||||
if ((!conf_screen->scrn_device) && (xf86configptr->conf_device_lst)) {
|
||||
conf_screen->scrn_device = xf86configptr->conf_device_lst;
|
||||
xf86Msg(X_DEFAULT, "No device specified for screen \"%s\".\n"
|
||||
"\tUsing the first device section listed.\n", screenp->id);
|
||||
}
|
||||
if (configDevice(screenp->device,conf_screen->scrn_device, TRUE)) {
|
||||
screenp->device->myScreenSection = screenp;
|
||||
else
|
||||
} else {
|
||||
screenp->device = NULL;
|
||||
}
|
||||
screenp->options = conf_screen->scrn_option_lst;
|
||||
|
||||
/*
|
||||
|
|
Loading…
Reference in New Issue
Block a user