diff options
author | Mauro Carvalho Chehab <mchehab+samsung@kernel.org> | 2018-08-07 15:25:37 +0200 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab+samsung@kernel.org> | 2018-08-08 16:57:14 +0200 |
commit | dcefa533bd97922a3cac37f395247082be44600b (patch) | |
tree | 71ae0be69354c4a94e0d0f7a619aeb8722df56ee /drivers/media | |
parent | media: s3c-camif: fix return code for the polling routine (diff) | |
download | linux-dcefa533bd97922a3cac37f395247082be44600b.tar.xz linux-dcefa533bd97922a3cac37f395247082be44600b.zip |
media: radio-wl1273: fix return code for the polling routine
All poll handlers should return a poll flag, and not error codes. So,
instead of returning an error, do the right thing here,
e. g. to return EPOLERR on errors, just like the V4L2 VB2 code.
Solves the following sparse warning:
drivers/media/radio/radio-wl1273.c:1099:24: warning: incorrect type in return expression (different base types)
drivers/media/radio/radio-wl1273.c:1099:24: expected restricted __poll_t
drivers/media/radio/radio-wl1273.c:1099:24: got int
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
Diffstat (limited to 'drivers/media')
-rw-r--r-- | drivers/media/radio/radio-wl1273.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/media/radio/radio-wl1273.c b/drivers/media/radio/radio-wl1273.c index 8f9f8dfc3497..11aa94f189cb 100644 --- a/drivers/media/radio/radio-wl1273.c +++ b/drivers/media/radio/radio-wl1273.c @@ -1096,7 +1096,7 @@ static __poll_t wl1273_fm_fops_poll(struct file *file, struct wl1273_core *core = radio->core; if (radio->owner && radio->owner != file) - return -EBUSY; + return EPOLLERR; radio->owner = file; |