Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit af2c5deb authored by Hans Verkuil's avatar Hans Verkuil Committed by Mauro Carvalho Chehab
Browse files

[media] saa6588: after calling CMD_CLOSE, CMD_POLL is broken



CMD_CLOSE sets data_available_for_read to 1, which is necessary to do the
wakeup call, but it is never reset to 0.

Because of this calling CMD_POLL afterwards will always return that data is
available, even if there isn't any.

Signed-off-by: default avatarHans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: default avatarMauro Carvalho Chehab <m.chehab@samsung.com>
parent a9fe3bee
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -402,6 +402,7 @@ static long saa6588_ioctl(struct v4l2_subdev *sd, unsigned int cmd, void *arg)
	case SAA6588_CMD_CLOSE:
		s->data_available_for_read = 1;
		wake_up_interruptible(&s->read_queue);
		s->data_available_for_read = 0;
		a->result = 0;
		break;
		/* --- read() for /dev/radio --- */