Commit 31e7f148 authored by Dave Jones's avatar Dave Jones Committed by Linus Torvalds

[PATCH] pci_enable_device before accessing ->irq for wdt_pci

parent bceb88dd
......@@ -523,14 +523,14 @@ static int __init wdtpci_init_one (struct pci_dev *dev,
return -ENODEV;
}
if (pci_enable_device (dev))
goto out;
irq = dev->irq;
io = pci_resource_start (dev, 2);
printk ("WDT501-P(PCI-WDG-CSM) driver 0.07 at %X "
"(Interrupt %d)\n", io, irq);
if (pci_enable_device (dev))
goto out;
if (request_region (io, 16, "wdt-pci") == NULL) {
printk (KERN_ERR PFX "I/O %d is not free.\n", io);
goto out;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment