diff options
author | Peter Naulls <peter@chocky.org> | 2006-08-08 08:10:05 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@infradead.org> | 2006-09-26 10:53:17 -0400 |
commit | d1009bd733a9324baff74611e0635e17fce4dfa2 (patch) | |
tree | 1a24068f7ad17615b950717514d7996a1f136d5f /drivers/media/video/cx88/cx88-input.c | |
parent | 5dbaa2cb757545f8238319d55aa75cc8fabc8212 (diff) |
V4L/DVB (4361): Cx88: add support for Norwood PCI TV Tuner (non-pro)
This patch adds support for Norwood PCI TV Tuner (non-pro)
Signed-off-by: Peter Naulls <peter@chocky.org>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/video/cx88/cx88-input.c')
-rw-r--r-- | drivers/media/video/cx88/cx88-input.c | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/drivers/media/video/cx88/cx88-input.c b/drivers/media/video/cx88/cx88-input.c index c25564648993..3049bd5b5a48 100644 --- a/drivers/media/video/cx88/cx88-input.c +++ b/drivers/media/video/cx88/cx88-input.c | |||
@@ -107,7 +107,15 @@ static void cx88_ir_handle_key(struct cx88_IR *ir) | |||
107 | (gpio & ir->mask_keydown) ? " down" : "", | 107 | (gpio & ir->mask_keydown) ? " down" : "", |
108 | (gpio & ir->mask_keyup) ? " up" : ""); | 108 | (gpio & ir->mask_keyup) ? " up" : ""); |
109 | 109 | ||
110 | if (ir->mask_keydown) { | 110 | if (ir->core->board == CX88_BOARD_NORWOOD_MICRO) { |
111 | u32 gpio_key = cx_read(MO_GP0_IO); | ||
112 | |||
113 | data = (data << 4) | ((gpio_key & 0xf0) >> 4); | ||
114 | |||
115 | ir_input_keydown(ir->input, &ir->ir, data, data); | ||
116 | ir_input_nokey(ir->input, &ir->ir); | ||
117 | |||
118 | } else if (ir->mask_keydown) { | ||
111 | /* bit set on keydown */ | 119 | /* bit set on keydown */ |
112 | if (gpio & ir->mask_keydown) { | 120 | if (gpio & ir->mask_keydown) { |
113 | ir_input_keydown(ir->input, &ir->ir, data, data); | 121 | ir_input_keydown(ir->input, &ir->ir, data, data); |
@@ -248,6 +256,13 @@ int cx88_ir_init(struct cx88_core *core, struct pci_dev *pci) | |||
248 | ir_type = IR_TYPE_PD; | 256 | ir_type = IR_TYPE_PD; |
249 | ir->sampling = 0xff00; /* address */ | 257 | ir->sampling = 0xff00; /* address */ |
250 | break; | 258 | break; |
259 | case CX88_BOARD_NORWOOD_MICRO: | ||
260 | ir_codes = ir_codes_norwood; | ||
261 | ir->gpio_addr = MO_GP1_IO; | ||
262 | ir->mask_keycode = 0x0e; | ||
263 | ir->mask_keyup = 0x80; | ||
264 | ir->polling = 50; /* ms */ | ||
265 | break; | ||
251 | case CX88_BOARD_NPGTECH_REALTV_TOP10FM: | 266 | case CX88_BOARD_NPGTECH_REALTV_TOP10FM: |
252 | ir_codes = ir_codes_npgtech; | 267 | ir_codes = ir_codes_npgtech; |
253 | ir->gpio_addr = MO_GP0_IO; | 268 | ir->gpio_addr = MO_GP0_IO; |