提交 7c60fc0e 编写于 作者: J Jiri Olsa 提交者: Ingo Molnar

perf: Use POLLIN instead of POLL_IN for perf poll data in flag

Currently we flag available data (via poll syscall) on perf fd with
POLL_IN macro, which is normally used for SIGIO interface.

We've been lucky, because POLLIN (0x1) is subset of POLL_IN (0x20001)
and sys_poll (do_pollfd function) cut the extra bit out (0x20000).
Signed-off-by: NJiri Olsa <jolsa@kernel.org>
Signed-off-by: NPeter Zijlstra (Intel) <peterz@infradead.org>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Stephane Eranian <eranian@google.com>
Cc: Arnaldo Carvalho de Melo <acme@kernel.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Link: http://lkml.kernel.org/r/1422467678-22341-1-git-send-email-jolsa@kernel.orgSigned-off-by: NIngo Molnar <mingo@kernel.org>
上级 a83fe28e
...@@ -13,12 +13,13 @@ ...@@ -13,12 +13,13 @@
#include <linux/vmalloc.h> #include <linux/vmalloc.h>
#include <linux/slab.h> #include <linux/slab.h>
#include <linux/circ_buf.h> #include <linux/circ_buf.h>
#include <linux/poll.h>
#include "internal.h" #include "internal.h"
static void perf_output_wakeup(struct perf_output_handle *handle) static void perf_output_wakeup(struct perf_output_handle *handle)
{ {
atomic_set(&handle->rb->poll, POLL_IN); atomic_set(&handle->rb->poll, POLLIN);
handle->event->pending_wakeup = 1; handle->event->pending_wakeup = 1;
irq_work_queue(&handle->event->pending); irq_work_queue(&handle->event->pending);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册