Remove fcntl wrapper
authorMichael Jeanson <mjeanson@efficios.com>
Tue, 17 Jan 2023 22:49:42 +0000 (17:49 -0500)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Mon, 17 Apr 2023 20:21:24 +0000 (16:21 -0400)
Replace the questionnable sync_file_range wrapper by more descriptive
util functions. Remove the unimplemented splice wrapper, I'd rather have
a build failure / adjust the build system on some platforms than have
hard to diagnose runtime issues.

Change-Id: I4114d0d9765ae3d95a1488c945e5d66a20c2029d
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
24 files changed:
src/bin/lttng-sessiond/agent-thread.cpp
src/bin/lttng-sessiond/client.cpp
src/bin/lttng-sessiond/health.cpp
src/bin/lttng-sessiond/manage-apps.cpp
src/bin/lttng-sessiond/manage-consumer.cpp
src/bin/lttng-sessiond/manage-kernel.cpp
src/bin/lttng-sessiond/notify-apps.cpp
src/bin/lttng-sessiond/register.cpp
src/bin/lttng-sessiond/rotation-thread.cpp
src/bin/lttng-sessiond/save.cpp
src/bin/lttng-sessiond/thread-utils.cpp
src/common/Makefile.am
src/common/compat/compat-fcntl.cpp [deleted file]
src/common/compat/fcntl.hpp [deleted file]
src/common/compat/poll.hpp
src/common/consumer/consumer-stream.cpp
src/common/consumer/consumer.cpp
src/common/consumer/consumer.hpp
src/common/io-hint.cpp [new file with mode: 0644]
src/common/io-hint.hpp [new file with mode: 0644]
src/common/kernel-consumer/kernel-consumer.cpp
src/common/ust-consumer/ust-consumer.cpp
tests/unit/test_payload.cpp
tests/unit/test_unix_socket.cpp

index f641ed78e12aecf0b16a67680b1ac54f0dc3ded2..23a26a8063b777a64a03f1892a6e61d66dc9fd6f 100644 (file)
@@ -22,6 +22,8 @@
 #include <common/uri.hpp>
 #include <common/utils.hpp>
 
