V4L/DVB: tm6000: bugfix image position
bugfix incorrect image and line position in videobuffer Signed-off-by: Stefan Ringel <stefan.ringel@arcor.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
This commit is contained in:
committed by
Mauro Carvalho Chehab
parent
083e472176
commit
3c7c5e9e89
@@ -225,8 +225,8 @@ static int copy_packet(struct urb *urb, u32 header, u8 **ptr, u8 *endp,
|
|||||||
* It should, instead, check if the user selected
|
* It should, instead, check if the user selected
|
||||||
* entrelaced or non-entrelaced mode
|
* entrelaced or non-entrelaced mode
|
||||||
*/
|
*/
|
||||||
pos= ((line<<1)+field)*linewidth +
|
pos = ((line << 1) - field - 1) * linewidth +
|
||||||
block*TM6000_URB_MSG_LEN;
|
block * TM6000_URB_MSG_LEN;
|
||||||
|
|
||||||
/* Don't allow to write out of the buffer */
|
/* Don't allow to write out of the buffer */
|
||||||
if (pos+TM6000_URB_MSG_LEN > (*buf)->vb.size) {
|
if (pos+TM6000_URB_MSG_LEN > (*buf)->vb.size) {
|
||||||
|
Reference in New Issue
Block a user