* [PATCH] ir-kbd-i2c: Add debug to examine received data in get_key_haup_common()
@ 2011-01-14 21:50 Andy Walls
0 siblings, 0 replies; only message in thread
From: Andy Walls @ 2011-01-14 21:50 UTC (permalink / raw)
To: Jarod Wilson; +Cc: Janne Grunau, linux-media, Jean Delvare
Add a hex dump of the received bytes for tester reporting of actual data
received from the hardware.
Signed-off-by: Andy Walls <awalls@md.metrocast.net>
---
My heart won't be broken if this never makes it into the kernel.
Regards,
Andy
diff --git a/drivers/media/video/ir-kbd-i2c.c b/drivers/media/video/ir-kbd-i2c.c
index c87b6bc..b27fc43 100644
--- a/drivers/media/video/ir-kbd-i2c.c
+++ b/drivers/media/video/ir-kbd-i2c.c
@@ -76,6 +76,11 @@ static int get_key_haup_common(struct IR_i2c *ir, u32 *ir_key, u32 *ir_raw,
if (size != i2c_master_recv(ir->c, buf, size))
return -EIO;
+ if (debug >= 2)
+ print_hex_dump_bytes(MODULE_NAME
+ ": get_key_haup_common: received bytes: ",
+ DUMP_PREFIX_NONE, buf, size);
+
/* split rc5 data block ... */
start = (buf[offset] >> 7) & 1;
range = (buf[offset] >> 6) & 1;
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2011-01-14 21:51 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-01-14 21:50 [PATCH] ir-kbd-i2c: Add debug to examine received data in get_key_haup_common() Andy Walls
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).