staging: comedi: drivers: use dev->board_name in request_irq()
Most of the comedi drivers use the dev->board_name for the id string passed to request_irq(). Fix the couple that still pass something else. Also, propogate the errno from request_irq(). Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
3d03cfcaf6
commit
71e068743a
|
@ -1471,11 +1471,12 @@ static int cb_pcidas_auto_attach(struct comedi_device *dev,
|
|||
outl(INTCSR_INBOX_INTR_STATUS,
|
||||
devpriv->s5933_config + AMCC_OP_REG_INTCSR);
|
||||
|
||||
if (request_irq(pcidev->irq, cb_pcidas_interrupt,
|
||||
IRQF_SHARED, dev->driver->driver_name, dev)) {
|
||||
ret = request_irq(pcidev->irq, cb_pcidas_interrupt, IRQF_SHARED,
|
||||
dev->board_name, dev);
|
||||
if (ret) {
|
||||
dev_dbg(dev->class_dev, "unable to allocate irq %d\n",
|
||||
pcidev->irq);
|
||||
return -EINVAL;
|
||||
return ret;
|
||||
}
|
||||
dev->irq = pcidev->irq;
|
||||
|
||||
|
|
|
@ -3989,12 +3989,13 @@ static int auto_attach(struct comedi_device *dev,
|
|||
devpriv->hw_revision);
|
||||
init_plx9080(dev);
|
||||
init_stc_registers(dev);
|
||||
/* get irq */
|
||||
if (request_irq(pcidev->irq, handle_interrupt, IRQF_SHARED,
|
||||
"cb_pcidas64", dev)) {
|
||||
|
||||
retval = request_irq(pcidev->irq, handle_interrupt, IRQF_SHARED,
|
||||
dev->board_name, dev);
|
||||
if (retval) {
|
||||
dev_dbg(dev->class_dev, "unable to allocate irq %u\n",
|
||||
pcidev->irq);
|
||||
return -EINVAL;
|
||||
return retval;
|
||||
}
|
||||
dev->irq = pcidev->irq;
|
||||
dev_dbg(dev->class_dev, "irq %u\n", dev->irq);
|
||||
|
|
|
@ -1165,8 +1165,8 @@ static int ni_660x_auto_attach(struct comedi_device *dev,
|
|||
for (i = 0; i < board->n_chips; ++i)
|
||||
set_tio_counterswap(dev, i);
|
||||
|
||||
ret = request_irq(pcidev->irq, ni_660x_interrupt,
|
||||
IRQF_SHARED, "ni_660x", dev);
|
||||
ret = request_irq(pcidev->irq, ni_660x_interrupt, IRQF_SHARED,
|
||||
dev->board_name, dev);
|
||||
if (ret < 0) {
|
||||
dev_warn(dev->class_dev, " irq not available\n");
|
||||
return ret;
|
||||
|
|
|
@ -345,8 +345,7 @@ static int ni_atmio_attach(struct comedi_device *dev,
|
|||
if (irq > 15 || ni_irqpin[irq] == -1)
|
||||
return -EINVAL;
|
||||
ret = request_irq(irq, ni_E_interrupt, 0,
|
||||
"ni_atmio", dev);
|
||||
|
||||
dev->board_name, dev);
|
||||
if (ret < 0)
|
||||
return -EINVAL;
|
||||
dev->irq = irq;
|
||||
|
|
Loading…
Reference in a new issue