staging: comedi: comedi_fc: cfc_write_array_to_buffer() data is const
authorIan Abbott <abbotti@mev.co.uk>
Mon, 15 Sep 2014 12:46:02 +0000 (13:46 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 19 Sep 2014 22:55:31 +0000 (15:55 -0700)
The `data` pointer of `cfc_write_array_to_buffer()` ought to point to
`const` data.

Signed-off-by: Ian Abbott <abbotti@mev.co.uk>
Reviewed-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/comedi/drivers/comedi_fc.c
drivers/staging/comedi/drivers/comedi_fc.h

index ed0e79f5bfaa3111efe8fc75a9530dec24cfe46b..6f872207ec3ac1276300758eee966ac59f45db9e 100644 (file)
@@ -24,7 +24,7 @@
 
 /* Writes an array of data points to comedi's buffer */
 unsigned int cfc_write_array_to_buffer(struct comedi_subdevice *s,
-                                      void *data, unsigned int num_bytes)
+                                      const void *data, unsigned int num_bytes)
 {
        struct comedi_async *async = s->async;
        unsigned int retval;
index c570c6eb6b9b8e325053d2dfac8d0d54ff95da89..fa3de9e873251781afb36b269dd4ccaf7f1898e8 100644 (file)
@@ -35,8 +35,9 @@ static inline void cfc_inc_scan_progress(struct comedi_subdevice *s,
 }
 
 /* Writes an array of data points to comedi's buffer */
-unsigned int cfc_write_array_to_buffer(struct comedi_subdevice *,
-                                      void *data, unsigned int num_bytes);
+unsigned int cfc_write_array_to_buffer(struct comedi_subdevice *s,
+                                      const void *data,
+                                      unsigned int num_bytes);
 
 static inline unsigned int cfc_write_to_buffer(struct comedi_subdevice *s,
                                               unsigned short data)