Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 261379
b: refs/heads/master
c: 5138870
h: refs/heads/master
i:
  261377: 6a2d84f
  261375: bfd474e
v: v3
  • Loading branch information
Hans Verkuil authored and Mauro Carvalho Chehab committed Jul 27, 2011
1 parent 7c302b5 commit dbaf16c
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: c7a52f8dced9ee325b8e3a16a5ac07d191fc3d9b
refs/heads/master: 5138870d68ffbf6fcdf019af5b2ce78bc5a1f837
11 changes: 8 additions & 3 deletions trunk/drivers/media/video/ivtv/ivtv-fileops.c
Original file line number Diff line number Diff line change
Expand Up @@ -750,6 +750,7 @@ unsigned int ivtv_v4l2_enc_poll(struct file *filp, poll_table * wait)
struct ivtv *itv = id->itv;
struct ivtv_stream *s = &itv->streams[id->type];
int eof = test_bit(IVTV_F_S_STREAMOFF, &s->s_flags);
unsigned res = 0;

/* Start a capture if there is none */
if (!eof && !test_bit(IVTV_F_S_STREAMING, &s->s_flags)) {
Expand All @@ -769,12 +770,16 @@ unsigned int ivtv_v4l2_enc_poll(struct file *filp, poll_table * wait)
/* add stream's waitq to the poll list */
IVTV_DEBUG_HI_FILE("Encoder poll\n");
poll_wait(filp, &s->waitq, wait);
if (v4l2_event_pending(&id->fh))
res |= POLLPRI;
else
poll_wait(filp, &id->fh.events->wait, wait);

if (s->q_full.length || s->q_io.length)
return POLLIN | POLLRDNORM;
return res | POLLIN | POLLRDNORM;
if (eof)
return POLLHUP;
return 0;
return res | POLLHUP;
return res;
}

void ivtv_stop_capture(struct ivtv_open_id *id, int gop_end)
Expand Down
2 changes: 2 additions & 0 deletions trunk/drivers/media/video/ivtv/ivtv-ioctl.c
Original file line number Diff line number Diff line change
Expand Up @@ -1451,6 +1451,8 @@ static int ivtv_subscribe_event(struct v4l2_fh *fh, struct v4l2_event_subscripti
case V4L2_EVENT_VSYNC:
case V4L2_EVENT_EOS:
break;
case V4L2_EVENT_CTRL:
return v4l2_ctrl_subscribe_fh(fh, sub, 0);
default:
return -EINVAL;
}
Expand Down

0 comments on commit dbaf16c

Please sign in to comment.