removed direct references to prealloc_buf from das800 and das1800 drivers
authorFrank Mori Hess <fmhess@speakeasy.net>
Tue, 13 Feb 2001 17:06:45 +0000 (17:06 +0000)
committerFrank Mori Hess <fmhess@speakeasy.net>
Tue, 13 Feb 2001 17:06:45 +0000 (17:06 +0000)
comedi/drivers/das1800.c
comedi/drivers/das800.c

index a62574733b47cd0190547efcaf774ea69bb9be0a..f607193a54e95d51fbc2097016d0ed726aa8e2eb 100644 (file)
@@ -1085,12 +1085,12 @@ static void das1800_handle_fifo_not_empty(comedi_device *dev, comedi_subdevice *
 /* utility function used by das1800 interrupt service routines */
 inline void write_to_buffer(comedi_device *dev, comedi_subdevice *s, sampl_t data_point)
 {
-       if(s->async->buf_int_ptr >= s->async->prealloc_bufsz )
+       if(s->async->buf_int_ptr >= s->async->cmd.data_len )
        {
                s->async->buf_int_ptr = 0;
                comedi_eobuf(dev, s);
        }
-       *((sampl_t *)((void *)s->async->prealloc_buf + s->async->buf_int_ptr)) = data_point;
+       *((sampl_t *)((void *)s->async->cmd.data + s->async->buf_int_ptr)) = data_point;
        s->async->cur_chan++;
        if(s->async->cur_chan >= s->async->cur_chanlist_len)
        {
index b0e68ade1268e423b1c31ac093989ffb7f71a588..1a0be37e2bebf57de1f0d87c5df8bf375d37e82b 100644 (file)
@@ -391,12 +391,12 @@ static void das800_interrupt(int irq, void *d, struct pt_regs *regs)
                if(devpriv->count > 0 || devpriv->forever == 1)
                {
                        /* write data point to buffer */
-                       if(async->buf_int_ptr >= async->prealloc_bufsz )
+                       if(async->buf_int_ptr >= async->cmd.data_len )
                        {
                                async->buf_int_ptr = 0;
                                comedi_eobuf(dev, s);
                        }
-                       *((sampl_t *)((void *)async->prealloc_buf + async->buf_int_ptr)) = dataPoint;
+                       *((sampl_t *)((void *)async->cmd.data + async->buf_int_ptr)) = dataPoint;
                        async->cur_chan++;
                        if( async->cur_chan >= async->cur_chanlist_len )
                        {