fix init of len_chanlist for analog output subdevice, removed
authorFrank Mori Hess <fmhess@speakeasy.net>
Thu, 22 Apr 2004 22:39:24 +0000 (22:39 +0000)
committerFrank Mori Hess <fmhess@speakeasy.net>
Thu, 22 Apr 2004 22:39:24 +0000 (22:39 +0000)
redundant check in ao command test

comedi/drivers/ni_mio_common.c

index a76be0f69ee47b6fe4b9118613d89869c6b689e6..a440a77eeabfe4c850e767c27207d29a837eab59 100644 (file)
@@ -2305,11 +2305,6 @@ static int ni_ao_cmdtest(comedi_device *dev,comedi_subdevice *s,comedi_cmd *cmd)
 
        /* step 5: fix up chanlist */
 
-       if(cmd->chanlist_len != cmd->scan_end_arg){
-               cmd->chanlist_len = cmd->scan_end_arg;
-               err++;
-       }
-
        if(err)return 5;
 
        return 0;
@@ -2679,7 +2674,7 @@ static int ni_E_init(comedi_device *dev,comedi_devconfig *it)
                if(boardtype.ao_fifo_depth){
                        s->do_cmd=ni_ao_cmd;
                        s->do_cmdtest=ni_ao_cmdtest;
-                       s->len_chanlist = 2;
+                       s->len_chanlist = boardtype.n_aochan;
                        s->munge=ni_ao_munge;
                }
                s->cancel=ni_ao_reset;