diff options
-rw-r--r-- | drivers/media/video/cx18/cx18-dvb.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/media/video/cx18/cx18-dvb.c b/drivers/media/video/cx18/cx18-dvb.c index 0ad5b63d27fe..0ae2c2e1eab5 100644 --- a/drivers/media/video/cx18/cx18-dvb.c +++ b/drivers/media/video/cx18/cx18-dvb.c | |||
@@ -260,6 +260,7 @@ static int cx18_dvb_start_feed(struct dvb_demux_feed *feed) | |||
260 | mutex_lock(&stream->dvb.feedlock); | 260 | mutex_lock(&stream->dvb.feedlock); |
261 | if (stream->dvb.feeding++ == 0) { | 261 | if (stream->dvb.feeding++ == 0) { |
262 | CX18_DEBUG_INFO("Starting Transport DMA\n"); | 262 | CX18_DEBUG_INFO("Starting Transport DMA\n"); |
263 | mutex_lock(&cx->serialize_lock); | ||
263 | set_bit(CX18_F_S_STREAMING, &stream->s_flags); | 264 | set_bit(CX18_F_S_STREAMING, &stream->s_flags); |
264 | ret = cx18_start_v4l2_encode_stream(stream); | 265 | ret = cx18_start_v4l2_encode_stream(stream); |
265 | if (ret < 0) { | 266 | if (ret < 0) { |
@@ -268,6 +269,7 @@ static int cx18_dvb_start_feed(struct dvb_demux_feed *feed) | |||
268 | if (stream->dvb.feeding == 0) | 269 | if (stream->dvb.feeding == 0) |
269 | clear_bit(CX18_F_S_STREAMING, &stream->s_flags); | 270 | clear_bit(CX18_F_S_STREAMING, &stream->s_flags); |
270 | } | 271 | } |
272 | mutex_unlock(&cx->serialize_lock); | ||
271 | } else | 273 | } else |
272 | ret = 0; | 274 | ret = 0; |
273 | mutex_unlock(&stream->dvb.feedlock); | 275 | mutex_unlock(&stream->dvb.feedlock); |
@@ -291,7 +293,9 @@ static int cx18_dvb_stop_feed(struct dvb_demux_feed *feed) | |||
291 | mutex_lock(&stream->dvb.feedlock); | 293 | mutex_lock(&stream->dvb.feedlock); |
292 | if (--stream->dvb.feeding == 0) { | 294 | if (--stream->dvb.feeding == 0) { |
293 | CX18_DEBUG_INFO("Stopping Transport DMA\n"); | 295 | CX18_DEBUG_INFO("Stopping Transport DMA\n"); |
296 | mutex_lock(&cx->serialize_lock); | ||
294 | ret = cx18_stop_v4l2_encode_stream(stream, 0); | 297 | ret = cx18_stop_v4l2_encode_stream(stream, 0); |
298 | mutex_unlock(&cx->serialize_lock); | ||
295 | } else | 299 | } else |
296 | ret = 0; | 300 | ret = 0; |
297 | mutex_unlock(&stream->dvb.feedlock); | 301 | mutex_unlock(&stream->dvb.feedlock); |