From: Hans Verkuil Date: Tue, 22 Apr 2008 17:45:48 +0000 (-0300) Subject: V4L/DVB (7337): ivtv: fix polling bug X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=0358d7c580370c5eaf081ac42a41c6e347709051;p=linux-beck.git V4L/DVB (7337): ivtv: fix polling bug The q_io queue was never taken into account by the poll function. Thanks to Andy Walls for finding this bug. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab --- diff --git a/drivers/media/video/ivtv/ivtv-fileops.c b/drivers/media/video/ivtv/ivtv-fileops.c index 6fb96f19a866..d949a81339d5 100644 --- a/drivers/media/video/ivtv/ivtv-fileops.c +++ b/drivers/media/video/ivtv/ivtv-fileops.c @@ -753,7 +753,7 @@ unsigned int ivtv_v4l2_enc_poll(struct file *filp, poll_table * wait) IVTV_DEBUG_HI_FILE("Encoder poll\n"); poll_wait(filp, &s->waitq, wait); - if (eof || s->q_full.length) + if (eof || s->q_full.length || s->q_io.length) return POLLIN | POLLRDNORM; return 0; }