summaryrefslogtreecommitdiff
path: root/drivers/media/usb/gspca/xirlink_cit.c
diff options
context:
space:
mode:
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>2013-09-03 16:31:37 +0400
committerMauro Carvalho Chehab <m.chehab@samsung.com>2013-09-26 14:22:25 +0400
commitee35fa2267df3ebe36819dd5381e0067d574131f (patch)
tree59493ac68f96c865642ca8f60d118affb9fd5022 /drivers/media/usb/gspca/xirlink_cit.c
parent76e059874d3c362797990b4dcd58979b3f26f86f (diff)
downloadlinux-ee35fa2267df3ebe36819dd5381e0067d574131f.tar.xz
[media] gspca: print small buffers via %*ph
Instead of passing each byte through stack let's use %*ph specifier to do this job better. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> 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/xirlink_cit.c')
-rw-r--r--drivers/media/usb/gspca/xirlink_cit.c12
1 files changed, 4 insertions, 8 deletions
diff --git a/drivers/media/usb/gspca/xirlink_cit.c b/drivers/media/usb/gspca/xirlink_cit.c
index 101df674d3ba..a41aa7817c54 100644
--- a/drivers/media/usb/gspca/xirlink_cit.c
+++ b/drivers/media/usb/gspca/xirlink_cit.c
@@ -2864,20 +2864,16 @@ static u8 *cit_find_sof(struct gspca_dev *gspca_dev, u8 *data, int len)
if (data[i] == 0xff) {
if (i >= 4)
PDEBUG(D_FRAM,
- "header found at offset: %d: %02x %02x 00 %02x %02x %02x\n",
+ "header found at offset: %d: %02x %02x 00 %3ph\n",
i - 1,
data[i - 4],
data[i - 3],
- data[i],
- data[i + 1],
- data[i + 2]);
+ &data[i]);
else
PDEBUG(D_FRAM,
- "header found at offset: %d: 00 %02x %02x %02x\n",
+ "header found at offset: %d: 00 %3ph\n",
i - 1,
- data[i],
- data[i + 1],
- data[i + 2]);
+ &data[i]);
return data + i + (sd->sof_len - 1);
}
break;