[PATCH] starfire reads irq before pci_enable_device.

ę[@─ě ┐8■ ┐Vedran Rodic (davej@suse.de)
Wed, 7 Feb 2001 18:42:07 +0000 (GMT)


Hi Alan, Donald,

This driver should call pci_enable_device before reading
pdev->irq.

regards,

Dave.

-- 
| Dave Jones.        http://www.suse.de/~davej
| SuSE Labs

diff -urN --exclude-from=/home/davej/.exclude linux/drivers/net/starfire.c linux-dj/drivers/net/starfire.c --- linux/drivers/net/starfire.c Wed Feb 7 12:42:42 2001 +++ linux-dj/drivers/net/starfire.c Wed Feb 7 18:34:22 2001 @@ -409,6 +409,9 @@ } SET_MODULE_OWNER(dev);

+ if (pci_enable_device (pdev)) + goto err_out_free_netdev; + irq = pdev->irq;

if (request_mem_region (ioaddr, io_size, dev->name) == NULL) { @@ -416,10 +419,7 @@ card_idx, io_size, ioaddr); goto err_out_free_netdev; } - - if (pci_enable_device (pdev)) - goto err_out_free_res; - + ioaddr = (long) ioremap (ioaddr, io_size); if (!ioaddr) { printk (KERN_ERR "starfire %d: cannot remap 0x%x @ 0x%lx, aborting\n",

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org Please read the FAQ at http://www.tux.org/lkml/