Oops, fix intsmb(4) attach. Don't overwrite the 'value' holding the

interrupt mode with the SMB revision before checking 'value' for a valid
interrupt mode.

Reported by:	Ulrich Spoerlein <uspoerlein of gmail fame>
This commit is contained in:
John Baldwin 2007-04-19 17:14:06 +00:00
parent f3064b397a
commit 0d4e0cc591

View File

@ -139,8 +139,7 @@ intsmb_attach(device_t dev)
}
device_printf(dev, "intr %s %s ", str,
(value & 1) ? "enabled" : "disabled");
value = pci_read_config(dev, PCI_REVID_SMB, 1);
printf("revision %d\n", value);
printf("revision %d\n", pci_read_config(dev, PCI_REVID_SMB, 1));
if ((value & 0xe) != PCI_INTR_SMB_IRQ9) {
device_printf(dev, "Unsupported interrupt mode\n");