staging: comedi: s526: don't dereference insn->data pointer
authorH Hartley Sweeten <hartleys@visionengravers.com>
Wed, 19 Sep 2012 22:08:35 +0000 (15:08 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 21 Sep 2012 16:19:41 +0000 (09:19 -0700)
commitb2abd982c484ba0e46ea681b0bc6d7baf7c47730
treeef38880b18c1def25de72d2b4898201988231713
parenteffef787a9e7c95b58a70951ec934a4474fa73bf
staging: comedi: s526: don't dereference insn->data pointer

The comedi_insn 'data' pointer is a __user pointer that is
passed into the kernel using an ioctl. The comedi core copies
this data to kernel space in do_insnlist_ioctl() and then
passes that kernel data to the drivers as a separate parameter.
The drivers never need to access the data through the insn->data
pointer.

This fixes a number of sparse warnings about:

  warning: dereference of noderef expression

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