diff options
author | Mike Isely <isely@pobox.com> | 2007-11-26 00:09:42 -0500 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@infradead.org> | 2008-01-25 16:03:05 -0500 |
commit | 056d1a899201f02777a35a32f8e6c9a2aac63f63 (patch) | |
tree | e99e723532821d13d4f65d90e18bbe25878ef3db /drivers/media | |
parent | f5174af201f2e22c101bb02d06343e4bc5f056de (diff) |
V4L/DVB (6699): pvrusb2: Use of virtual IR chip is a device-specific attribute
For Hauppauge 24xxx devices, the IR receiver is a custom piece of
logic that is very specific to the device. The pvrusb2 driver can
virtualize this to make it look like a more normal IR receiver found
in other Hauppauge devices. The decision of whether or not to enable
this virtualization however is a device-specific attribute, thus this
changeset.
Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media')
-rw-r--r-- | drivers/media/video/pvrusb2/pvrusb2-devattr.c | 1 | ||||
-rw-r--r-- | drivers/media/video/pvrusb2/pvrusb2-devattr.h | 4 | ||||
-rw-r--r-- | drivers/media/video/pvrusb2/pvrusb2-i2c-core.c | 2 |
3 files changed, 6 insertions, 1 deletions
diff --git a/drivers/media/video/pvrusb2/pvrusb2-devattr.c b/drivers/media/video/pvrusb2/pvrusb2-devattr.c index 464a13a06494..6ba0b79e3a1e 100644 --- a/drivers/media/video/pvrusb2/pvrusb2-devattr.c +++ b/drivers/media/video/pvrusb2/pvrusb2-devattr.c | |||
@@ -85,6 +85,7 @@ const struct pvr2_device_desc pvr2_device_descriptions[] = { | |||
85 | .flag_has_cx25840 = !0, | 85 | .flag_has_cx25840 = !0, |
86 | .flag_has_wm8775 = !0, | 86 | .flag_has_wm8775 = !0, |
87 | .flag_has_hauppauge_rom = !0, | 87 | .flag_has_hauppauge_rom = !0, |
88 | .flag_has_hauppauge_custom_ir = !0, | ||
88 | .signal_routing_scheme = PVR2_ROUTING_SCHEME_HAUPPAUGE, | 89 | .signal_routing_scheme = PVR2_ROUTING_SCHEME_HAUPPAUGE, |
89 | }, | 90 | }, |
90 | }; | 91 | }; |
diff --git a/drivers/media/video/pvrusb2/pvrusb2-devattr.h b/drivers/media/video/pvrusb2/pvrusb2-devattr.h index 05eb2c669ee8..2aff5a3d5a55 100644 --- a/drivers/media/video/pvrusb2/pvrusb2-devattr.h +++ b/drivers/media/video/pvrusb2/pvrusb2-devattr.h | |||
@@ -84,6 +84,10 @@ struct pvr2_device_desc { | |||
84 | /* Device has a wm8775 - this enables special additional logic to | 84 | /* Device has a wm8775 - this enables special additional logic to |
85 | ensure that it is found. */ | 85 | ensure that it is found. */ |
86 | char flag_has_wm8775; | 86 | char flag_has_wm8775; |
87 | |||
88 | /* Device has IR hardware that can be faked into looking like a | ||
89 | normal Hauppauge i2c IR receiver. */ | ||
90 | char flag_has_hauppauge_custom_ir; | ||
87 | }; | 91 | }; |
88 | 92 | ||
89 | extern const struct pvr2_device_desc pvr2_device_descriptions[]; | 93 | extern const struct pvr2_device_desc pvr2_device_descriptions[]; |
diff --git a/drivers/media/video/pvrusb2/pvrusb2-i2c-core.c b/drivers/media/video/pvrusb2/pvrusb2-i2c-core.c index 7721ec85d572..62867fa3517a 100644 --- a/drivers/media/video/pvrusb2/pvrusb2-i2c-core.c +++ b/drivers/media/video/pvrusb2/pvrusb2-i2c-core.c | |||
@@ -980,7 +980,7 @@ void pvr2_i2c_core_init(struct pvr2_hdw *hdw) | |||
980 | printk(KERN_INFO "%s: IR disabled\n",hdw->name); | 980 | printk(KERN_INFO "%s: IR disabled\n",hdw->name); |
981 | hdw->i2c_func[0x18] = i2c_black_hole; | 981 | hdw->i2c_func[0x18] = i2c_black_hole; |
982 | } else if (ir_mode[hdw->unit_number] == 1) { | 982 | } else if (ir_mode[hdw->unit_number] == 1) { |
983 | if (hdw->hdw_desc->flag_has_cx25840) { | 983 | if (hdw->hdw_desc->flag_has_hauppauge_custom_ir) { |
984 | hdw->i2c_func[0x18] = i2c_24xxx_ir; | 984 | hdw->i2c_func[0x18] = i2c_24xxx_ir; |
985 | } | 985 | } |
986 | } | 986 | } |