summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAntonio Cardace2018-02-09 15:13:26 +0100
committerMauro Carvalho Chehab2018-02-26 14:13:37 +0100
commit290ef7d846b35205975786296388c082e50d4319 (patch)
tree946bb2278561ee69e83e9b4ff60372b20a2ef712
parentmedia: cec: improve debugging (diff)
downloadkernel-qcow2-linux-290ef7d846b35205975786296388c082e50d4319.tar.gz
kernel-qcow2-linux-290ef7d846b35205975786296388c082e50d4319.tar.xz
kernel-qcow2-linux-290ef7d846b35205975786296388c082e50d4319.zip
media: em28xx: use %*phC to print small buffers
Use %*phC format to print small buffers as hex strings Suggested-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Antonio Cardace <anto.cardace@gmail.com> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
-rw-r--r--drivers/media/usb/em28xx/em28xx-i2c.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/media/usb/em28xx/em28xx-i2c.c b/drivers/media/usb/em28xx/em28xx-i2c.c
index 9bf49d666e5a..9ad958004990 100644
--- a/drivers/media/usb/em28xx/em28xx-i2c.c
+++ b/drivers/media/usb/em28xx/em28xx-i2c.c
@@ -710,8 +710,8 @@ static int em28xx_i2c_eeprom(struct em28xx *dev, unsigned bus,
mc_start = (data[1] << 8) + 4; /* usually 0x0004 */
dev_info(&dev->intf->dev,
- "EEPROM ID = %02x %02x %02x %02x, EEPROM hash = 0x%08lx\n",
- data[0], data[1], data[2], data[3], dev->hash);
+ "EEPROM ID = %4ph, EEPROM hash = 0x%08lx\n",
+ data, dev->hash);
dev_info(&dev->intf->dev,
"EEPROM info:\n");
dev_info(&dev->intf->dev,
@@ -776,8 +776,8 @@ static int em28xx_i2c_eeprom(struct em28xx *dev, unsigned bus,
data[2] == 0x67 && data[3] == 0x95) {
dev->hash = em28xx_hash_mem(data, len, 32);
dev_info(&dev->intf->dev,
- "EEPROM ID = %02x %02x %02x %02x, EEPROM hash = 0x%08lx\n",
- data[0], data[1], data[2], data[3], dev->hash);
+ "EEPROM ID = %4ph, EEPROM hash = 0x%08lx\n",
+ data, dev->hash);
dev_info(&dev->intf->dev,
"EEPROM info:\n");
} else {