From: H Hartley Sweeten Date: Tue, 14 May 2013 20:41:51 +0000 (-0700) Subject: staging: comedi: usbduxfast: tidy up usbduxfast_ai_insn_read() X-Git-Tag: omap-for-v3.11/fixes-for-merge-window~76^2~636 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=dabf2aa3546aa662cd2624d6308e07454689e91d;p=pandora-kernel.git staging: comedi: usbduxfast: tidy up usbduxfast_ai_insn_read() Remove the sanity check of devpriv, this function can only be called by the comedi core if the private data is allocated. Get the 'chan', 'range' and 'rngmask' from the function parameters when the local variables are declared. For aesthetic reasons, rename the local variable 'err' to 'ret' since that name is more standard. (*insn_read) functions are supposed to return the number of values read or an error code. Change the final return to 'insn->n' to make it clearer. Signed-off-by: H Hartley Sweeten Cc: Ian Abbott Signed-off-by: Greg Kroah-Hartman --- Reading git-diff-tree failed