summaryrefslogtreecommitdiff
path: root/drivers/iio/kfifo_buf.c
diff options
context:
space:
mode:
authorLars-Peter Clausen <lars@metafoo.de>2013-09-15 19:31:00 +0400
committerJonathan Cameron <jic23@kernel.org>2013-09-15 20:39:04 +0400
commit623c334c1a40ae84a19ab8ef77924e9f0f2d4bcd (patch)
treefaa222f6ab4733ad5fd0f538dbe6d9e541da27bf /drivers/iio/kfifo_buf.c
parent705ee2c98a37130fd0aa914dc55b74a9174a6ff0 (diff)
downloadlinux-623c334c1a40ae84a19ab8ef77924e9f0f2d4bcd.tar.xz
iio:kfifo_buf: Use wake_up_interruptible_poll()
Use wake_up_interruptible_poll() instead of wake_up_interruptible() to only wake up those threads that listen for input poll notifications. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
Diffstat (limited to 'drivers/iio/kfifo_buf.c')
-rw-r--r--drivers/iio/kfifo_buf.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/iio/kfifo_buf.c b/drivers/iio/kfifo_buf.c
index a923c78d5cb4..1bea41bcbdc6 100644
--- a/drivers/iio/kfifo_buf.c
+++ b/drivers/iio/kfifo_buf.c
@@ -7,6 +7,7 @@
#include <linux/mutex.h>
#include <linux/iio/kfifo_buf.h>
#include <linux/sched.h>
+#include <linux/poll.h>
struct iio_kfifo {
struct iio_buffer buffer;
@@ -102,7 +103,7 @@ static int iio_store_to_kfifo(struct iio_buffer *r,
if (ret != 1)
return -EBUSY;
r->stufftoread = true;
- wake_up_interruptible(&r->pollq);
+ wake_up_interruptible_poll(&r->pollq, POLLIN | POLLRDNORM);
return 0;
}