aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHans Verkuil <hverkuil-cisco@xs4all.nl>2019-01-16 13:34:12 +0100
committerHans Verkuil <hverkuil-cisco@xs4all.nl>2019-06-02 12:00:04 +0200
commite7a44ad8a380e9cf65a59320ad7dd0262822afd1 (patch)
tree033bc6355f9c8d4f0767f2ad1f25c96f2bcc4a4a
parentb6b6167f1cf49eb803b11f42485273f73a882258 (diff)
si470x: fix epoll
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
-rw-r--r--drivers/media/radio/si470x/radio-si470x-common.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/media/radio/si470x/radio-si470x-common.c b/drivers/media/radio/si470x/radio-si470x-common.c
index 1d7ab5462c77..138f27d285f6 100644
--- a/drivers/media/radio/si470x/radio-si470x-common.c
+++ b/drivers/media/radio/si470x/radio-si470x-common.c
@@ -528,13 +528,12 @@ static __poll_t si470x_fops_poll(struct file *file,
__poll_t req_events = poll_requested_events(pts);
__poll_t retval = v4l2_ctrl_poll(file, pts);
+ poll_wait(file, &radio->read_queue, pts);
if (req_events & (EPOLLIN | EPOLLRDNORM)) {
/* switch on rds reception */
if ((radio->registers[SYSCONFIG1] & SYSCONFIG1_RDS) == 0)
si470x_rds_on(radio);
- poll_wait(file, &radio->read_queue, pts);
-
if (radio->rd_index != radio->wr_index)
retval |= EPOLLIN | EPOLLRDNORM;
}

Privacy Policy