+#include <fcntl.h>
+
 namespace {
 struct thread_notifiers {
        struct lttng_pipe *quit_pipe;
index 6c3f696f01cc3fb12ba246116c7f9beb692850fa..d6d894cfbeced044cc463a43be08e9271af29a34 100644 (file)
@@ -40,6 +40,7 @@
 #include <lttng/session-internal.hpp>
 #include <lttng/userspace-probe-internal.hpp>
 
+#include <fcntl.h>
 #include <pthread.h>
 #include <signal.h>
 #include <stddef.h>
index dd3d9426d3f1eb6fec96713aa3462f9d1a7f54eb..4aa4275629e0d92fea6014c3ad5f304bcb9ed075 100644 (file)
@@ -16,6 +16,7 @@
 #include <common/pipe.hpp>
 #include <common/utils.hpp>
 
+#include <fcntl.h>
 #include <inttypes.h>
 #include <sys/stat.h>
 
index 27fa6ce85e0e47afd522698c7ebe067f8250ff17..68e70676aa1daf0ff0a7340907891f6d9bd02a65 100644 (file)
@@ -13,6 +13,8 @@
 #include "thread.hpp"
 #include "utils.hpp"
 
+#include <fcntl.h>
+
 namespace {
 struct thread_notifiers {
        struct lttng_pipe *quit_pipe;
index e1d67f5bb0e3126cf9fc0ea61a3fb8931e56fa82..b7eb10800fcaf2e21dd42e7de661a7568dc5597e 100644 (file)
@@ -17,6 +17,7 @@
 #include <common/pipe.hpp>
 #include <common/utils.hpp>
 
+#include <fcntl.h>
 #include <signal.h>
 
 namespace {
index 74bcb1322e868284b788e2c4d279f0481b03a6d8..fe7f21c6fe36774c19a015239baabd3eb7882af4 100644 (file)
@@ -19,6 +19,8 @@
 #include <common/urcu.hpp>
 #include <common/utils.hpp>
 
+#include <fcntl.h>
+
 namespace {
 struct thread_notifiers {
        struct lttng_pipe *quit_pipe;
index a73e9df5837cb0723b4190ce0fd1f50a025b3b5c..03ac5866c83d562289c948c219d36a72d49a2f75 100644 (file)
@@ -18,6 +18,8 @@
 #include <common/common.hpp>
 #include <common/utils.hpp>
 
+#include <fcntl.h>
+
 namespace {
 struct thread_notifiers {
        struct lttng_pipe *quit_pipe;
index 3740b380acddf6039ffa2cc13bf49da4d0e7ac16..0191adc9420f04cc0c96943e3477f4a945f51b14 100644 (file)
@@ -20,6 +20,7 @@
 #include <common/shm.hpp>
 #include <common/utils.hpp>
 
+#include <fcntl.h>
 #include <stddef.h>
 #include <stdlib.h>
 #include <sys/stat.h>
index 1f82176f8bd33464117ce3eb05f43c8a42b2ef51..9c92f66abaa1a7d1cb30aaff9f9f59ca845e46b1 100644 (file)
@@ -44,6 +44,7 @@
 #include <lttng/rotate-internal.hpp>
 #include <lttng/trigger/trigger.h>
 
+#include <fcntl.h>
 #include <inttypes.h>
 #include <memory>
 #include <signal.h>
index e8205bf7f1ff76e7aff37f84c25649948539d19e..b4ca4c080fdd8f119a98a2fe31682be6d9cec42e 100644 (file)
@@ -22,6 +22,7 @@
 
 #include <lttng/save-internal.hpp>
 
+#include <fcntl.h>
 #include <inttypes.h>
 #include <string.h>
 #include <unistd.h>
index 3231d8acf859182d3dfcfb27b252b2f71509b344..c861e0f52e65bd76e5962742475e81f64003681f 100644 (file)
@@ -12,6 +12,7 @@
 
 #include <common/utils.hpp>
 
+#include <fcntl.h>
 #include <pthread.h>
 
 /*
index 5e5f6d5e79985d8da98a98432016118ae7beebac..e04b38347d47fb60a6ab8e7bb0563bdd07c55099 100644 (file)
@@ -89,6 +89,8 @@ libcommon_lgpl_la_SOURCES = \
        file-descriptor.hpp file-descriptor.cpp \
        fd-handle.cpp fd-handle.hpp\
        format.hpp \
+       io-hint.cpp \
+       io-hint.hpp \
        kernel-probe.cpp \
        location.cpp \
        locked-reference.hpp \
@@ -169,13 +171,11 @@ libcommon_gpl_la_LIBADD = \
 # libcompat
 noinst_LTLIBRARIES += libcompat.la
 libcompat_la_SOURCES = \
-        compat/compat-fcntl.cpp \
         compat/directory-handle.cpp \
         compat/directory-handle.hpp \
         compat/dirent.hpp \
         compat/endian.hpp \
         compat/errno.hpp \
-        compat/fcntl.hpp \
         compat/getenv.hpp \
         compat/mman.hpp \
         compat/netdb.hpp \
diff --git a/src/common/compat/compat-fcntl.cpp b/src/common/compat/compat-fcntl.cpp
deleted file mode 100644 (file)
index 18b6fa3..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * Copyright (C) 2011 David Goulet <dgoulet@efficios.com>
- *
- * SPDX-License-Identifier: LGPL-2.1-only
- *
- */
-
-#define _LGPL_SOURCE
-#include <common/compat/fcntl.hpp>
-#include <common/macros.hpp>
-
-#include <unistd.h>
-
-#ifdef __linux__
-
-int compat_sync_file_range(int fd, off_t offset, off_t nbytes, unsigned int flags)
-{
-#ifdef HAVE_SYNC_FILE_RANGE
-       return sync_file_range(fd, offset, nbytes, flags);
-#else
-       return fdatasync(fd);
-#endif
-}
-
-#endif /* __linux__ */
diff --git a/src/common/compat/fcntl.hpp b/src/common/compat/fcntl.hpp
deleted file mode 100644 (file)
index ba8f05a..0000000
+++ /dev/null
@@ -1,72 +0,0 @@
-/*
- * Copyright (C) 2011 David Goulet <dgoulet@efficios.com>
- *
- * SPDX-License-Identifier: LGPL-2.1-only
- *
- */
-
-#ifndef _COMPAT_FCNTL_H
-#define _COMPAT_FCNTL_H
-
-#include <common/compat/errno.hpp>
-
-#include <fcntl.h>
-#include <sys/types.h>
-
-static_assert(sizeof(off_t) == sizeof(int64_t),
-             "Build system is misconfigured, off_t must be 64-bit wide");
-
-#if (defined(__FreeBSD__) || defined(__sun__))
-typedef off64_t loff_t;
-#endif
-
-#ifdef __linux__
-extern int compat_sync_file_range(int fd, off_t offset, off_t nbytes, unsigned int flags);
-#define lttng_sync_file_range(fd, offset, nbytes, flags) \
-       compat_sync_file_range(fd, offset, nbytes, flags)
-
-#endif /* __linux__ */
-
-#if (defined(__FreeBSD__) || defined(__CYGWIN__) || defined(__sun__))
-/*
- * Possible flags under Linux. Simply nullify them and avoid wrapper.
- */
-#define SYNC_FILE_RANGE_WAIT_AFTER  0
-#define SYNC_FILE_RANGE_WAIT_BEFORE 0
-#define SYNC_FILE_RANGE_WRITE      0
-
-static inline int lttng_sync_file_range(int fd __attribute__((unused)),
-                                       off_t offset __attribute__((unused)),
-                                       off_t nbytes __attribute__((unused)),
-                                       unsigned int flags __attribute__((unused)))
-{
-       return -ENOSYS;
-}
-#endif
-
-#if (defined(__FreeBSD__) || defined(__CYGWIN__) || defined(__sun__))
-/*
- * Possible flags under Linux. Simply nullify them and avoid wrappers.
- */
-#define SPLICE_F_MOVE    0
-#define SPLICE_F_NONBLOCK 0
-#define SPLICE_F_MORE    0
-#define SPLICE_F_GIFT    0
-
-static inline ssize_t splice(int fd_in __attribute__((unused)),
-                            loff_t *off_in __attribute__((unused)),
-                            int fd_out __attribute__((unused)),
-                            loff_t *off_out __attribute__((unused)),
-                            size_t len __attribute__((unused)),
-                            unsigned int flags __attribute__((unused)))
-{
-       return -ENOSYS;
-}
-#endif
-
-#if !(defined(__linux__) || defined(__FreeBSD__) || defined(__CYGWIN__) || defined(__sun__) || \
-      defined(__APPLE__))
-#error "Please add support for your OS."
-#endif /* __linux__ , __FreeBSD__, __CYGWIN__, __sun__, __APPLE__ */
-
-#endif /* _COMPAT_FCNTL_H */
index bfb3da82be7dc8459d8c8b8f459682ad93131757..da339110622bca7a1f1c1f56271121ea105f5ad3 100644 (file)
@@ -25,7 +25,6 @@ static inline void __lttng_poll_free(void *events)
  * epoll(7) implementation.
  */
 #ifdef HAVE_EPOLL
-#include <common/compat/fcntl.hpp>
 
 #include <features.h>
 #include <stdio.h>
index ab9b39111a02580bd176baac55b7c3b95379d123..0742c865296bad5754c074afb88a6ef08eea8a20 100644 (file)
@@ -23,6 +23,7 @@
 #include <common/ust-consumer/ust-consumer.hpp>
 #include <common/utils.hpp>
 
+#include <fcntl.h>
 #include <inttypes.h>
 #include <sys/mman.h>
 #include <unistd.h>
index 5f3dc4e621ad303a3b605e134182ee8177448877..01845871b91a2a2423e4375e983de1cac6243b7f 100644 (file)
@@ -20,6 +20,7 @@
 #include <common/dynamic-array.hpp>
 #include <common/index/ctf-index.hpp>
 #include <common/index/index.hpp>
+#include <common/io-hint.hpp>
 #include <common/kernel-consumer/kernel-consumer.hpp>
 #include <common/kernel-ctl/kernel-ctl.hpp>
 #include <common/relayd/relayd.hpp>
@@ -34,6 +35,7 @@
 #include <common/utils.hpp>
 
 #include <bin/lttng-consumerd/health-consumerd.hpp>
+#include <fcntl.h>
 #include <inttypes.h>
 #include <poll.h>
 #include <pthread.h>
@@ -1336,7 +1338,6 @@ void lttng_consumer_should_exit(struct lttng_consumer_local_data *ctx)
  */
 static void lttng_consumer_sync_trace_file(struct lttng_consumer_stream *stream, off_t orig_offset)
 {
-       int ret;
        int outfd = stream->out_fd;
 
        /*
@@ -1348,31 +1349,8 @@ static void lttng_consumer_sync_trace_file(struct lttng_consumer_stream *stream,
        if (orig_offset < stream->max_sb_size) {
                return;
        }
-       lttng_sync_file_range(outfd,
-                             orig_offset - stream->max_sb_size,
-                             stream->max_sb_size,
-                             SYNC_FILE_RANGE_WAIT_BEFORE | SYNC_FILE_RANGE_WRITE |
-                                     SYNC_FILE_RANGE_WAIT_AFTER);
-       /*
-        * Give hints to the kernel about how we access the file:
-        * POSIX_FADV_DONTNEED : we won't re-access data in a near future after
-        * we write it.
-        *
-        * We need to call fadvise again after the file grows because the
-        * kernel does not seem to apply fadvise to non-existing parts of the
-        * file.
-        *
-        * Call fadvise _after_ having waited for the page writeback to
-        * complete because the dirty page writeback semantic is not well
-        * defined. So it can be expected to lead to lower throughput in
-        * streaming.
-        */
-       ret = posix_fadvise(
-               outfd, orig_offset - stream->max_sb_size, stream->max_sb_size, POSIX_FADV_DONTNEED);
-       if (ret && ret != -ENOSYS) {
-               errno = ret;
-               PERROR("posix_fadvise on fd %i", outfd);
-       }
+       lttng::io::hint_flush_range_dont_need_sync(
+               outfd, orig_offset - stream->max_sb_size, stream->max_sb_size);
 }
 
 /*
@@ -1733,8 +1711,7 @@ ssize_t lttng_consumer_on_read_subbuffer_mmap(struct lttng_consumer_stream *stre
        /* This call is useless on a socket so better save a syscall. */
        if (!relayd) {
                /* This won't block, but will start writeout asynchronously */
-               lttng_sync_file_range(
-                       outfd, stream->out_fd_offset, write_len, SYNC_FILE_RANGE_WRITE);
+               lttng::io::hint_flush_range_async(outfd, stream->out_fd_offset, write_len);
                stream->out_fd_offset += write_len;
                lttng_consumer_sync_trace_file(stream, orig_offset);
        }
@@ -1933,8 +1910,7 @@ ssize_t lttng_consumer_on_read_subbuffer_splice(struct lttng_consumer_local_data
                /* This call is useless on a socket so better save a syscall. */
                if (!relayd) {
                        /* This won't block, but will start writeout asynchronously */
-                       lttng_sync_file_range(
-                               outfd, stream->out_fd_offset, ret_splice, SYNC_FILE_RANGE_WRITE);
+                       lttng::io::hint_flush_range_async(outfd, stream->out_fd_offset, ret_splice);
                        stream->out_fd_offset += ret_splice;
                }
                stream->output_written += ret_splice;
index 1efbc4eeeec33e6a57ebeb9748cf3d51f2e28907..053744904c7c7907dadae920520f6f46cc9b0d0d 100644 (file)
@@ -12,7 +12,6 @@
 #define LIB_CONSUMER_H
 
 #include <common/buffer-view.hpp>
-#include <common/compat/fcntl.hpp>
 #include <common/credentials.hpp>
 #include <common/dynamic-array.hpp>
 #include <common/hashtable/hashtable.hpp>
diff --git a/src/common/io-hint.cpp b/src/common/io-hint.cpp
new file mode 100644 (file)
index 0000000..506f15d
--- /dev/null
@@ -0,0 +1,165 @@
+/*
+ * Copyright (C) 2023 Michael Jeanson <mjeanson@efficios.com>
+ *
+ * SPDX-License-Identifier: LGPL-2.1-only
+ *
+ */
+
+#include <common/error.hpp>
+#include <common/io-hint.hpp>
+#include <common/scope-exit.hpp>
+
+#include <cinttypes>
+#include <fcntl.h>
+#include <sys/mman.h>
+#include <unistd.h>
+
+/*
+ * Use sync_file_range when available.
+ */
+#ifdef HAVE_SYNC_FILE_RANGE
+
+#include <fcntl.h>
+
+namespace {
+int flush_range(int fd, off_t offset, off_t nbytes, unsigned int flags)
+{
+       int ret;
+
+       ret = sync_file_range(fd, offset, nbytes, flags);
+       if (ret) {
+               PERROR("Failed to sync file range: fd=%i, offset=%" PRIu64 ", nbytes=%" PRIu64
+                      ", flags=%i",
+                      fd,
+                      static_cast<uint64_t>(offset),
+                      static_cast<uint64_t>(nbytes),
+                      flags);
+       }
+
+       return ret;
+}
+
+int flush_range_sync(int fd, off_t offset, off_t nbytes)
+{
+       return flush_range(fd,
+                          offset,
+                          nbytes,
+                          SYNC_FILE_RANGE_WAIT_BEFORE | SYNC_FILE_RANGE_WRITE |
+                                  SYNC_FILE_RANGE_WAIT_AFTER);
+}
+
+int flush_range_async(int fd, off_t offset, off_t nbytes)
+{
+       return flush_range(fd, offset, nbytes, SYNC_FILE_RANGE_WRITE);
+}
+} /* namespace */
+
+#else
+
+namespace {
+/*
+ * Use a memory mapping with msync() to emulate sync_file_range().
+ */
+int flush_range(int fd, off_t offset, off_t nbytes, int flags)
+{
+       void *mapped_region = mmap(NULL, nbytes, PROT_READ | PROT_WRITE, MAP_SHARED, fd, offset);
+       if (mapped_region == MAP_FAILED) {
+               PERROR("Failed to mmap region to flush range: fd=%i, offset=%" PRIu64
+                      ", nbytes=%" PRIu64 ", flags=%i",
+                      fd,
+                      static_cast<uint64_t>(offset),
+                      static_cast<uint64_t>(nbytes),
+                      flags);
+               return -1;
+       }
+
+       const auto munmap_on_exit = lttng::make_scope_exit([&]() noexcept {
+               const auto munmap_ret = munmap(mapped_region, nbytes);
+               if (munmap_ret) {
+                       PERROR("Failed to munmap region while flushing range: fd=%i, offset=%" PRIu64
+                              ", nbytes=%" PRIu64 ", flags=%i",
+                              fd,
+                              static_cast<uint64_t>(offset),
+                              static_cast<uint64_t>(nbytes),
+                              flags);
+               }
+       });
+
+       const auto msync_ret = msync(mapped_region, nbytes, flags);
+       if (msync_ret) {
+               PERROR("Failed to msync region while flushing range: fd=%i, offset=%" PRIu64
+                      ", nbytes=%" PRIu64 ", flags=%i",
+                      fd,
+                      static_cast<uint64_t>(offset),
+                      static_cast<uint64_t>(nbytes),
+                      flags);
+               return -1;
+       }
+
+       return 0;
+}
+
+int flush_range_sync(int fd, off_t offset, off_t nbytes)
+{
+       return flush_range(fd, offset, nbytes, MS_SYNC);
+}
+
+int flush_range_async(int fd, off_t offset, off_t nbytes)
+{
+       return flush_range(fd, offset, nbytes, MS_ASYNC);
+}
+} /* namespace */
+#endif
+
+/*
+ * Give a hint to the kernel that we won't need the data at the specified range
+ * so it can be dropped from the page cache and wait for it to be flushed to
+ * disk.
+ */
+void lttng::io::hint_flush_range_dont_need_sync(int fd, off_t offset, off_t nbytes)
+{
+       /* Waited for the page writeback to complete. */
+       flush_range_sync(fd, offset, nbytes);
+
+       /*
+        * Give hints to the kernel about how we access the file:
+        * POSIX_FADV_DONTNEED : we won't re-access data in a near future after
+        * we write it.
+        *
+        * We need to call fadvise again after the file grows because the
+        * kernel does not seem to apply fadvise to non-existing parts of the
+        * file.
+        *
+        * Call fadvise _after_ having waited for the page writeback to
+        * complete because the dirty page writeback semantic is not well
+        * defined. So it can be expected to lead to lower throughput in
+        * streaming.
+        */
+       const int ret = posix_fadvise(fd, offset, nbytes, POSIX_FADV_DONTNEED);
+       if (ret && ret != -ENOSYS) {
+               PERROR("Failed to mark region as DONTNEED with posix_fadvise: fd=%i, offset=%" PRIu64
+                      ", nbytes=%" PRIu64,
+                      fd,
+                      static_cast<uint64_t>(offset),
+                      static_cast<uint64_t>(nbytes));
+               errno = ret;
+       }
+}
+
+/*
+ * Give a hint to the kernel that the data at the specified range should be
+ * flushed to disk and wait for it to complete.
+ */
+void lttng::io::hint_flush_range_sync(int fd, off_t offset, off_t nbytes)
+{
+       flush_range_sync(fd, offset, nbytes);
+}
+
+/*
+ * Give a hint to the kernel that the data at the specified range should be
+ * flushed to disk and return immediatly.
+ */
+void lttng::io::hint_flush_range_async(int fd, off_t offset, off_t nbytes)
+{
+       flush_range_async(fd, offset, nbytes);
+}
diff --git a/src/common/io-hint.hpp b/src/common/io-hint.hpp
new file mode 100644 (file)
index 0000000..24fde6b
--- /dev/null
@@ -0,0 +1,21 @@
+/*
+ * Copyright (C) 2023 Michael Jeanson <mjeanson@efficios.com>
+ *
+ * SPDX-License-Identifier: LGPL-2.1-only
+ *
+ */
+
+#ifndef _LTTNG_IO_HINT_H
+#define _LTTNG_IO_HINT_H
+
+namespace lttng {
+namespace io {
+
+void hint_flush_range_dont_need_sync(int fd, off_t offset, off_t nbytes);
+void hint_flush_range_sync(int fd, off_t offset, off_t nbytes);
+void hint_flush_range_async(int fd, off_t offset, off_t nbytes);
+
+} /* namespace io */
+} /* namespace lttng */
+
+#endif
index b0aa99ec1ce25ffc45242b4ffcc0cd6acf0375da..7e8de03f6b1380ca46eaf31c02ce5682b5f20e81 100644 (file)
@@ -13,7 +13,6 @@
 #include <common/buffer-view.hpp>
 #include <common/common.hpp>
 #include <common/compat/endian.hpp>
-#include <common/compat/fcntl.hpp>
 #include <common/consumer/consumer-stream.hpp>
 #include <common/consumer/consumer-timer.hpp>
 #include <common/consumer/consumer.hpp>
@@ -29,6 +28,7 @@
 #include <common/utils.hpp>
 
 #include <bin/lttng-consumerd/health-consumerd.hpp>
+#include <fcntl.h>
 #include <inttypes.h>
 #include <poll.h>
 #include <pthread.h>
index 48a01a352e7f5ccd268ac13f4120e2c9ba473f62..6274cdcc5341bdfa62bdcca12e8f8c945bb50007 100644 (file)
@@ -12,7 +12,6 @@
 
 #include <common/common.hpp>
 #include <common/compat/endian.hpp>
-#include <common/compat/fcntl.hpp>
 #include <common/consumer/consumer-metadata-cache.hpp>
 #include <common/consumer/consumer-stream.hpp>
 #include <common/consumer/consumer-timer.hpp>
@@ -29,6 +28,7 @@
 #include <lttng/ust-sigbus.h>
 
 #include <bin/lttng-consumerd/health-consumerd.hpp>
+#include <fcntl.h>
 #include <inttypes.h>
 #include <poll.h>
 #include <pthread.h>
index 2d1e016964461f9c800c574c697ca83e90c6e9c3..419fc893d23796609aac808dc153c78f2e8551a2 100644 (file)
@@ -5,10 +5,10 @@
  *
  */
 
-#include <common/compat/fcntl.hpp>
 #include <common/payload-view.hpp>
 #include <common/payload.hpp>
 
+#include <fcntl.h>
 #include <tap/tap.h>
 #include <unistd.h>
 
index ea02c2ec2700ddcebc3b42f810fea9b7ab5b6a9a..e0af6e2969b4125417d0ec11d98659cac54ff32d 100644 (file)
@@ -5,7 +5,6 @@
  *
  */
 
-#include <common/compat/fcntl.hpp>
 #include <common/defaults.hpp>
 #include <common/error.hpp>
 #include <common/payload-view.hpp>
@@ -17,6 +16,7 @@
 #include <lttng/constant.h>
 
 #include <algorithm>
+#include <fcntl.h>
 #include <pthread.h>
 #include <stdbool.h>
 #include <stdio.h>
This page took 0.038805 seconds and 4 git commands to generate.