aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/staging
diff options
context:
space:
mode:
authorDavid Härdeman <david@hardeman.nu>2010-10-29 16:08:07 -0300
committerMauro Carvalho Chehab <mchehab@redhat.com>2010-12-29 08:16:35 -0200
commit62c6503125389763a74911408d984c5dd09eeb97 (patch)
treea9b419280d25fca5086d82f8992a1d5843da75f1 /drivers/staging
parent2997137be8eba5bf9c07a24d5fda1f4225f9ca7d (diff)
downloadkernel_samsung_tuna-62c6503125389763a74911408d984c5dd09eeb97.zip
kernel_samsung_tuna-62c6503125389763a74911408d984c5dd09eeb97.tar.gz
kernel_samsung_tuna-62c6503125389763a74911408d984c5dd09eeb97.tar.bz2
[media] ir-core: remove remaining users of the ir-functions keyhandlers
This patch removes the remaining usages of the ir_input_nokey() and ir_input_keydown() functions provided by drivers/media/IR/ir-functions.c by using the corresponding functionality in ir-core instead. Signed-off-by: David Härdeman <david@hardeman.nu> Acked-by: Jarod Wilson <jarod@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/staging')
-rw-r--r--drivers/staging/tm6000/tm6000-input.c15
1 files changed, 4 insertions, 11 deletions
diff --git a/drivers/staging/tm6000/tm6000-input.c b/drivers/staging/tm6000/tm6000-input.c
index 6022caa..3e74884 100644
--- a/drivers/staging/tm6000/tm6000-input.c
+++ b/drivers/staging/tm6000/tm6000-input.c
@@ -25,7 +25,6 @@
#include <linux/usb.h>
#include <media/ir-core.h>
-#include <media/ir-common.h>
#include "tm6000.h"
#include "tm6000-regs.h"
@@ -52,7 +51,6 @@ struct tm6000_ir_poll_result {
struct tm6000_IR {
struct tm6000_core *dev;
struct ir_input_dev *input;
- struct ir_input_state ir;
char name[32];
char phys[32];
@@ -67,6 +65,7 @@ struct tm6000_IR {
int (*get_key) (struct tm6000_IR *, struct tm6000_ir_poll_result *);
/* IR device properties */
+ u64 ir_type;
struct ir_dev_props props;
};
@@ -145,7 +144,7 @@ static int default_polling_getkey(struct tm6000_IR *ir,
return 0;
if (&dev->int_in) {
- if (ir->ir.ir_type == IR_TYPE_RC5)
+ if (ir->ir_type == IR_TYPE_RC5)
poll_result->rc_data = ir->urb_data[0];
else
poll_result->rc_data = ir->urb_data[0] | ir->urb_data[1] << 8;
@@ -155,7 +154,7 @@ static int default_polling_getkey(struct tm6000_IR *ir,
tm6000_set_reg(dev, REQ_04_EN_DISABLE_MCU_INT, 2, 1);
msleep(10);
- if (ir->ir.ir_type == IR_TYPE_RC5) {
+ if (ir->ir_type == IR_TYPE_RC5) {
rc = tm6000_read_write_usb(dev, USB_DIR_IN |
USB_TYPE_VENDOR | USB_RECIP_DEVICE,
REQ_02_GET_IR_CODE, 0, 0, buf, 1);
@@ -201,10 +200,7 @@ static void tm6000_ir_handle_key(struct tm6000_IR *ir)
dprintk("ir->get_key result data=%04x\n", poll_result.rc_data);
if (ir->key) {
- ir_input_keydown(ir->input->input_dev, &ir->ir,
- (u32)poll_result.rc_data);
-
- ir_input_nokey(ir->input->input_dev, &ir->ir);
+ ir_keydown(ir->input->input_dev, poll_result.rc_data, 0);
ir->key = 0;
}
return;
@@ -291,9 +287,6 @@ int tm6000_ir_init(struct tm6000_core *dev)
strlcat(ir->phys, "/input0", sizeof(ir->phys));
tm6000_ir_change_protocol(ir, IR_TYPE_UNKNOWN);
- err = ir_input_init(ir_input_dev->input_dev, &ir->ir, IR_TYPE_OTHER);
- if (err < 0)
- goto err_out_free;
ir_input_dev->input_dev->name = ir->name;
ir_input_dev->input_dev->phys = ir->phys;