aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/media')
-rw-r--r--drivers/media/dvb/dvb-core/dvb_ca_en50221.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/media/dvb/dvb-core/dvb_ca_en50221.c b/drivers/media/dvb/dvb-core/dvb_ca_en50221.c
index 7ea517b7e186..9be65a3b931f 100644
--- a/drivers/media/dvb/dvb-core/dvb_ca_en50221.c
+++ b/drivers/media/dvb/dvb-core/dvb_ca_en50221.c
@@ -1306,6 +1306,10 @@ static ssize_t dvb_ca_en50221_io_write(struct file *file,
1306 /* fragment the packets & store in the buffer */ 1306 /* fragment the packets & store in the buffer */
1307 while (fragpos < count) { 1307 while (fragpos < count) {
1308 fraglen = ca->slot_info[slot].link_buf_size - 2; 1308 fraglen = ca->slot_info[slot].link_buf_size - 2;
1309 if (fraglen < 0)
1310 break;
1311 if (fraglen > HOST_LINK_BUF_SIZE - 2)
1312 fraglen = HOST_LINK_BUF_SIZE - 2;
1309 if ((count - fragpos) < fraglen) 1313 if ((count - fragpos) < fraglen)
1310 fraglen = count - fragpos; 1314 fraglen = count - fragpos;
1311 1315