X-Git-Url: http://git.liburcu.org/?a=blobdiff_plain;f=lttng-abi.c;h=fb970a6926ce0eec2d61199f8dedc470ad9eab1f;hb=e18f5d234504092f97d801a9a3f46417fceb0a84;hp=3be91fcfaf48ade8c42bf228038e109184fafb45;hpb=2d70eed13e3c9a656eec50677940f8ef99eccabf;p=lttng-modules.git diff --git a/lttng-abi.c b/lttng-abi.c index 3be91fcf..fb970a69 100644 --- a/lttng-abi.c +++ b/lttng-abi.c @@ -34,8 +34,6 @@ #include #include #include -#include -#include #include #include #include @@ -80,7 +78,7 @@ int lttng_abi_create_session(void) session = lttng_session_create(); if (!session) return -ENOMEM; - session_fd = lttng_get_unused_fd(); + session_fd = get_unused_fd_flags(0); if (session_fd < 0) { ret = session_fd; goto fd_error; @@ -109,7 +107,7 @@ int lttng_abi_tracepoint_list(void) struct file *tracepoint_list_file; int file_fd, ret; - file_fd = lttng_get_unused_fd(); + file_fd = get_unused_fd_flags(0); if (file_fd < 0) { ret = file_fd; goto fd_error; @@ -149,7 +147,7 @@ int lttng_abi_syscall_list(void) struct file *syscall_list_file; int file_fd, ret; - file_fd = lttng_get_unused_fd(); + file_fd = get_unused_fd_flags(0); if (file_fd < 0) { ret = file_fd; goto fd_error; @@ -426,7 +424,7 @@ int lttng_abi_create_channel(struct file *session_file, int chan_fd; int ret = 0; - chan_fd = lttng_get_unused_fd(); + chan_fd = get_unused_fd_flags(0); if (chan_fd < 0) { ret = chan_fd; goto fd_error; @@ -777,7 +775,6 @@ unsigned int lttng_metadata_ring_buffer_poll(struct file *filp, unsigned int mask = 0; if (filp->f_mode & FMODE_READ) { - poll_wait_set_exclusive(wait); poll_wait(filp, &stream->read_wait, wait); finalized = stream->finalized; @@ -1085,7 +1082,7 @@ int lttng_abi_create_stream_fd(struct file *channel_file, void *stream_priv, int stream_fd, ret; struct file *stream_file; - stream_fd = lttng_get_unused_fd(); + stream_fd = get_unused_fd_flags(0); if (stream_fd < 0) { ret = stream_fd; goto fd_error; @@ -1221,7 +1218,7 @@ int lttng_abi_create_event(struct file *channel_file, default: break; } - event_fd = lttng_get_unused_fd(); + event_fd = get_unused_fd_flags(0); if (event_fd < 0) { ret = event_fd; goto fd_error; @@ -1505,7 +1502,6 @@ unsigned int lttng_channel_poll(struct file *file, poll_table *wait) unsigned int mask = 0; if (file->f_mode & FMODE_READ) { - poll_wait_set_exclusive(wait); poll_wait(file, channel->ops->get_hp_wait_queue(channel->chan), wait);