summaryrefslogtreecommitdiff
path: root/drivers/media/IR/ir-sony-decoder.c
diff options
context:
space:
mode:
authorMaxim Levitsky <maximlevitsky@gmail.com>2010-10-16 19:56:28 -0300
committerMauro Carvalho Chehab <mchehab@redhat.com>2010-10-21 10:59:47 -0200
commit4651918a4afdd49bdea21d2f919b189ef17a6399 (patch)
tree73a4e3b5f7da1d655a059bb9b69135cf6f395e02 /drivers/media/IR/ir-sony-decoder.c
parentfb249ca61d469a9cb666ba7e1d992787dc6bad82 (diff)
[media] IR: extend ir_raw_event and do refactoring
Add new event types for timeout & carrier report Move timeout handling from ir_raw_event_store_with_filter to ir-lirc-codec, where it is really needed. Now lirc bridge ensures proper gap handling. Extend lirc bridge for carrier & timeout reports Note: all new ir_raw_event variables now should be initialized like that: DEFINE_IR_RAW_EVENT(ev); To clean an existing event, use init_ir_raw_event(&ev); Signed-off-by: Maxim Levitsky <maximlevitsky@gmail.com> Acked-by: Jarod Wilson <jarod@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/IR/ir-sony-decoder.c')
-rw-r--r--drivers/media/IR/ir-sony-decoder.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/media/IR/ir-sony-decoder.c b/drivers/media/IR/ir-sony-decoder.c
index b9074f07c7a0..2d15730822bc 100644
--- a/drivers/media/IR/ir-sony-decoder.c
+++ b/drivers/media/IR/ir-sony-decoder.c
@@ -48,8 +48,9 @@ static int ir_sony_decode(struct input_dev *input_dev, struct ir_raw_event ev)
if (!(ir_dev->raw->enabled_protocols & IR_TYPE_SONY))
return 0;
- if (IS_RESET(ev)) {
- data->state = STATE_INACTIVE;
+ if (!is_timing_event(ev)) {
+ if (ev.reset)
+ data->state = STATE_INACTIVE;
return 0;
}