aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/bttv-i2c.c
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@brturbo.com.br>2005-07-12 16:58:42 -0400
committerLinus Torvalds <torvalds@g5.osdl.org>2005-07-12 19:01:04 -0400
commitfa9846a8c5965636fbade8655ae0ce1f9a655bd4 (patch)
tree4a011e90cd64eedeeb01bd09e1d3175b3a0edd17 /drivers/media/video/bttv-i2c.c
parentde9c634270df3e27675a3c0e95545d2b3f754e3f (diff)
[PATCH] v4l: BTTV update
- use DMA_32BIT_MASK. - Rename tuner structures fields. - Tail spaces removed. - I2C cleanups and converged to a basic reference structure. - Removed unused structures. - Removed BTTV version check. Signed-off-by: <domen@coderock.org> Signed-off-by: Michael Krufky <mkrufky@m1k.net> Signed-Off-By: Nickolay V. Shmyrev <nshmyrev@yandex.ru> Signed-off-by: Mauro Carvalho Chehab <mchehab@brturbo.com.br> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers/media/video/bttv-i2c.c')
-rw-r--r--drivers/media/video/bttv-i2c.c26
1 files changed, 19 insertions, 7 deletions
diff --git a/drivers/media/video/bttv-i2c.c b/drivers/media/video/bttv-i2c.c
index da448a5f9e9c..234a85563769 100644
--- a/drivers/media/video/bttv-i2c.c
+++ b/drivers/media/video/bttv-i2c.c
@@ -1,5 +1,5 @@
1/* 1/*
2 $Id: bttv-i2c.c,v 1.21 2005/06/10 17:20:24 mchehab Exp $ 2 $Id: bttv-i2c.c,v 1.25 2005/07/05 17:37:35 nsh Exp $
3 3
4 bttv-i2c.c -- all the i2c code is here 4 bttv-i2c.c -- all the i2c code is here
5 5
@@ -295,14 +295,26 @@ static int attach_inform(struct i2c_client *client)
295{ 295{
296 struct bttv *btv = i2c_get_adapdata(client->adapter); 296 struct bttv *btv = i2c_get_adapdata(client->adapter);
297 297
298 if (btv->tuner_type != UNSET) 298 if (bttv_debug)
299 bttv_call_i2c_clients(btv,TUNER_SET_TYPE,&btv->tuner_type); 299 printk(KERN_DEBUG "bttv%d: %s i2c attach [addr=0x%x,client=%s]\n",
300 btv->c.nr,client->driver->name,client->addr,
301 i2c_clientname(client));
302 if (!client->driver->command)
303 return 0;
304
305 if (btv->tuner_type != UNSET) {
306 struct tuner_setup tun_setup;
307
308 tun_setup.mode_mask = T_RADIO | T_ANALOG_TV | T_DIGITAL_TV;
309 tun_setup.type = btv->tuner_type;
310 tun_setup.addr = ADDR_UNSET;
311
312 client->driver->command (client, TUNER_SET_TYPE_ADDR, &tun_setup);
313 }
314
300 if (btv->pinnacle_id != UNSET) 315 if (btv->pinnacle_id != UNSET)
301 bttv_call_i2c_clients(btv,AUDC_CONFIG_PINNACLE, 316 client->driver->command(client,AUDC_CONFIG_PINNACLE,
302 &btv->pinnacle_id); 317 &btv->pinnacle_id);
303 if (bttv_debug)
304 printk("bttv%d: i2c attach [client=%s]\n",
305 btv->c.nr, i2c_clientname(client));
306 return 0; 318 return 0;
307} 319}
308 320