}
dev->board_ptr = das800_boards + board;
thisboard = comedi_board(dev);
+ dev->board_name = thisboard->name;
- /* grab our IRQ */
- if (irq == 1 || irq > 7) {
- dev_err(dev->class_dev, "irq out of range\n");
- return -EINVAL;
- }
- if (irq) {
- if (request_irq(irq, das800_interrupt, 0, "das800", dev)) {
- dev_err(dev->class_dev, "unable to allocate irq %u\n",
- irq);
- return -EINVAL;
- }
+ if (irq > 1 && irq <= 7) {
+ ret = request_irq(irq, das800_interrupt, 0, dev->board_name,
+ dev);
+ if (ret == 0)
+ dev->irq = irq;
}
- dev->irq = irq;
-
- dev->board_name = thisboard->name;
ret = comedi_alloc_subdevices(dev, 3);
if (ret)