aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media
diff options
context:
space:
mode:
authorJames Bottomley <jejb@mulgrave.il.steeleye.com>2007-01-31 12:24:00 -0500
committerJames Bottomley <jejb@mulgrave.il.steeleye.com>2007-01-31 12:24:00 -0500
commit30716e07ef511ec7525c07eb1e8060ba8943c2a2 (patch)
treeeb6a47cae63d3587fa773cc5a16781eaa2c7810b /drivers/media
parent03c79cc56e4497cbd09d74a73c1bd0d1d9a8a16c (diff)
parentf56df2f4db6e4af87fb8e941cff69f4501a111df (diff)
Merge branch 'linus'
Diffstat (limited to 'drivers/media')
-rw-r--r--drivers/media/video/cx88/cx88-tvaudio.c2
-rw-r--r--drivers/media/video/ks0127.c8
-rw-r--r--drivers/media/video/saa7134/saa7134-cards.c14
-rw-r--r--drivers/media/video/tveeprom.c2
-rw-r--r--drivers/media/video/usbvideo/quickcam_messenger.h14
-rw-r--r--drivers/media/video/usbvision/usbvision-video.c3
-rw-r--r--drivers/media/video/v4l2-common.c9
-rw-r--r--drivers/media/video/video-buf.c3
-rw-r--r--drivers/media/video/vivi.c7
9 files changed, 35 insertions, 27 deletions
diff --git a/drivers/media/video/cx88/cx88-tvaudio.c b/drivers/media/video/cx88/cx88-tvaudio.c
index 3482e0114d43..2bd84d351a18 100644
--- a/drivers/media/video/cx88/cx88-tvaudio.c
+++ b/drivers/media/video/cx88/cx88-tvaudio.c
@@ -38,6 +38,7 @@
38#include <linux/module.h> 38#include <linux/module.h>
39#include <linux/moduleparam.h> 39#include <linux/moduleparam.h>
40#include <linux/errno.h> 40#include <linux/errno.h>
41#include <linux/freezer.h>
41#include <linux/kernel.h> 42#include <linux/kernel.h>
42#include <linux/slab.h> 43#include <linux/slab.h>
43#include <linux/mm.h> 44#include <linux/mm.h>
@@ -961,6 +962,7 @@ int cx88_audio_thread(void *data)
961 msleep_interruptible(1000); 962 msleep_interruptible(1000);
962 if (kthread_should_stop()) 963 if (kthread_should_stop())
963 break; 964 break;
965 try_to_freeze();
964 966
965 /* just monitor the audio status for now ... */ 967 /* just monitor the audio status for now ... */
966 memset(&t, 0, sizeof(t)); 968 memset(&t, 0, sizeof(t));
diff --git a/drivers/media/video/ks0127.c b/drivers/media/video/ks0127.c
index c1a377f797d9..b6cd21e6dab9 100644
--- a/drivers/media/video/ks0127.c
+++ b/drivers/media/video/ks0127.c
@@ -712,13 +712,13 @@ static int ks0127_command(struct i2c_client *client,
712 *iarg = 0; 712 *iarg = 0;
713 status = ks0127_read(ks, KS_STAT); 713 status = ks0127_read(ks, KS_STAT);
714 if (!(status & 0x20)) /* NOVID not set */ 714 if (!(status & 0x20)) /* NOVID not set */
715 *iarg = (*iarg & DECODER_STATUS_GOOD); 715 *iarg = (*iarg | DECODER_STATUS_GOOD);
716 if ((status & 0x01)) /* CLOCK set */ 716 if ((status & 0x01)) /* CLOCK set */
717 *iarg = (*iarg & DECODER_STATUS_COLOR); 717 *iarg = (*iarg | DECODER_STATUS_COLOR);
718 if ((status & 0x08)) /* PALDET set */ 718 if ((status & 0x08)) /* PALDET set */
719 *iarg = (*iarg & DECODER_STATUS_PAL); 719 *iarg = (*iarg | DECODER_STATUS_PAL);
720 else 720 else
721 *iarg = (*iarg & DECODER_STATUS_NTSC); 721 *iarg = (*iarg | DECODER_STATUS_NTSC);
722 break; 722 break;
723 723
724 //Catch any unknown command 724 //Catch any unknown command
diff --git a/drivers/media/video/saa7134/saa7134-cards.c b/drivers/media/video/saa7134/saa7134-cards.c
index 4dead84aff46..ae984bbe36b6 100644
--- a/drivers/media/video/saa7134/saa7134-cards.c
+++ b/drivers/media/video/saa7134/saa7134-cards.c
@@ -2570,6 +2570,7 @@ struct saa7134_board saa7134_boards[] = {
2570 .radio_type = UNSET, 2570 .radio_type = UNSET,
2571 .tuner_addr = ADDR_UNSET, 2571 .tuner_addr = ADDR_UNSET,
2572 .radio_addr = ADDR_UNSET, 2572 .radio_addr = ADDR_UNSET,
2573 .gpiomask = 1 << 21,
2573 .inputs = {{ 2574 .inputs = {{
2574 .name = name_tv, 2575 .name = name_tv,
2575 .vmux = 1, 2576 .vmux = 1,
@@ -2578,15 +2579,20 @@ struct saa7134_board saa7134_boards[] = {
2578 },{ 2579 },{
2579 .name = name_comp1, 2580 .name = name_comp1,
2580 .vmux = 3, 2581 .vmux = 3,
2581 .amux = LINE1, 2582 .amux = LINE2, /* unconfirmed, taken from Philips driver */
2583 },{
2584 .name = name_comp2,
2585 .vmux = 0, /* untested, Composite over S-Video */
2586 .amux = LINE2,
2582 },{ 2587 },{
2583 .name = name_svideo, 2588 .name = name_svideo,
2584 .vmux = 0, 2589 .vmux = 8,
2585 .amux = LINE1, 2590 .amux = LINE2,
2586 }}, 2591 }},
2587 .radio = { 2592 .radio = {
2588 .name = name_radio, 2593 .name = name_radio,
2589 .amux = LINE1, 2594 .amux = TV,
2595 .gpio = 0x0200000,
2590 }, 2596 },
2591 }, 2597 },
2592 [SAA7134_BOARD_CINERGY250PCI] = { 2598 [SAA7134_BOARD_CINERGY250PCI] = {
diff --git a/drivers/media/video/tveeprom.c b/drivers/media/video/tveeprom.c
index 2624e3f7dd29..4e7c1fa668d3 100644
--- a/drivers/media/video/tveeprom.c
+++ b/drivers/media/video/tveeprom.c
@@ -184,7 +184,7 @@ hauppauge_tuner[] =
184 { TUNER_ABSENT, "Thompson DTT757"}, 184 { TUNER_ABSENT, "Thompson DTT757"},
185 /* 80-89 */ 185 /* 80-89 */
186 { TUNER_ABSENT, "Philips FQ1216LME MK3"}, 186 { TUNER_ABSENT, "Philips FQ1216LME MK3"},
187 { TUNER_ABSENT, "LG TAPC G701D"}, 187 { TUNER_LG_PAL_NEW_TAPC, "LG TAPC G701D"},
188 { TUNER_LG_NTSC_NEW_TAPC, "LG TAPC H791F"}, 188 { TUNER_LG_NTSC_NEW_TAPC, "LG TAPC H791F"},
189 { TUNER_LG_PAL_NEW_TAPC, "TCL 2002MB 3"}, 189 { TUNER_LG_PAL_NEW_TAPC, "TCL 2002MB 3"},
190 { TUNER_LG_PAL_NEW_TAPC, "TCL 2002MI 3"}, 190 { TUNER_LG_PAL_NEW_TAPC, "TCL 2002MI 3"},
diff --git a/drivers/media/video/usbvideo/quickcam_messenger.h b/drivers/media/video/usbvideo/quickcam_messenger.h
index baab9c081b52..17ace394d981 100644
--- a/drivers/media/video/usbvideo/quickcam_messenger.h
+++ b/drivers/media/video/usbvideo/quickcam_messenger.h
@@ -35,27 +35,13 @@ struct rgb {
35}; 35};
36 36
37struct bayL0 { 37struct bayL0 {
38#ifdef __BIG_ENDIAN
39 u8 r;
40 u8 g;
41#elif __LITTLE_ENDIAN
42 u8 g; 38 u8 g;
43 u8 r; 39 u8 r;
44#else
45#error not byte order defined
46#endif
47}; 40};
48 41
49struct bayL1 { 42struct bayL1 {
50#ifdef __BIG_ENDIAN
51 u8 g;
52 u8 b;
53#elif __LITTLE_ENDIAN
54 u8 b; 43 u8 b;
55 u8 g; 44 u8 g;
56#else
57#error not byte order defined
58#endif
59}; 45};
60 46
61struct cam_size { 47struct cam_size {
diff --git a/drivers/media/video/usbvision/usbvision-video.c b/drivers/media/video/usbvision/usbvision-video.c
index 8c7eba2a728e..7243337b771a 100644
--- a/drivers/media/video/usbvision/usbvision-video.c
+++ b/drivers/media/video/usbvision/usbvision-video.c
@@ -1080,7 +1080,6 @@ static ssize_t usbvision_v4l2_read(struct file *file, char *buf,
1080 int noblock = file->f_flags & O_NONBLOCK; 1080 int noblock = file->f_flags & O_NONBLOCK;
1081 unsigned long lock_flags; 1081 unsigned long lock_flags;
1082 1082
1083 int frmx = -1;
1084 int ret,i; 1083 int ret,i;
1085 struct usbvision_frame *frame; 1084 struct usbvision_frame *frame;
1086 1085
@@ -1155,7 +1154,7 @@ static ssize_t usbvision_v4l2_read(struct file *file, char *buf,
1155 frame->bytes_read = 0; 1154 frame->bytes_read = 0;
1156 1155
1157 /* Mark it as available to be used again. */ 1156 /* Mark it as available to be used again. */
1158 usbvision->frame[frmx].grabstate = FrameState_Unused; 1157 frame->grabstate = FrameState_Unused;
1159/* } */ 1158/* } */
1160 1159
1161 return count; 1160 return count;
diff --git a/drivers/media/video/v4l2-common.c b/drivers/media/video/v4l2-common.c
index 752c82c37f55..b87d571e0463 100644
--- a/drivers/media/video/v4l2-common.c
+++ b/drivers/media/video/v4l2-common.c
@@ -90,8 +90,15 @@ MODULE_LICENSE("GPL");
90char *v4l2_norm_to_name(v4l2_std_id id) 90char *v4l2_norm_to_name(v4l2_std_id id)
91{ 91{
92 char *name; 92 char *name;
93 u32 myid = id;
93 94
94 switch (id) { 95 /* HACK: ppc32 architecture doesn't have __ucmpdi2 function to handle
96 64 bit comparations. So, on that architecture, with some gcc variants,
97 compilation fails. Currently, the max value is 30bit wide.
98 */
99 BUG_ON(myid != id);
100
101 switch (myid) {
95 case V4L2_STD_PAL: 102 case V4L2_STD_PAL:
96 name="PAL"; break; 103 name="PAL"; break;
97 case V4L2_STD_PAL_BG: 104 case V4L2_STD_PAL_BG:
diff --git a/drivers/media/video/video-buf.c b/drivers/media/video/video-buf.c
index f429f49901b9..6504a5866849 100644
--- a/drivers/media/video/video-buf.c
+++ b/drivers/media/video/video-buf.c
@@ -700,6 +700,7 @@ videobuf_qbuf(struct videobuf_queue *q,
700 goto done; 700 goto done;
701 } 701 }
702 if (buf->state == STATE_QUEUED || 702 if (buf->state == STATE_QUEUED ||
703 buf->state == STATE_PREPARED ||
703 buf->state == STATE_ACTIVE) { 704 buf->state == STATE_ACTIVE) {
704 dprintk(1,"qbuf: buffer is already queued or active.\n"); 705 dprintk(1,"qbuf: buffer is already queued or active.\n");
705 goto done; 706 goto done;
@@ -1229,7 +1230,7 @@ videobuf_vm_nopage(struct vm_area_struct *vma, unsigned long vaddr,
1229 vaddr,vma->vm_start,vma->vm_end); 1230 vaddr,vma->vm_start,vma->vm_end);
1230 if (vaddr > vma->vm_end) 1231 if (vaddr > vma->vm_end)
1231 return NOPAGE_SIGBUS; 1232 return NOPAGE_SIGBUS;
1232 page = alloc_page(GFP_USER); 1233 page = alloc_page(GFP_USER | __GFP_DMA32);
1233 if (!page) 1234 if (!page)
1234 return NOPAGE_OOM; 1235 return NOPAGE_OOM;
1235 clear_user_page(page_address(page), vaddr, page); 1236 clear_user_page(page_address(page), vaddr, page);
diff --git a/drivers/media/video/vivi.c b/drivers/media/video/vivi.c
index bacb311b4f24..d4cf55666731 100644
--- a/drivers/media/video/vivi.c
+++ b/drivers/media/video/vivi.c
@@ -270,10 +270,15 @@ static void gen_line(struct sg_to_addr to_addr[],int inipos,int pages,int wmax,
270 char *p,*s,*basep; 270 char *p,*s,*basep;
271 struct page *pg; 271 struct page *pg;
272 u8 chr,r,g,b,color; 272 u8 chr,r,g,b,color;
273 unsigned long flags;
274 spinlock_t spinlock;
275
276 spin_lock_init(&spinlock);
273 277
274 /* Get first addr pointed to pixel position */ 278 /* Get first addr pointed to pixel position */
275 oldpg=get_addr_pos(pos,pages,to_addr); 279 oldpg=get_addr_pos(pos,pages,to_addr);
276 pg=pfn_to_page(sg_dma_address(to_addr[oldpg].sg) >> PAGE_SHIFT); 280 pg=pfn_to_page(sg_dma_address(to_addr[oldpg].sg) >> PAGE_SHIFT);
281 spin_lock_irqsave(&spinlock,flags);
277 basep = kmap_atomic(pg, KM_BOUNCE_READ)+to_addr[oldpg].sg->offset; 282 basep = kmap_atomic(pg, KM_BOUNCE_READ)+to_addr[oldpg].sg->offset;
278 283
279 /* We will just duplicate the second pixel at the packet */ 284 /* We will just duplicate the second pixel at the packet */
@@ -376,6 +381,8 @@ static void gen_line(struct sg_to_addr to_addr[],int inipos,int pages,int wmax,
376 381
377end: 382end:
378 kunmap_atomic(basep, KM_BOUNCE_READ); 383 kunmap_atomic(basep, KM_BOUNCE_READ);
384 spin_unlock_irqrestore(&spinlock,flags);
385
379} 386}
380static void vivi_fillbuff(struct vivi_dev *dev,struct vivi_buffer *buf) 387static void vivi_fillbuff(struct vivi_dev *dev,struct vivi_buffer *buf)
381{ 388{