struct comedi_subdevice *s,
unsigned int *chanlist, unsigned int n_chan);
-static int pcl818_ai_cancel(struct comedi_device *dev,
- struct comedi_subdevice *s);
-
static void pcl818_start_pacer(struct comedi_device *dev, bool load_counters)
{
struct pcl818_private *devpriv = dev->private;
}
outb(0, dev->iobase + PCL818_STATUS); /* clear INT request */
comedi_error(dev, "A/D mode1/3 IRQ without DRDY!");
- pcl818_ai_cancel(dev, s);
+ s->cancel(dev, s);
s->async->events |= COMEDI_CB_EOA | COMEDI_CB_ERROR;
comedi_event(dev, s);
return IRQ_HANDLED;
"A/D mode1/3 IRQ - channel dropout %x!=%x !\n",
chan,
devpriv->act_chanlist[devpriv->act_chanlist_pos]);
- pcl818_ai_cancel(dev, s);
+ s->cancel(dev, s);
s->async->events |= COMEDI_CB_EOA | COMEDI_CB_ERROR;
comedi_event(dev, s);
return IRQ_HANDLED;
if (!devpriv->neverending_ai) {
if (devpriv->ai_act_scan == 0) { /* all data sampled */
- pcl818_ai_cancel(dev, s);
+ s->cancel(dev, s);
s->async->events |= COMEDI_CB_EOA;
}
}
(ptr[bufptr] & 0xf),
devpriv->act_chanlist[devpriv->act_chanlist_pos],
devpriv->act_chanlist_pos);
- pcl818_ai_cancel(dev, s);
+ s->cancel(dev, s);
s->async->events |= COMEDI_CB_EOA | COMEDI_CB_ERROR;
comedi_event(dev, s);
return IRQ_HANDLED;
if (!devpriv->neverending_ai)
if (devpriv->ai_act_scan == 0) { /* all data sampled */
- pcl818_ai_cancel(dev, s);
+ s->cancel(dev, s);
s->async->events |= COMEDI_CB_EOA;
comedi_event(dev, s);
return IRQ_HANDLED;
if (lo & 4) {
comedi_error(dev, "A/D mode1/3 FIFO overflow!");
- pcl818_ai_cancel(dev, s);
+ s->cancel(dev, s);
s->async->events |= COMEDI_CB_EOA | COMEDI_CB_ERROR;
comedi_event(dev, s);
return IRQ_HANDLED;
if (lo & 1) {
comedi_error(dev, "A/D mode1/3 FIFO interrupt without data!");
- pcl818_ai_cancel(dev, s);
+ s->cancel(dev, s);
s->async->events |= COMEDI_CB_EOA | COMEDI_CB_ERROR;
comedi_event(dev, s);
return IRQ_HANDLED;
"A/D mode1/3 FIFO - channel dropout %d!=%d !\n",
(lo & 0xf),
devpriv->act_chanlist[devpriv->act_chanlist_pos]);
- pcl818_ai_cancel(dev, s);
+ s->cancel(dev, s);
s->async->events |= COMEDI_CB_EOA | COMEDI_CB_ERROR;
comedi_event(dev, s);
return IRQ_HANDLED;
if (!devpriv->neverending_ai)
if (devpriv->ai_act_scan == 0) { /* all data sampled */
- pcl818_ai_cancel(dev, s);
+ s->cancel(dev, s);
s->async->events |= COMEDI_CB_EOA;
comedi_event(dev, s);
return IRQ_HANDLED;
{
struct comedi_device *dev = d;
struct pcl818_private *devpriv = dev->private;
+ struct comedi_subdevice *s = dev->read_subdev;
if (!dev->attached) {
comedi_error(dev, "premature interrupt");
*/
devpriv->ai_act_scan = 0;
devpriv->neverending_ai = 0;
- pcl818_ai_cancel(dev, dev->read_subdev);
+ s->cancel(dev, s);
}
outb(0, dev->iobase + PCL818_CLRINT); /* clear INT request */