Skip to content

Commit

Permalink
V4L/DVB (5123): Buf_qbuf: fix: videobuf_queue->stream corruption and …
Browse files Browse the repository at this point in the history
…lockup

We are doing ->buf_prepare(buf) before adding buf to q->stream list. This
means that videobuf_qbuf() should not try to re-add a STATE_PREPARED buffer.

Signed-off-by: Oleg Nesterov <oleg@tv-sign.ru>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
  • Loading branch information
Oleg Nesterov authored and Mauro Carvalho Chehab committed Jan 24, 2007
1 parent 99ddcc7 commit 419dd83
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/media/video/video-buf.c
Original file line number Diff line number Diff line change
Expand Up @@ -700,6 +700,7 @@ videobuf_qbuf(struct videobuf_queue *q,
goto done;
}
if (buf->state == STATE_QUEUED ||
buf->state == STATE_PREPARED ||
buf->state == STATE_ACTIVE) {
dprintk(1,"qbuf: buffer is already queued or active.\n");
goto done;
Expand Down

0 comments on commit 419dd83

Please sign in to comment.