diff options
author | Andy Shevchenko <andriy.shevchenko@linux.intel.com> | 2012-08-07 17:56:35 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2012-08-13 15:42:24 -0400 |
commit | 1d16e6d3965bff8d96995132a3b6beab7841e842 (patch) | |
tree | 00280f3630569e42bf35cd25390f41eb76b64095 | |
parent | 6f28f75a6df713559e675fbfd21ab1f7fbe8a20f (diff) |
[media] dvb-usb: use %*ph to dump small buffers
[crope@iki.fi: fix trivial merge conflict]
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Antti Palosaari <crope@iki.fi>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
-rw-r--r-- | drivers/media/dvb/dvb-usb-v2/af9015.c | 3 | ||||
-rw-r--r-- | drivers/media/dvb/dvb-usb-v2/af9035.c | 3 | ||||
-rw-r--r-- | drivers/media/dvb/dvb-usb/pctv452e.c | 7 |
3 files changed, 5 insertions, 8 deletions
diff --git a/drivers/media/dvb/dvb-usb-v2/af9015.c b/drivers/media/dvb/dvb-usb-v2/af9015.c index 10363f6b5234..e77429b37a7d 100644 --- a/drivers/media/dvb/dvb-usb-v2/af9015.c +++ b/drivers/media/dvb/dvb-usb-v2/af9015.c | |||
@@ -1199,8 +1199,7 @@ static int af9015_rc_query(struct dvb_usb_device *d) | |||
1199 | 1199 | ||
1200 | /* Only process key if canary killed */ | 1200 | /* Only process key if canary killed */ |
1201 | if (buf[16] != 0xff && buf[0] != 0x01) { | 1201 | if (buf[16] != 0xff && buf[0] != 0x01) { |
1202 | deb_rc("%s: key pressed %02x %02x %02x %02x\n", __func__, | 1202 | deb_rc("%s: key pressed %*ph\n", __func__, 4, buf + 12); |
1203 | buf[12], buf[13], buf[14], buf[15]); | ||
1204 | 1203 | ||
1205 | /* Reset the canary */ | 1204 | /* Reset the canary */ |
1206 | ret = af9015_write_reg(d, 0x98e9, 0xff); | 1205 | ret = af9015_write_reg(d, 0x98e9, 0xff); |
diff --git a/drivers/media/dvb/dvb-usb-v2/af9035.c b/drivers/media/dvb/dvb-usb-v2/af9035.c index 79197f46aa95..bb90b877d07b 100644 --- a/drivers/media/dvb/dvb-usb-v2/af9035.c +++ b/drivers/media/dvb/dvb-usb-v2/af9035.c | |||
@@ -290,8 +290,7 @@ static int af9035_identify_state(struct dvb_usb_device *d, const char **name) | |||
290 | if (ret < 0) | 290 | if (ret < 0) |
291 | goto err; | 291 | goto err; |
292 | 292 | ||
293 | pr_debug("%s: reply=%02x %02x %02x %02x\n", __func__, | 293 | pr_debug("%s: reply=%*ph\n", __func__, 4, rbuf); |
294 | rbuf[0], rbuf[1], rbuf[2], rbuf[3]); | ||
295 | if (rbuf[0] || rbuf[1] || rbuf[2] || rbuf[3]) | 294 | if (rbuf[0] || rbuf[1] || rbuf[2] || rbuf[3]) |
296 | ret = WARM; | 295 | ret = WARM; |
297 | else | 296 | else |
diff --git a/drivers/media/dvb/dvb-usb/pctv452e.c b/drivers/media/dvb/dvb-usb/pctv452e.c index f526eb05cc7a..02e878577c3d 100644 --- a/drivers/media/dvb/dvb-usb/pctv452e.c +++ b/drivers/media/dvb/dvb-usb/pctv452e.c | |||
@@ -136,8 +136,8 @@ static int tt3650_ci_msg(struct dvb_usb_device *d, u8 cmd, u8 *data, | |||
136 | return 0; | 136 | return 0; |
137 | 137 | ||
138 | failed: | 138 | failed: |
139 | err("CI error %d; %02X %02X %02X -> %02X %02X %02X.", | 139 | err("CI error %d; %02X %02X %02X -> %*ph.", |
140 | ret, SYNC_BYTE_OUT, id, cmd, buf[0], buf[1], buf[2]); | 140 | ret, SYNC_BYTE_OUT, id, cmd, 3, buf); |
141 | 141 | ||
142 | return ret; | 142 | return ret; |
143 | } | 143 | } |
@@ -556,8 +556,7 @@ static int pctv452e_rc_query(struct dvb_usb_device *d) | |||
556 | return ret; | 556 | return ret; |
557 | 557 | ||
558 | if (debug > 3) { | 558 | if (debug > 3) { |
559 | info("%s: read: %2d: %02x %02x %02x: ", __func__, | 559 | info("%s: read: %2d: %*ph: ", __func__, ret, 3, rx); |
560 | ret, rx[0], rx[1], rx[2]); | ||
561 | for (i = 0; (i < rx[3]) && ((i+3) < PCTV_ANSWER_LEN); i++) | 560 | for (i = 0; (i < rx[3]) && ((i+3) < PCTV_ANSWER_LEN); i++) |
562 | info(" %02x", rx[i+3]); | 561 | info(" %02x", rx[i+3]); |
563 | 562 | ||