- Remove a redundant check for dpms(4).
- Test a cheaper function first.
This commit is contained in:
parent
bf71c25f87
commit
2f28bf307c
@ -125,12 +125,8 @@ static void
|
||||
dpms_identify(driver_t *driver, device_t parent)
|
||||
{
|
||||
|
||||
/* The DPMS VBE only allows for manipulating a single monitor. */
|
||||
if (devclass_get_device(dpms_devclass, 0) != NULL)
|
||||
return;
|
||||
|
||||
if (x86bios_match_device(0xc0000, parent) &&
|
||||
device_get_flags(parent) != 0)
|
||||
if (device_get_flags(parent) != 0 &&
|
||||
x86bios_match_device(0xc0000, parent))
|
||||
device_add_child(parent, "dpms", 0);
|
||||
}
|
||||
|
||||
|
@ -250,8 +250,8 @@ vesa_bios_post(void)
|
||||
dc = devclass_find("vgapci");
|
||||
if (dc != NULL && devclass_get_devices(dc, &devs, &count) == 0) {
|
||||
for (dev = NULL, i = 0; dev == NULL && i < count; devs++, i++)
|
||||
if (x86bios_match_device(0xc0000, *devs) &&
|
||||
device_get_flags(*devs) != 0) {
|
||||
if (device_get_flags(*devs) != 0 &&
|
||||
x86bios_match_device(0xc0000, *devs)) {
|
||||
dev = *devs;
|
||||
is_pci = 1;
|
||||
break;
|
||||
|
Loading…
x
Reference in New Issue
Block a user