On Tue, 2011-08-23 at 11:47 +1000, Jason Hecker wrote: > Damn, this patch didn't help so maybe forget this patch. Tuner A is > still messed up. Try this patch, applied to the latest media_build. it aligns buffer size to the max packet size instead of TS packet size. I think what might happening is that TS packets are getting chopped, as device seems to want to align to max packet size. Afatech seem to want create rather large buffers at considerable delay. The size of the buffer has also been considerably reduced. If you want to increase it change TS_USB20_PACKET_COUNT in multiplies of 2 (56 ... 112). --- drivers/media/dvb/dvb-usb/af9015.c | 13 +++++++------ 1 files changed, 7 insertions(+), 6 deletions(-) diff --git a/drivers/media/dvb/dvb-usb/af9015.c b/drivers/media/dvb/dvb-usb/af9015.c index d7ad05f..eaf0800 100644 --- a/drivers/media/dvb/dvb-usb/af9015.c +++ b/drivers/media/dvb/dvb-usb/af9015.c @@ -404,21 +404,22 @@ static int af9015_init_endpoint(struct dvb_usb_device *d) We use smaller - about 1/4 from the original, 5 and 87. */ #define TS_PACKET_SIZE 188 -#define TS_USB20_PACKET_COUNT 87 -#define TS_USB20_FRAME_SIZE (TS_PACKET_SIZE*TS_USB20_PACKET_COUNT) - #define TS_USB11_PACKET_COUNT 5 #define TS_USB11_FRAME_SIZE (TS_PACKET_SIZE*TS_USB11_PACKET_COUNT) -#define TS_USB20_MAX_PACKET_SIZE 512 +#define TS_USB20_MAX_PACKET_SIZE 128 #define TS_USB11_MAX_PACKET_SIZE 64 +#define TS_USB20_PACKET_COUNT 28 +#define TS_USB20_FRAME_SIZE (TS_USB20_MAX_PACKET_SIZE\ + *TS_USB20_PACKET_COUNT) + if (d->udev->speed == USB_SPEED_FULL) { frame_size = TS_USB11_FRAME_SIZE/4; packet_size = TS_USB11_MAX_PACKET_SIZE/4; } else { - frame_size = TS_USB20_FRAME_SIZE/4; - packet_size = TS_USB20_MAX_PACKET_SIZE/4; + frame_size = TS_USB20_FRAME_SIZE; + packet_size = TS_USB20_MAX_PACKET_SIZE; } ret = af9015_set_reg_bit(d, 0xd507, 2); /* assert EP4 reset */ -- 1.7.4.1 -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html