diff options
author | Hans Verkuil <hverkuil@xs4all.nl> | 2008-04-07 07:32:14 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@infradead.org> | 2008-04-24 13:08:00 -0400 |
commit | b38bf410fed223a48482e499150d4b554526a13a (patch) | |
tree | 2cc98a0878e9797aa1b145e0e0f1b618632607a6 /drivers/media/video/ivtv/ivtv-i2c.c | |
parent | faea4d2ab2d4710f87739fd53b5c13ca7a7d34aa (diff) |
V4L/DVB (7534): ivtv: the upd* modules have to be probed to properly autodetect some cards
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/video/ivtv/ivtv-i2c.c')
-rw-r--r-- | drivers/media/video/ivtv/ivtv-i2c.c | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/drivers/media/video/ivtv/ivtv-i2c.c b/drivers/media/video/ivtv/ivtv-i2c.c index fa5ab1eb1800..9824eafee021 100644 --- a/drivers/media/video/ivtv/ivtv-i2c.c +++ b/drivers/media/video/ivtv/ivtv-i2c.c | |||
@@ -177,10 +177,16 @@ int ivtv_i2c_register(struct ivtv *itv, unsigned idx) | |||
177 | } | 177 | } |
178 | 178 | ||
179 | if (id != I2C_DRIVERID_TUNER) { | 179 | if (id != I2C_DRIVERID_TUNER) { |
180 | c = i2c_new_device(&itv->i2c_adap, &info); | 180 | if (id == I2C_DRIVERID_UPD64031A || |
181 | if (c->driver == NULL) | 181 | id == I2C_DRIVERID_UPD64083) { |
182 | unsigned short addrs[2] = { info.addr, I2C_CLIENT_END }; | ||
183 | |||
184 | c = i2c_new_probed_device(&itv->i2c_adap, &info, addrs); | ||
185 | } else | ||
186 | c = i2c_new_device(&itv->i2c_adap, &info); | ||
187 | if (c && c->driver == NULL) | ||
182 | i2c_unregister_device(c); | 188 | i2c_unregister_device(c); |
183 | else | 189 | else if (c) |
184 | itv->i2c_clients[i] = c; | 190 | itv->i2c_clients[i] = c; |
185 | return itv->i2c_clients[i] ? 0 : -ENODEV; | 191 | return itv->i2c_clients[i] ? 0 : -ENODEV; |
186 | } | 192 | } |