aboutsummaryrefslogtreecommitdiffstats
path: root/include/media
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@redhat.com>2010-03-25 20:13:43 -0400
committerMauro Carvalho Chehab <mchehab@redhat.com>2010-05-17 23:53:00 -0400
commit93c312ff21b0a53e701a45741887208297646a1a (patch)
treecc17d43e5b1926228daacb4ea61d7be43f1c0c24 /include/media
parent995187bed30c0545e8da88372e9807da0a85911e (diff)
V4L/DVB: ir-core: prepare to add more operations for ir decoders
Some decoders and a lirc_dev interface may need some other operations to work. For example: IR device register/unregister and ir_keydown events may need to be tracked. As some operations can occur in interrupt time, and a lock is needed to prevent un-registering a decode while decoding a key, the lock needed to be convert into a spin lock. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'include/media')
-rw-r--r--include/media/ir-core.h7
1 files changed, 2 insertions, 5 deletions
diff --git a/include/media/ir-core.h b/include/media/ir-core.h
index c377bf47a059..c704fa7cc11e 100644
--- a/include/media/ir-core.h
+++ b/include/media/ir-core.h
@@ -88,6 +88,8 @@ struct ir_raw_handler {
88 int (*decode)(struct input_dev *input_dev, 88 int (*decode)(struct input_dev *input_dev,
89 struct ir_raw_event *evs, 89 struct ir_raw_event *evs,
90 int len); 90 int len);
91 int (*raw_register)(struct input_dev *input_dev);
92 int (*raw_unregister)(struct input_dev *input_dev);
91}; 93};
92 94
93#define to_ir_input_dev(_attr) container_of(_attr, struct ir_input_dev, attr) 95#define to_ir_input_dev(_attr) container_of(_attr, struct ir_input_dev, attr)
@@ -116,12 +118,7 @@ int ir_raw_event_store(struct input_dev *input_dev, enum raw_event_type type);
116int ir_raw_event_handle(struct input_dev *input_dev); 118int ir_raw_event_handle(struct input_dev *input_dev);
117int ir_raw_handler_register(struct ir_raw_handler *ir_raw_handler); 119int ir_raw_handler_register(struct ir_raw_handler *ir_raw_handler);
118void ir_raw_handler_unregister(struct ir_raw_handler *ir_raw_handler); 120void ir_raw_handler_unregister(struct ir_raw_handler *ir_raw_handler);
119
120#ifdef MODULE
121void ir_raw_init(void); 121void ir_raw_init(void);
122#else
123#define ir_raw_init() 0
124#endif
125 122
126/* from ir-nec-decoder.c */ 123/* from ir-nec-decoder.c */
127#ifdef CONFIG_IR_NEC_DECODER_MODULE 124#ifdef CONFIG_IR_NEC_DECODER_MODULE