diff options
| author | Mauro Carvalho Chehab <mchehab@brturbo.com.br> | 2005-07-12 16:58:53 -0400 |
|---|---|---|
| committer | Linus Torvalds <torvalds@g5.osdl.org> | 2005-07-12 19:01:05 -0400 |
| commit | ebe4c6fa535b0410e58e9c8352320896d07e2efb (patch) | |
| tree | b608627d954de8c5d795d10506722751f9db223b /drivers | |
| parent | 60acbc99e82753b0baa64834435caf81eabc2501 (diff) | |
[PATCH] v4l: I2C Miscelaneous
- Removed unused structures.
- CodingStyle rules applied to comments.
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')
| -rw-r--r-- | drivers/media/video/msp3400.c | 25 | ||||
| -rw-r--r-- | drivers/media/video/tda7432.c | 13 | ||||
| -rw-r--r-- | drivers/media/video/tda9875.c | 13 | ||||
| -rw-r--r-- | drivers/media/video/tvaudio.c | 5 |
4 files changed, 4 insertions, 52 deletions
diff --git a/drivers/media/video/msp3400.c b/drivers/media/video/msp3400.c index b4ee9dfe6d42..6239254db27e 100644 --- a/drivers/media/video/msp3400.c +++ b/drivers/media/video/msp3400.c | |||
| @@ -567,10 +567,6 @@ static void msp3400c_set_audmode(struct i2c_client *client, int audmode) | |||
| 567 | switch (audmode) { | 567 | switch (audmode) { |
| 568 | case V4L2_TUNER_MODE_STEREO: | 568 | case V4L2_TUNER_MODE_STEREO: |
| 569 | src = 0x0020 | nicam; | 569 | src = 0x0020 | nicam; |
| 570 | #if 0 | ||
| 571 | /* spatial effect */ | ||
| 572 | msp3400c_write(client,I2C_MSP3400C_DFP, 0x0005,0x4000); | ||
| 573 | #endif | ||
| 574 | break; | 570 | break; |
| 575 | case V4L2_TUNER_MODE_MONO: | 571 | case V4L2_TUNER_MODE_MONO: |
| 576 | if (msp->mode == MSP_MODE_AM_NICAM) { | 572 | if (msp->mode == MSP_MODE_AM_NICAM) { |
| @@ -741,16 +737,14 @@ static int msp34xx_sleep(struct msp3400c *msp, int timeout) | |||
| 741 | set_current_state(TASK_INTERRUPTIBLE); | 737 | set_current_state(TASK_INTERRUPTIBLE); |
| 742 | schedule(); | 738 | schedule(); |
| 743 | } else { | 739 | } else { |
| 744 | #if 0 | ||
| 745 | /* hmm, that one doesn't return on wakeup ... */ | ||
| 746 | msleep_interruptible(timeout); | ||
| 747 | #else | ||
| 748 | set_current_state(TASK_INTERRUPTIBLE); | 740 | set_current_state(TASK_INTERRUPTIBLE); |
| 749 | schedule_timeout(msecs_to_jiffies(timeout)); | 741 | schedule_timeout(msecs_to_jiffies(timeout)); |
| 750 | #endif | ||
| 751 | } | 742 | } |
| 752 | } | 743 | } |
| 753 | try_to_freeze(); | 744 | if (current->flags & PF_FREEZE) { |
| 745 | refrigerator (); | ||
| 746 | } | ||
| 747 | |||
| 754 | remove_wait_queue(&msp->wq, &wait); | 748 | remove_wait_queue(&msp->wq, &wait); |
| 755 | return msp->restart; | 749 | return msp->restart; |
| 756 | } | 750 | } |
| @@ -1154,17 +1148,10 @@ static int msp3410d_thread(void *data) | |||
| 1154 | MSP_CARRIER(10.7)); | 1148 | MSP_CARRIER(10.7)); |
| 1155 | /* scart routing */ | 1149 | /* scart routing */ |
| 1156 | msp3400c_set_scart(client,SCART_IN2,0); | 1150 | msp3400c_set_scart(client,SCART_IN2,0); |
| 1157 | #if 0 | ||
| 1158 | /* radio from SCART_IN2 */ | ||
| 1159 | msp3400c_write(client,I2C_MSP3400C_DFP, 0x08, 0x0220); | ||
| 1160 | msp3400c_write(client,I2C_MSP3400C_DFP, 0x09, 0x0220); | ||
| 1161 | msp3400c_write(client,I2C_MSP3400C_DFP, 0x0b, 0x0220); | ||
| 1162 | #else | ||
| 1163 | /* msp34xx does radio decoding */ | 1151 | /* msp34xx does radio decoding */ |
| 1164 | msp3400c_write(client,I2C_MSP3400C_DFP, 0x08, 0x0020); | 1152 | msp3400c_write(client,I2C_MSP3400C_DFP, 0x08, 0x0020); |
| 1165 | msp3400c_write(client,I2C_MSP3400C_DFP, 0x09, 0x0020); | 1153 | msp3400c_write(client,I2C_MSP3400C_DFP, 0x09, 0x0020); |
| 1166 | msp3400c_write(client,I2C_MSP3400C_DFP, 0x0b, 0x0020); | 1154 | msp3400c_write(client,I2C_MSP3400C_DFP, 0x0b, 0x0020); |
| 1167 | #endif | ||
| 1168 | break; | 1155 | break; |
| 1169 | case 0x0003: | 1156 | case 0x0003: |
| 1170 | case 0x0004: | 1157 | case 0x0004: |
| @@ -1507,10 +1494,6 @@ static int msp_attach(struct i2c_adapter *adap, int addr, int kind) | |||
| 1507 | return -1; | 1494 | return -1; |
| 1508 | } | 1495 | } |
| 1509 | 1496 | ||
| 1510 | #if 0 | ||
| 1511 | /* this will turn on a 1kHz beep - might be useful for debugging... */ | ||
| 1512 | msp3400c_write(c,I2C_MSP3400C_DFP, 0x0014, 0x1040); | ||
| 1513 | #endif | ||
| 1514 | msp3400c_setvolume(c, msp->muted, msp->volume, msp->balance); | 1497 | msp3400c_setvolume(c, msp->muted, msp->volume, msp->balance); |
| 1515 | 1498 | ||
| 1516 | snprintf(c->name, sizeof(c->name), "MSP34%02d%c-%c%d", | 1499 | snprintf(c->name, sizeof(c->name), "MSP34%02d%c-%c%d", |
diff --git a/drivers/media/video/tda7432.c b/drivers/media/video/tda7432.c index 07ba6d3ed08c..7cb1fb3e66f9 100644 --- a/drivers/media/video/tda7432.c +++ b/drivers/media/video/tda7432.c | |||
| @@ -243,19 +243,6 @@ static int tda7432_write(struct i2c_client *client, int subaddr, int val) | |||
| 243 | } | 243 | } |
| 244 | 244 | ||
| 245 | /* I don't think we ever actually _read_ the chip... */ | 245 | /* I don't think we ever actually _read_ the chip... */ |
| 246 | #if 0 | ||
| 247 | static int tda7432_read(struct i2c_client *client) | ||
| 248 | { | ||
| 249 | unsigned char buffer; | ||
| 250 | d2printk("tda7432: In tda7432_read\n"); | ||
| 251 | if (1 != i2c_master_recv(client,&buffer,1)) { | ||
| 252 | printk(KERN_WARNING "tda7432: I/O error, trying (read)\n"); | ||
| 253 | return -1; | ||
| 254 | } | ||
| 255 | dprintk("tda7432: Read 0x%02x\n", buffer); | ||
| 256 | return buffer; | ||
| 257 | } | ||
| 258 | #endif | ||
| 259 | 246 | ||
| 260 | static int tda7432_set(struct i2c_client *client) | 247 | static int tda7432_set(struct i2c_client *client) |
| 261 | { | 248 | { |
diff --git a/drivers/media/video/tda9875.c b/drivers/media/video/tda9875.c index 97b113e070f3..566e1a5ca135 100644 --- a/drivers/media/video/tda9875.c +++ b/drivers/media/video/tda9875.c | |||
| @@ -123,19 +123,6 @@ static int tda9875_write(struct i2c_client *client, int subaddr, unsigned char v | |||
| 123 | return 0; | 123 | return 0; |
| 124 | } | 124 | } |
| 125 | 125 | ||
| 126 | #if 0 | ||
| 127 | static int tda9875_read(struct i2c_client *client) | ||
| 128 | { | ||
| 129 | unsigned char buffer; | ||
| 130 | dprintk("In tda9875_read\n"); | ||
| 131 | if (1 != i2c_master_recv(client,&buffer,1)) { | ||
| 132 | printk(KERN_WARNING "tda9875: I/O error, trying (read)\n"); | ||
| 133 | return -1; | ||
| 134 | } | ||
| 135 | dprintk("Read 0x%02x\n", buffer); | ||
| 136 | return buffer; | ||
| 137 | } | ||
| 138 | #endif | ||
| 139 | 126 | ||
| 140 | static int i2c_read_register(struct i2c_adapter *adap, int addr, int reg) | 127 | static int i2c_read_register(struct i2c_adapter *adap, int addr, int reg) |
| 141 | { | 128 | { |
diff --git a/drivers/media/video/tvaudio.c b/drivers/media/video/tvaudio.c index 9a493bea76d8..d8b78f1d686b 100644 --- a/drivers/media/video/tvaudio.c +++ b/drivers/media/video/tvaudio.c | |||
| @@ -864,13 +864,8 @@ static int tda9874a_getmode(struct CHIPSTATE *chip) | |||
| 864 | * But changing the mode to VIDEO_SOUND_MONO would switch | 864 | * But changing the mode to VIDEO_SOUND_MONO would switch |
| 865 | * external 4052 multiplexer in audio_hook(). | 865 | * external 4052 multiplexer in audio_hook(). |
| 866 | */ | 866 | */ |
| 867 | #if 0 | ||
| 868 | if((nsr & 0x02) && !(dsr & 0x10)) /* NSR.S/MB=1 and DSR.AMSTAT=0 */ | ||
| 869 | mode |= VIDEO_SOUND_STEREO; | ||
| 870 | #else | ||
| 871 | if(nsr & 0x02) /* NSR.S/MB=1 */ | 867 | if(nsr & 0x02) /* NSR.S/MB=1 */ |
| 872 | mode |= VIDEO_SOUND_STEREO; | 868 | mode |= VIDEO_SOUND_STEREO; |
| 873 | #endif | ||
| 874 | if(nsr & 0x01) /* NSR.D/SB=1 */ | 869 | if(nsr & 0x01) /* NSR.D/SB=1 */ |
| 875 | mode |= VIDEO_SOUND_LANG1 | VIDEO_SOUND_LANG2; | 870 | mode |= VIDEO_SOUND_LANG1 | VIDEO_SOUND_LANG2; |
| 876 | } else { | 871 | } else { |
