[media] au0828: Improve debug messages for urb_completion
authorMauro Carvalho Chehab <m.chehab@samsung.com>
Wed, 21 May 2014 12:35:06 +0000 (09:35 -0300)
committerMauro Carvalho Chehab <m.chehab@samsung.com>
Sun, 25 May 2014 20:46:36 +0000 (17:46 -0300)
Sometimes, it helps to know how much data was received by
urb_completion. Add that information to the optional debug
log.

Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
drivers/media/usb/au0828/au0828-dvb.c

index 2019e4a168b24ade6021c4941cee60103e8ed3bd..ab5f93643021c27fd6a57475ca3fe97e664b3cd3 100755 (executable)
@@ -114,16 +114,20 @@ static void urb_completion(struct urb *purb)
        int ptype = usb_pipetype(purb->pipe);
        unsigned char *ptr;
 
-       dprintk(2, "%s()\n", __func__);
+       dprintk(2, "%s: %d\n", __func__, purb->actual_length);
 
-       if (!dev)
+       if (!dev) {
+               dprintk(2, "%s: no dev!\n", __func__);
                return;
+       }
 
-       if (dev->urb_streaming == 0)
+       if (dev->urb_streaming == 0) {
+               dprintk(2, "%s: not streaming!\n", __func__);
                return;
+       }
 
        if (ptype != PIPE_BULK) {
-               printk(KERN_ERR "%s() Unsupported URB type %d\n",
+               printk(KERN_ERR "%s: Unsupported URB type %d\n",
                       __func__, ptype);
                return;
        }
This page took 0.04434 seconds and 5 git commands to generate.