summaryrefslogtreecommitdiff
path: root/drivers/media/usb/gspca/kinect.c
diff options
context:
space:
mode:
authorAntonio Ospite <ospite@studenti.unina.it>2013-12-30 20:41:46 +0400
committerMauro Carvalho Chehab <m.chehab@samsung.com>2014-02-28 21:37:26 +0400
commitccf78070d7ec8ff0231c5c2b1b16c78e10c768fc (patch)
tree0491dd44e1428ef01e2c8cc969eeb95832c709bd /drivers/media/usb/gspca/kinect.c
parent840d94eacea399b3bfe2ebcbf75e0dec202cd922 (diff)
downloadlinux-ccf78070d7ec8ff0231c5c2b1b16c78e10c768fc.tar.xz
[media] gspca_kinect: fix messages about kinect_read() return value
Messages relative to kinect_read() are printing "res" which contains the return value of a previous kinect_write(). Print the correct value in the messages. Cc: Julia Lawall <julia.lawall@lip6.fr> Signed-off-by: Antonio Ospite <ospite@studenti.unina.it> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
Diffstat (limited to 'drivers/media/usb/gspca/kinect.c')
-rw-r--r--drivers/media/usb/gspca/kinect.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/media/usb/gspca/kinect.c b/drivers/media/usb/gspca/kinect.c
index 48084736f882..081f05162809 100644
--- a/drivers/media/usb/gspca/kinect.c
+++ b/drivers/media/usb/gspca/kinect.c
@@ -155,9 +155,10 @@ static int send_cmd(struct gspca_dev *gspca_dev, uint16_t cmd, void *cmdbuf,
do {
actual_len = kinect_read(udev, ibuf, 0x200);
} while (actual_len == 0);
- PDEBUG(D_USBO, "Control reply: %d", res);
+ PDEBUG(D_USBO, "Control reply: %d", actual_len);
if (actual_len < sizeof(*rhdr)) {
- pr_err("send_cmd: Input control transfer failed (%d)\n", res);
+ pr_err("send_cmd: Input control transfer failed (%d)\n",
+ actual_len);
return actual_len < 0 ? actual_len : -EREMOTEIO;
}
actual_len -= sizeof(*rhdr);