]> git.karo-electronics.de Git - karo-tx-linux.git/commit
staging: comedi: dt9812: tidy up usb_bulk_msg() calls
authorH Hartley Sweeten <hsweeten@visionengravers.com>
Tue, 14 May 2013 21:22:39 +0000 (14:22 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 16 May 2013 23:25:54 +0000 (16:25 -0700)
commit0ec77d3499b10c75b279080a79a79e35e51b70a6
tree84e81b8983fac2bd5217eb876cc0126134008e94
parent1415003fe6015575ed00f85bacd948b93d7ca78c
staging: comedi: dt9812: tidy up usb_bulk_msg() calls

To clarify the code, add a local variable for the struct usb_device
pointer used in the usb_blk_msg() calls.

It's not necessary to initialize the 'count' when writing to the
usb device. The 'count' variable is used to get back the number
of bytes actually sent.

Just return the usb_blk_msg() result when it is the last operation
in a function.

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/dt9812.c