summaryrefslogtreecommitdiff
path: root/linux/drivers/media/video/tda9875.c
diff options
context:
space:
mode:
Diffstat (limited to 'linux/drivers/media/video/tda9875.c')
-rw-r--r--linux/drivers/media/video/tda9875.c36
1 files changed, 18 insertions, 18 deletions
diff --git a/linux/drivers/media/video/tda9875.c b/linux/drivers/media/video/tda9875.c
index cbb305b19..54c3fa517 100644
--- a/linux/drivers/media/video/tda9875.c
+++ b/linux/drivers/media/video/tda9875.c
@@ -1,19 +1,19 @@
/*
* For the TDA9875 chip
- * (The TDA9875 is used on the Diamond DTV2000 french version
+ * (The TDA9875 is used on the Diamond DTV2000 french version
* Other cards probably use these chips as well.)
- * This driver will not complain if used with any
+ * This driver will not complain if used with any
* other i2c device with the same address.
*
* Copyright (c) 2000 Guillaume Delvit based on Gerd Knorr source and
- * Eric Sandeen
+ * Eric Sandeen
* This code is placed under the terms of the GNU General Public License
* Based on tda9855.c by Steve VanDeBogart (vandebo@uclink.berkeley.edu)
* Which was based on tda8425.c by Greg Alexander (c) 1998
*
* OPTIONS:
* debug - set to 1 if you'd like to see debug messages
- *
+ *
* Revision: 0.1 - original version
*/
@@ -70,7 +70,7 @@ static struct i2c_client client_template;
* http://www.semiconductors.philips.com
* TDA9875: I2C-bus controlled DSP audio processor, FM demodulator
*
- */
+ */
/* subaddresses for TDA9875 */
#define TDA9875_MUT 0x12 /*General mute (value --> 0b11001100*/
@@ -139,7 +139,7 @@ static int tda9875_read(struct i2c_client *client)
printk(KERN_WARNING "tda9875: I/O error, trying (read)\n");
return -1;
}
- dprintk("Read 0x%02x\n", buffer);
+ dprintk("Read 0x%02x\n", buffer);
return buffer;
}
#endif
@@ -184,7 +184,7 @@ static void tda9875_set(struct i2c_client *client)
static void do_tda9875_init(struct i2c_client *client)
{
struct tda9875 *t = i2c_get_clientdata(client);
- dprintk("In tda9875_init\n");
+ dprintk("In tda9875_init\n");
tda9875_write(client, TDA9875_CFG, 0xd0 ); /*reg de config 0 (reset)*/
tda9875_write(client, TDA9875_MSR, 0x03 ); /* Monitor 0b00000XXX*/
tda9875_write(client, TDA9875_C1MSB, 0x00 ); /*Car1(FM) MSB XMHz*/
@@ -198,7 +198,7 @@ static void do_tda9875_init(struct i2c_client *client)
tda9875_write(client, TDA9875_FMAT, 0x00 ); /*FM Matrix reg 0x00*/
tda9875_write(client, TDA9875_SC1, 0x00 ); /* SCART 1 (SC1)*/
tda9875_write(client, TDA9875_SC2, 0x01 ); /* SCART 2 (sc2)*/
-
+
tda9875_write(client, TDA9875_CH1V, 0x10 ); /* Channel volume 1 mute*/
tda9875_write(client, TDA9875_CH2V, 0x10 ); /* Channel volume 2 mute */
tda9875_write(client, TDA9875_DACOS, 0x02 ); /* sig DAC i/o(in:nicam)*/
@@ -210,14 +210,14 @@ static void do_tda9875_init(struct i2c_client *client)
tda9875_write(client, TDA9875_MVR, 0x03 ); /* Vol Main right 10dB*/
tda9875_write(client, TDA9875_MBA, 0x00 ); /* Main Bass Main 0dB*/
tda9875_write(client, TDA9875_MTR, 0x00 ); /* Main Treble Main 0dB*/
- tda9875_write(client, TDA9875_ACS, 0x44 ); /* Aux chan select (dac)*/
+ tda9875_write(client, TDA9875_ACS, 0x44 ); /* Aux chan select (dac)*/
tda9875_write(client, TDA9875_AVL, 0x00 ); /* Vol Aux left 0dB*/
tda9875_write(client, TDA9875_AVR, 0x00 ); /* Vol Aux right 0dB*/
tda9875_write(client, TDA9875_ABA, 0x00 ); /* Aux Bass Main 0dB*/
tda9875_write(client, TDA9875_ATR, 0x00 ); /* Aux Aigus Main 0dB*/
-
+
tda9875_write(client, TDA9875_MUT, 0xcc ); /* General mute */
-
+
t->mode=AUDIO_UNMUTE;
t->lvol=t->rvol =0; /* 0dB */
t->bass=0; /* 0dB */
@@ -273,7 +273,7 @@ static int tda9875_attach(struct i2c_adapter *adap, int addr,
kfree(t);
return 1;
}
-
+
do_tda9875_init(client);
#if LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0)
MOD_INC_USE_COUNT;
@@ -302,7 +302,7 @@ static int tda9875_detach(struct i2c_client *client)
do_tda9875_init(client);
i2c_detach_client(client);
-
+
kfree(t);
#if LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0)
MOD_DEC_USE_COUNT;
@@ -315,9 +315,9 @@ static int tda9875_command(struct i2c_client *client,
{
struct tda9875 *t = i2c_get_clientdata(client);
- dprintk("In tda9875_command...\n");
+ dprintk("In tda9875_command...\n");
- switch (cmd) {
+ switch (cmd) {
/* --- v4l ioctls --- */
/* take care: bttv does userspace copying, we'll get a
kernel pointer here... */
@@ -352,7 +352,7 @@ static int tda9875_command(struct i2c_client *client,
struct video_audio *va = arg;
int left,right;
- dprintk("VIDEOCSAUDIO...\n");
+ dprintk("VIDEOCSAUDIO...\n");
left = (min(65536 - va->balance,32768) *
va->volume) / 32768;
right = (min(va->balance,(__u16)32768) *
@@ -374,7 +374,7 @@ static int tda9875_command(struct i2c_client *client,
t->bass = 15;
if (t->bass < -12)
t->bass = -12 & 0xff;
-
+
t->treble = ((va->treble/2700)-12) & 0xff;
if (t->treble > 12)
t->treble = 12;
@@ -384,7 +384,7 @@ static int tda9875_command(struct i2c_client *client,
//printk("tda9875 bal:%04x vol:%04x bass:%04x treble:%04x\n",va->balance,va->volume,va->bass,va->treble);
-
+
tda9875_set(client);