linux-media.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/4] tm6000: bugfix incorrect size
@ 2010-05-19 16:58 stefan.ringel
  2010-05-19 16:58 ` [PATCH 2/4] tm6000: add vbi message stefan.ringel
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: stefan.ringel @ 2010-05-19 16:58 UTC (permalink / raw)
  To: linux-media; +Cc: mchehab, d.belimov, Stefan Ringel

From: Stefan Ringel <stefan.ringel@arcor.de>

Signed-off-by: Stefan Ringel <stefan.ringel@arcor.de>
---
 drivers/staging/tm6000/tm6000-video.c |    6 +++++-
 1 files changed, 5 insertions(+), 1 deletions(-)

diff --git a/drivers/staging/tm6000/tm6000-video.c b/drivers/staging/tm6000/tm6000-video.c
index 9554472..e5f8b57 100644
--- a/drivers/staging/tm6000/tm6000-video.c
+++ b/drivers/staging/tm6000/tm6000-video.c
@@ -205,7 +205,11 @@ static int copy_packet(struct urb *urb, u32 header, u8 **ptr, u8 *endp,
 		c = (header >> 24) & 0xff;
 
 		/* split the header fields */
-		size  = (((header & 0x7e) << 1) -1) *4;
+		size  = ((header & 0x7e) << 1);
+
+		if (size > 0)
+			size -= 4;
+
 		block = (header >> 7) & 0xf;
 		field = (header >> 11) & 0x1;
 		line  = (header >> 12) & 0x1ff;
-- 
1.7.0.3


^ permalink raw reply related	[flat|nested] 7+ messages in thread
* Re: [PATCH 3/4] tm6000: bugfix video image
@ 2010-05-27 14:43 Luis Henrique Fagundes
  2010-05-27 15:07 ` Stefan Ringel
  2010-05-27 15:44 ` Stefan Ringel
  0 siblings, 2 replies; 7+ messages in thread
From: Luis Henrique Fagundes @ 2010-05-27 14:43 UTC (permalink / raw)
  To: Linux Media Mailing List, Dmitri Belimov, Mauro Carvalho Chehab,
	Bee Hock Goh, Stefan Ringel

[-- Attachment #1: Type: text/plain, Size: 156 bytes --]

Hi Stefan,

Looks like your patch sent on May 19th doesn't compile. I might be
missing something, but I needed the attached patch to make it compile.

Luis

[-- Attachment #2: patch3-fix-bugfix_video_image.patch --]
[-- Type: text/x-patch, Size: 798 bytes --]

--- a/drivers/staging/tm6000/tm6000-video.c	2010-05-26 09:13:19.000000000 -0300
+++ b/drivers/staging/tm6000/tm6000-video.c	2010-05-26 09:12:29.000000000 -0300
@@ -423,7 +423,7 @@
 					jiffies);
 			return rc;
 		}
+		if (!buf)
-		if (!*buf)
 			return 0;
 	}
 
@@ -452,7 +452,7 @@
 	while (len>0) {
 		cpysize=min(len,buf->vb.size-pos);
 		//printk("Copying %d bytes (max=%lu) from %p to %p[%u]\n",cpysize,(*buf)->vb.size,ptr,out_p,pos);
-		memcpy(&out_p[pos], ptr, cpysize);
+		memcpy(&outp[pos], ptr, cpysize);
 		pos+=cpysize;
 		ptr+=cpysize;
 		len-=cpysize;
@@ -464,8 +464,8 @@
 			get_next_buf (dma_q, &buf);
 			if (!buf)
 				break;
-			out_p = videobuf_to_vmalloc(&(buf->vb));
-			if (!out_p)
+			outp = videobuf_to_vmalloc(&(buf->vb));
+			if (!outp)
 				return rc;
 			pos = 0;
 		}

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2010-05-27 15:46 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-05-19 16:58 [PATCH 1/4] tm6000: bugfix incorrect size stefan.ringel
2010-05-19 16:58 ` [PATCH 2/4] tm6000: add vbi message stefan.ringel
2010-05-19 16:58 ` [PATCH 3/4] tm6000: bugfix video image stefan.ringel
2010-05-19 16:58 ` [PATCH 4/4] tm6000: bugfix stabilizing urb data stefan.ringel
  -- strict thread matches above, loose matches on Subject: below --
2010-05-27 14:43 [PATCH 3/4] tm6000: bugfix video image Luis Henrique Fagundes
2010-05-27 15:07 ` Stefan Ringel
2010-05-27 15:44 ` Stefan Ringel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).