提交 7ecff8c9 编写于 作者: S Stefan Ringel 提交者: Mauro Carvalho Chehab

[media] tm6000: all audio packets must swab

Signed-off-by: NStefan Ringel <stefan.ringel@arcor.de>
Signed-off-by: NMauro Carvalho Chehab <mchehab@redhat.com>
上级 f2e18dc1
......@@ -344,17 +344,14 @@ static int copy_streams(u8 *data, unsigned long len,
if (vbuf)
memcpy(&voutp[pos], ptr, cpysize);
break;
case TM6000_URB_MSG_AUDIO:
/* Need some code to copy audio buffer */
if (dev->fourcc == V4L2_PIX_FMT_YUYV) {
/* Swap word bytes */
int i;
case TM6000_URB_MSG_AUDIO: {
int i;
for (i = 0; i < cpysize; i += 2)
swab16s((u16 *)(ptr + i));
for (i = 0; i < cpysize; i += 2)
swab16s((u16 *)(ptr + i));
}
tm6000_call_fillbuf(dev, TM6000_AUDIO, ptr, cpysize);
break;
}
case TM6000_URB_MSG_VBI:
/* Need some code to copy vbi buffer */
break;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册