summaryrefslogtreecommitdiffstats
path: root/drivers/media/video/au0828/au0828-cards.c
diff options
context:
space:
mode:
authorDevin Heitmueller <dheitmueller@linuxtv.org>2009-03-11 03:01:04 -0300
committerMauro Carvalho Chehab <mchehab@redhat.com>2009-03-30 12:43:27 -0300
commitb14667f32ad0f85f986847ef65f9f3d12a44b71a (patch)
treebb5e0a2867f9d16e37d2a27f9a5d3b7efe122f5f /drivers/media/video/au0828/au0828-cards.c
parent2eaf396020555973cad7aa5b517c2418eccbca50 (diff)
V4L/DVB (11080): au0828: Convert to use v4l2_device/subdev framework
Convert over to using the new subdev framework for the au0828 bridge. This includes using the new i2c probing mechanism. Signed-off-by: Devin Heitmueller <dheitmueller@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/au0828/au0828-cards.c')
-rw-r--r--drivers/media/video/au0828/au0828-cards.c13
1 files changed, 11 insertions, 2 deletions
diff --git a/drivers/media/video/au0828/au0828-cards.c b/drivers/media/video/au0828/au0828-cards.c
index 0516c060810..a12c92c0374 100644
--- a/drivers/media/video/au0828/au0828-cards.c
+++ b/drivers/media/video/au0828/au0828-cards.c
@@ -173,6 +173,7 @@ void au0828_card_setup(struct au0828_dev *dev)
{
static u8 eeprom[256];
struct tuner_setup tun_setup;
+ struct v4l2_subdev *sd;
unsigned int mode_mask = T_ANALOG_TV |
T_DIGITAL_TV;
@@ -199,13 +200,21 @@ void au0828_card_setup(struct au0828_dev *dev)
/* Load the analog demodulator driver (note this would need to
be abstracted out if we ever need to support a different
demod) */
- request_module("au8522");
+ sd = v4l2_i2c_new_subdev(&dev->i2c_adap, "au8522", "au8522",
+ 0x8e >> 1);
+ if (sd == NULL) {
+ printk("analog subdev registration failure\n");
+ }
}
/* Setup tuners */
if (dev->board.tuner_type != TUNER_ABSENT) {
/* Load the tuner module, which does the attach */
- request_module("tuner");
+ sd = v4l2_i2c_new_subdev(&dev->i2c_adap, "tuner", "tuner",
+ dev->board.tuner_addr);
+ if (sd == NULL) {
+ printk("analog tuner subdev registration failure\n");
+ }
tun_setup.mode_mask = mode_mask;
tun_setup.type = dev->board.tuner_type;