Skip to content

Commit ffdeca8

Browse files
committed
[media] em28xx_dvb: only call the software filter if data
Several URBs will be simply not filled. Don't call the DVB core software filter for those empty URBs. Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
1 parent cd701c8 commit ffdeca8

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

‎drivers/media/usb/em28xx/em28xx-dvb.c‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -161,6 +161,8 @@ static inline int em28xx_dvb_urb_data_copy(struct em28xx *dev, struct urb *urb)
161161
if (urb->status != -EPROTO)
162162
continue;
163163
}
164+
if (!urb->actual_length)
165+
continue;
164166
dvb_dmx_swfilter(&dev->dvb->demux, urb->transfer_buffer,
165167
urb->actual_length);
166168
} else {
@@ -170,6 +172,8 @@ static inline int em28xx_dvb_urb_data_copy(struct em28xx *dev, struct urb *urb)
170172
if (urb->iso_frame_desc[i].status != -EPROTO)
171173
continue;
172174
}
175+
if (!urb->iso_frame_desc[i].actual_length)
176+
continue;
173177
dvb_dmx_swfilter(&dev->dvb->demux,
174178
urb->transfer_buffer +
175179
urb->iso_frame_desc[i].offset,

0 commit comments

Comments
 (0)