Commit 457e2ffc authored by Jarod Wilson's avatar Jarod Wilson Committed by Mauro Carvalho Chehab

[media] rc/ir-lirc-codec: add back debug spew

Some occasionally useful debug spew disappeared as part of a feature
update a while back, and I'm finding myself in need of it again to help
diagnose some issues.
Signed-off-by: default avatarJarod Wilson <jarod@redhat.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent 8df59918
/* ir-lirc-codec.c - ir-core to classic lirc interface bridge /* ir-lirc-codec.c - rc-core to classic lirc interface bridge
* *
* Copyright (C) 2010 by Jarod Wilson <jarod@redhat.com> * Copyright (C) 2010 by Jarod Wilson <jarod@redhat.com>
* *
...@@ -47,6 +47,7 @@ static int ir_lirc_decode(struct rc_dev *dev, struct ir_raw_event ev) ...@@ -47,6 +47,7 @@ static int ir_lirc_decode(struct rc_dev *dev, struct ir_raw_event ev)
/* Carrier reports */ /* Carrier reports */
if (ev.carrier_report) { if (ev.carrier_report) {
sample = LIRC_FREQUENCY(ev.carrier); sample = LIRC_FREQUENCY(ev.carrier);
IR_dprintk(2, "carrier report (freq: %d)\n", sample);
/* Packet end */ /* Packet end */
} else if (ev.timeout) { } else if (ev.timeout) {
...@@ -62,6 +63,7 @@ static int ir_lirc_decode(struct rc_dev *dev, struct ir_raw_event ev) ...@@ -62,6 +63,7 @@ static int ir_lirc_decode(struct rc_dev *dev, struct ir_raw_event ev)
return 0; return 0;
sample = LIRC_TIMEOUT(ev.duration / 1000); sample = LIRC_TIMEOUT(ev.duration / 1000);
IR_dprintk(2, "timeout report (duration: %d)\n", sample);
/* Normal sample */ /* Normal sample */
} else { } else {
...@@ -85,6 +87,8 @@ static int ir_lirc_decode(struct rc_dev *dev, struct ir_raw_event ev) ...@@ -85,6 +87,8 @@ static int ir_lirc_decode(struct rc_dev *dev, struct ir_raw_event ev)
sample = ev.pulse ? LIRC_PULSE(ev.duration / 1000) : sample = ev.pulse ? LIRC_PULSE(ev.duration / 1000) :
LIRC_SPACE(ev.duration / 1000); LIRC_SPACE(ev.duration / 1000);
IR_dprintk(2, "delivering %uus %s to lirc_dev\n",
TO_US(ev.duration), TO_STR(ev.pulse));
} }
lirc_buffer_write(dev->raw->lirc.drv->rbuf, lirc_buffer_write(dev->raw->lirc.drv->rbuf,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment