summaryrefslogtreecommitdiff
path: root/drivers/media/video/em28xx/em28xx-dvb.c
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@redhat.com>2011-07-28 15:42:00 -0300
committerMauro Carvalho Chehab <mchehab@redhat.com>2011-07-28 17:09:54 -0300
commitf7acc4bb86594d78aa41c07b7670df3e03738b18 (patch)
tree49c602a4b5224f0872903c02c4c30436ff4437e4 /drivers/media/video/em28xx/em28xx-dvb.c
parentcf845297d592339bcf0839298c4319633df3173a (diff)
[media] em28xx: Fix DVB-C maxsize for em2884
The logic at em28xx_isoc_dvb_max_packetsize() sucks, at least for newer the needed packet size. Yet, it is better than nothing. Rewrite the code in order to change the default to 752 for em2884 and newer chips and provide a better way to handle per-chipset specifics. For em2874, the current default should be enough, as the only em2874 board is currently a 1-seg ISDB-T board, so, it needs only a limited amount of bandwidth. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/em28xx/em28xx-dvb.c')
-rw-r--r--drivers/media/video/em28xx/em28xx-dvb.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/media/video/em28xx/em28xx-dvb.c b/drivers/media/video/em28xx/em28xx-dvb.c
index ab8a740bc68c..e5916dee4094 100644
--- a/drivers/media/video/em28xx/em28xx-dvb.c
+++ b/drivers/media/video/em28xx/em28xx-dvb.c
@@ -167,6 +167,11 @@ static int start_streaming(struct em28xx_dvb *dvb)
return rc;
max_dvb_packet_size = em28xx_isoc_dvb_max_packetsize(dev);
+ if (max_dvb_packet_size < 0)
+ return max_dvb_packet_size;
+ dprintk(1, "Using %d buffers each with %d bytes\n",
+ EM28XX_DVB_NUM_BUFS,
+ max_dvb_packet_size);
return em28xx_init_isoc(dev, EM28XX_DVB_MAX_PACKETS,
EM28XX_DVB_NUM_BUFS, max_dvb_packet_size,