Re: [-mm patch] aic7xxx: check irq validity (was Re: 2.6.18-mm2)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Matthew Wilcox wrote:
Others tend to use the driver name.  Changing them all to be 0000:00:1d.2
isn't really an improvement in the readability of /proc/interrupts, IMO.

agreed


Passing pdev as the data is a good idea for practically no device driver.

agreed


It's rare to actually want the pci_device down in the interrupt handler;
normally you want the device private data.  Using pci_get_drvdata(pdev)
as the data would make sense for both sym2 and tg3.  I don't feel like

Using pci_get_drvdata() is a pretty good idea


int pci_request_irq(struct pci_dev *pdev, irq_handler_t handler,
			const char *name)
{
	if (!valid_irq(pdev->irq)) {
		dev_printk(KERN_ERR, &pdev->dev, "invalid irq\n");
		return -EINVAL;
	}

	return request_irq(pdev->irq, handler, IRQF_SHARED, name,
				pci_get_drvdata(pdev));
}

But what about IRQF_SAMPLE_RANDOM?

I still like having a flags argument though. It's enough of an open question, and I bet there will be a new flag or two in the future that PCI drivers will want to use.

	Jeff


-
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]
  Powered by Linux