diff options
Diffstat (limited to 'drivers/media')
-rw-r--r-- | drivers/media/dvb/frontends/tda10021.c | 4 | ||||
-rw-r--r-- | drivers/media/radio/radio-cadet.c | 2 | ||||
-rw-r--r-- | drivers/media/video/bttv-cards.c | 6 | ||||
-rw-r--r-- | drivers/media/video/bttv-driver.c | 14 | ||||
-rw-r--r-- | drivers/media/video/bttvp.h | 2 | ||||
-rw-r--r-- | drivers/media/video/cpia.c | 2 | ||||
-rw-r--r-- | drivers/media/video/rds.h | 2 | ||||
-rw-r--r-- | drivers/media/video/saa6588.c | 4 | ||||
-rw-r--r-- | drivers/media/video/vpx3220.c | 32 |
9 files changed, 38 insertions, 30 deletions
diff --git a/drivers/media/dvb/frontends/tda10021.c b/drivers/media/dvb/frontends/tda10021.c index 87d5f4d8790f..eaf130e666d8 100644 --- a/drivers/media/dvb/frontends/tda10021.c +++ b/drivers/media/dvb/frontends/tda10021.c | |||
@@ -100,8 +100,8 @@ static u8 tda10021_readreg (struct tda10021_state* state, u8 reg) | |||
100 | 100 | ||
101 | ret = i2c_transfer (state->i2c, msg, 2); | 101 | ret = i2c_transfer (state->i2c, msg, 2); |
102 | if (ret != 2) | 102 | if (ret != 2) |
103 | printk("DVB: TDA10021(%d): %s: readreg error (ret == %i)\n", | 103 | printk("DVB: TDA10021: %s: readreg error (ret == %i)\n", |
104 | state->frontend.dvb->num, __FUNCTION__, ret); | 104 | __FUNCTION__, ret); |
105 | return b1[0]; | 105 | return b1[0]; |
106 | } | 106 | } |
107 | 107 | ||
diff --git a/drivers/media/radio/radio-cadet.c b/drivers/media/radio/radio-cadet.c index 022913da8c59..9b0406318f2d 100644 --- a/drivers/media/radio/radio-cadet.c +++ b/drivers/media/radio/radio-cadet.c | |||
@@ -543,7 +543,7 @@ static int cadet_probe(void) | |||
543 | 543 | ||
544 | for(i=0;i<8;i++) { | 544 | for(i=0;i<8;i++) { |
545 | io=iovals[i]; | 545 | io=iovals[i]; |
546 | if(request_region(io,2, "cadet-probe")>=0) { | 546 | if (request_region(io, 2, "cadet-probe")) { |
547 | cadet_setfreq(1410); | 547 | cadet_setfreq(1410); |
548 | if(cadet_getfreq()==1410) { | 548 | if(cadet_getfreq()==1410) { |
549 | release_region(io, 2); | 549 | release_region(io, 2); |
diff --git a/drivers/media/video/bttv-cards.c b/drivers/media/video/bttv-cards.c index 190977a1e549..0881a17d5226 100644 --- a/drivers/media/video/bttv-cards.c +++ b/drivers/media/video/bttv-cards.c | |||
@@ -2393,12 +2393,12 @@ struct tvcard bttv_tvcards[] = { | |||
2393 | .tuner = 0, | 2393 | .tuner = 0, |
2394 | .tuner_type = TUNER_LG_TDVS_H062F, | 2394 | .tuner_type = TUNER_LG_TDVS_H062F, |
2395 | .tuner_addr = ADDR_UNSET, | 2395 | .tuner_addr = ADDR_UNSET, |
2396 | .video_inputs = 2, | 2396 | .video_inputs = 3, |
2397 | .audio_inputs = 1, | 2397 | .audio_inputs = 1, |
2398 | .svhs = 2, | 2398 | .svhs = 2, |
2399 | .muxsel = { 2, 3 }, | 2399 | .muxsel = { 2, 3, 1 }, |
2400 | .gpiomask = 0x00e00007, | 2400 | .gpiomask = 0x00e00007, |
2401 | .audiomux = { 0x00400005, 0, 0, 0, 0, 0 }, | 2401 | .audiomux = { 0x00400005, 0, 0x00000001, 0, 0x00c00007, 0 }, |
2402 | .no_msp34xx = 1, | 2402 | .no_msp34xx = 1, |
2403 | .no_tda9875 = 1, | 2403 | .no_tda9875 = 1, |
2404 | .no_tda7432 = 1, | 2404 | .no_tda7432 = 1, |
diff --git a/drivers/media/video/bttv-driver.c b/drivers/media/video/bttv-driver.c index a564321db2f0..c062a017491e 100644 --- a/drivers/media/video/bttv-driver.c +++ b/drivers/media/video/bttv-driver.c | |||
@@ -763,21 +763,21 @@ static void set_pll(struct bttv *btv) | |||
763 | /* no PLL needed */ | 763 | /* no PLL needed */ |
764 | if (btv->pll.pll_current == 0) | 764 | if (btv->pll.pll_current == 0) |
765 | return; | 765 | return; |
766 | vprintk(KERN_INFO "bttv%d: PLL can sleep, using XTAL (%d).\n", | 766 | bttv_printk(KERN_INFO "bttv%d: PLL can sleep, using XTAL (%d).\n", |
767 | btv->c.nr,btv->pll.pll_ifreq); | 767 | btv->c.nr,btv->pll.pll_ifreq); |
768 | btwrite(0x00,BT848_TGCTRL); | 768 | btwrite(0x00,BT848_TGCTRL); |
769 | btwrite(0x00,BT848_PLL_XCI); | 769 | btwrite(0x00,BT848_PLL_XCI); |
770 | btv->pll.pll_current = 0; | 770 | btv->pll.pll_current = 0; |
771 | return; | 771 | return; |
772 | } | 772 | } |
773 | 773 | ||
774 | vprintk(KERN_INFO "bttv%d: PLL: %d => %d ",btv->c.nr, | 774 | bttv_printk(KERN_INFO "bttv%d: PLL: %d => %d ",btv->c.nr, |
775 | btv->pll.pll_ifreq, btv->pll.pll_ofreq); | 775 | btv->pll.pll_ifreq, btv->pll.pll_ofreq); |
776 | set_pll_freq(btv, btv->pll.pll_ifreq, btv->pll.pll_ofreq); | 776 | set_pll_freq(btv, btv->pll.pll_ifreq, btv->pll.pll_ofreq); |
777 | 777 | ||
778 | for (i=0; i<10; i++) { | 778 | for (i=0; i<10; i++) { |
779 | /* Let other people run while the PLL stabilizes */ | 779 | /* Let other people run while the PLL stabilizes */ |
780 | vprintk("."); | 780 | bttv_printk("."); |
781 | msleep(10); | 781 | msleep(10); |
782 | 782 | ||
783 | if (btread(BT848_DSTATUS) & BT848_DSTATUS_PLOCK) { | 783 | if (btread(BT848_DSTATUS) & BT848_DSTATUS_PLOCK) { |
@@ -785,12 +785,12 @@ static void set_pll(struct bttv *btv) | |||
785 | } else { | 785 | } else { |
786 | btwrite(0x08,BT848_TGCTRL); | 786 | btwrite(0x08,BT848_TGCTRL); |
787 | btv->pll.pll_current = btv->pll.pll_ofreq; | 787 | btv->pll.pll_current = btv->pll.pll_ofreq; |
788 | vprintk(" ok\n"); | 788 | bttv_printk(" ok\n"); |
789 | return; | 789 | return; |
790 | } | 790 | } |
791 | } | 791 | } |
792 | btv->pll.pll_current = -1; | 792 | btv->pll.pll_current = -1; |
793 | vprintk("failed\n"); | 793 | bttv_printk("failed\n"); |
794 | return; | 794 | return; |
795 | } | 795 | } |
796 | 796 | ||
diff --git a/drivers/media/video/bttvp.h b/drivers/media/video/bttvp.h index 9b0b7ca035f8..7a312f79340a 100644 --- a/drivers/media/video/bttvp.h +++ b/drivers/media/video/bttvp.h | |||
@@ -221,7 +221,7 @@ extern void bttv_gpio_tracking(struct bttv *btv, char *comment); | |||
221 | extern int init_bttv_i2c(struct bttv *btv); | 221 | extern int init_bttv_i2c(struct bttv *btv); |
222 | extern int fini_bttv_i2c(struct bttv *btv); | 222 | extern int fini_bttv_i2c(struct bttv *btv); |
223 | 223 | ||
224 | #define vprintk if (bttv_verbose) printk | 224 | #define bttv_printk if (bttv_verbose) printk |
225 | #define dprintk if (bttv_debug >= 1) printk | 225 | #define dprintk if (bttv_debug >= 1) printk |
226 | #define d2printk if (bttv_debug >= 2) printk | 226 | #define d2printk if (bttv_debug >= 2) printk |
227 | 227 | ||
diff --git a/drivers/media/video/cpia.c b/drivers/media/video/cpia.c index 8c08b7f1ad23..b7ec9bf45085 100644 --- a/drivers/media/video/cpia.c +++ b/drivers/media/video/cpia.c | |||
@@ -1397,7 +1397,7 @@ static void destroy_proc_cpia_cam(struct cam_data *cam) | |||
1397 | 1397 | ||
1398 | static void proc_cpia_create(void) | 1398 | static void proc_cpia_create(void) |
1399 | { | 1399 | { |
1400 | cpia_proc_root = create_proc_entry("cpia", S_IFDIR, NULL); | 1400 | cpia_proc_root = proc_mkdir("cpia", NULL); |
1401 | 1401 | ||
1402 | if (cpia_proc_root) | 1402 | if (cpia_proc_root) |
1403 | cpia_proc_root->owner = THIS_MODULE; | 1403 | cpia_proc_root->owner = THIS_MODULE; |
diff --git a/drivers/media/video/rds.h b/drivers/media/video/rds.h index 30337d0f1a87..0d30eb744e61 100644 --- a/drivers/media/video/rds.h +++ b/drivers/media/video/rds.h | |||
@@ -31,7 +31,7 @@ | |||
31 | struct rds_command { | 31 | struct rds_command { |
32 | unsigned int block_count; | 32 | unsigned int block_count; |
33 | int result; | 33 | int result; |
34 | unsigned char *buffer; | 34 | unsigned char __user *buffer; |
35 | struct file *instance; | 35 | struct file *instance; |
36 | poll_table *event_list; | 36 | poll_table *event_list; |
37 | }; | 37 | }; |
diff --git a/drivers/media/video/saa6588.c b/drivers/media/video/saa6588.c index 1a657a70ff43..72b70eb5da1d 100644 --- a/drivers/media/video/saa6588.c +++ b/drivers/media/video/saa6588.c | |||
@@ -157,7 +157,7 @@ static struct i2c_client client_template; | |||
157 | 157 | ||
158 | /* ---------------------------------------------------------------------- */ | 158 | /* ---------------------------------------------------------------------- */ |
159 | 159 | ||
160 | static int block_to_user_buf(struct saa6588 *s, unsigned char *user_buf) | 160 | static int block_to_user_buf(struct saa6588 *s, unsigned char __user *user_buf) |
161 | { | 161 | { |
162 | int i; | 162 | int i; |
163 | 163 | ||
@@ -191,7 +191,7 @@ static void read_from_buf(struct saa6588 *s, struct rds_command *a) | |||
191 | { | 191 | { |
192 | unsigned long flags; | 192 | unsigned long flags; |
193 | 193 | ||
194 | unsigned char *buf_ptr = a->buffer; /* This is a user space buffer! */ | 194 | unsigned char __user *buf_ptr = a->buffer; |
195 | unsigned int i; | 195 | unsigned int i; |
196 | unsigned int rd_blocks; | 196 | unsigned int rd_blocks; |
197 | 197 | ||
diff --git a/drivers/media/video/vpx3220.c b/drivers/media/video/vpx3220.c index 4437bdebe24f..137b58f2c666 100644 --- a/drivers/media/video/vpx3220.c +++ b/drivers/media/video/vpx3220.c | |||
@@ -203,7 +203,7 @@ static const unsigned short init_ntsc[] = { | |||
203 | 0x8c, 640, /* Horizontal length */ | 203 | 0x8c, 640, /* Horizontal length */ |
204 | 0x8d, 640, /* Number of pixels */ | 204 | 0x8d, 640, /* Number of pixels */ |
205 | 0x8f, 0xc00, /* Disable window 2 */ | 205 | 0x8f, 0xc00, /* Disable window 2 */ |
206 | 0xf0, 0x173, /* 13.5 MHz transport, Forced | 206 | 0xf0, 0x73, /* 13.5 MHz transport, Forced |
207 | * mode, latch windows */ | 207 | * mode, latch windows */ |
208 | 0xf2, 0x13, /* NTSC M, composite input */ | 208 | 0xf2, 0x13, /* NTSC M, composite input */ |
209 | 0xe7, 0x1e1, /* Enable vertical standard | 209 | 0xe7, 0x1e1, /* Enable vertical standard |
@@ -212,38 +212,36 @@ static const unsigned short init_ntsc[] = { | |||
212 | 212 | ||
213 | static const unsigned short init_pal[] = { | 213 | static const unsigned short init_pal[] = { |
214 | 0x88, 23, /* Window 1 vertical begin */ | 214 | 0x88, 23, /* Window 1 vertical begin */ |
215 | 0x89, 288 + 16, /* Vertical lines in (16 lines | 215 | 0x89, 288, /* Vertical lines in (16 lines |
216 | * skipped by the VFE) */ | 216 | * skipped by the VFE) */ |
217 | 0x8a, 288 + 16, /* Vertical lines out (16 lines | 217 | 0x8a, 288, /* Vertical lines out (16 lines |
218 | * skipped by the VFE) */ | 218 | * skipped by the VFE) */ |
219 | 0x8b, 16, /* Horizontal begin */ | 219 | 0x8b, 16, /* Horizontal begin */ |
220 | 0x8c, 768, /* Horizontal length */ | 220 | 0x8c, 768, /* Horizontal length */ |
221 | 0x8d, 784, /* Number of pixels | 221 | 0x8d, 784, /* Number of pixels |
222 | * Must be >= Horizontal begin + Horizontal length */ | 222 | * Must be >= Horizontal begin + Horizontal length */ |
223 | 0x8f, 0xc00, /* Disable window 2 */ | 223 | 0x8f, 0xc00, /* Disable window 2 */ |
224 | 0xf0, 0x177, /* 13.5 MHz transport, Forced | 224 | 0xf0, 0x77, /* 13.5 MHz transport, Forced |
225 | * mode, latch windows */ | 225 | * mode, latch windows */ |
226 | 0xf2, 0x3d1, /* PAL B,G,H,I, composite input */ | 226 | 0xf2, 0x3d1, /* PAL B,G,H,I, composite input */ |
227 | 0xe7, 0x261, /* PAL/SECAM set to 288 + 16 lines | 227 | 0xe7, 0x241, /* PAL/SECAM set to 288 lines */ |
228 | * change to 0x241 for 288 lines */ | ||
229 | }; | 228 | }; |
230 | 229 | ||
231 | static const unsigned short init_secam[] = { | 230 | static const unsigned short init_secam[] = { |
232 | 0x88, 23 - 16, /* Window 1 vertical begin */ | 231 | 0x88, 23, /* Window 1 vertical begin */ |
233 | 0x89, 288 + 16, /* Vertical lines in (16 lines | 232 | 0x89, 288, /* Vertical lines in (16 lines |
234 | * skipped by the VFE) */ | 233 | * skipped by the VFE) */ |
235 | 0x8a, 288 + 16, /* Vertical lines out (16 lines | 234 | 0x8a, 288, /* Vertical lines out (16 lines |
236 | * skipped by the VFE) */ | 235 | * skipped by the VFE) */ |
237 | 0x8b, 16, /* Horizontal begin */ | 236 | 0x8b, 16, /* Horizontal begin */ |
238 | 0x8c, 768, /* Horizontal length */ | 237 | 0x8c, 768, /* Horizontal length */ |
239 | 0x8d, 784, /* Number of pixels | 238 | 0x8d, 784, /* Number of pixels |
240 | * Must be >= Horizontal begin + Horizontal length */ | 239 | * Must be >= Horizontal begin + Horizontal length */ |
241 | 0x8f, 0xc00, /* Disable window 2 */ | 240 | 0x8f, 0xc00, /* Disable window 2 */ |
242 | 0xf0, 0x177, /* 13.5 MHz transport, Forced | 241 | 0xf0, 0x77, /* 13.5 MHz transport, Forced |
243 | * mode, latch windows */ | 242 | * mode, latch windows */ |
244 | 0xf2, 0x3d5, /* SECAM, composite input */ | 243 | 0xf2, 0x3d5, /* SECAM, composite input */ |
245 | 0xe7, 0x261, /* PAL/SECAM set to 288 + 16 lines | 244 | 0xe7, 0x241, /* PAL/SECAM set to 288 lines */ |
246 | * change to 0x241 for 288 lines */ | ||
247 | }; | 245 | }; |
248 | 246 | ||
249 | static const unsigned char init_common[] = { | 247 | static const unsigned char init_common[] = { |
@@ -410,6 +408,12 @@ vpx3220_command (struct i2c_client *client, | |||
410 | case DECODER_SET_NORM: | 408 | case DECODER_SET_NORM: |
411 | { | 409 | { |
412 | int *iarg = arg, data; | 410 | int *iarg = arg, data; |
411 | int temp_input; | ||
412 | |||
413 | /* Here we back up the input selection because it gets | ||
414 | overwritten when we fill the registers with the | ||
415 | choosen video norm */ | ||
416 | temp_input = vpx3220_fp_read(client, 0xf2); | ||
413 | 417 | ||
414 | dprintk(1, KERN_DEBUG "%s: DECODER_SET_NORM %d\n", | 418 | dprintk(1, KERN_DEBUG "%s: DECODER_SET_NORM %d\n", |
415 | I2C_NAME(client), *iarg); | 419 | I2C_NAME(client), *iarg); |
@@ -449,6 +453,10 @@ vpx3220_command (struct i2c_client *client, | |||
449 | 453 | ||
450 | } | 454 | } |
451 | decoder->norm = *iarg; | 455 | decoder->norm = *iarg; |
456 | |||
457 | /* And here we set the backed up video input again */ | ||
458 | vpx3220_fp_write(client, 0xf2, temp_input | 0x0010); | ||
459 | udelay(10); | ||
452 | } | 460 | } |
453 | break; | 461 | break; |
454 | 462 | ||