From: Mathieu Desnoyers Date: Mon, 13 Apr 2020 20:44:43 +0000 (-0400) Subject: namespace contexts: remove compatibility code X-Git-Tag: for-upstreaming-review-1~37 X-Git-Url: http://git.liburcu.org/?p=lttng-modules.git;a=commitdiff_plain;h=9f920259167fcd032139b2ab605b82e5d0b970c6 namespace contexts: remove compatibility code --- diff --git a/lttng-context-ipc-ns.c b/lttng-context-ipc-ns.c index 4e9a60ee..f4080788 100644 --- a/lttng-context-ipc-ns.c +++ b/lttng-context-ipc-ns.c @@ -17,8 +17,7 @@ #include #include -#if defined(CONFIG_IPC_NS) && \ - (LINUX_VERSION_CODE >= KERNEL_VERSION(3,8,0)) +#if defined(CONFIG_IPC_NS) static size_t ipc_ns_get_size(size_t offset) diff --git a/lttng-context-mnt-ns.c b/lttng-context-mnt-ns.c index 154517bd..c6b7dbe0 100644 --- a/lttng-context-mnt-ns.c +++ b/lttng-context-mnt-ns.c @@ -17,8 +17,7 @@ #include #include -#if !defined(LTTNG_MNT_NS_MISSING_HEADER) && \ - (LINUX_VERSION_CODE >= KERNEL_VERSION(3,8,0)) +#if !defined(LTTNG_MNT_NS_MISSING_HEADER) #include <../fs/mount.h> diff --git a/lttng-context-net-ns.c b/lttng-context-net-ns.c index 459aa379..b96afee8 100644 --- a/lttng-context-net-ns.c +++ b/lttng-context-net-ns.c @@ -18,8 +18,7 @@ #include #include -#if defined(CONFIG_NET_NS) && \ - (LINUX_VERSION_CODE >= KERNEL_VERSION(3,8,0)) +#if defined(CONFIG_NET_NS) static size_t net_ns_get_size(size_t offset) diff --git a/lttng-context-pid-ns.c b/lttng-context-pid-ns.c index 1e95d6b3..894789b8 100644 --- a/lttng-context-pid-ns.c +++ b/lttng-context-pid-ns.c @@ -17,8 +17,7 @@ #include #include -#if defined(CONFIG_PID_NS) && \ - (LINUX_VERSION_CODE >= KERNEL_VERSION(3,8,0)) +#if defined(CONFIG_PID_NS) static size_t pid_ns_get_size(size_t offset) diff --git a/lttng-context-user-ns.c b/lttng-context-user-ns.c index 15306389..04a2c3ee 100644 --- a/lttng-context-user-ns.c +++ b/lttng-context-user-ns.c @@ -17,8 +17,7 @@ #include #include -#if defined(CONFIG_USER_NS) && \ - (LINUX_VERSION_CODE >= KERNEL_VERSION(3,8,0)) +#if defined(CONFIG_USER_NS) static size_t user_ns_get_size(size_t offset) diff --git a/lttng-context-uts-ns.c b/lttng-context-uts-ns.c index cb8c60f1..a6dbddf0 100644 --- a/lttng-context-uts-ns.c +++ b/lttng-context-uts-ns.c @@ -17,8 +17,7 @@ #include #include -#if defined(CONFIG_UTS_NS) && \ - (LINUX_VERSION_CODE >= KERNEL_VERSION(3,8,0)) +#if defined(CONFIG_UTS_NS) static size_t uts_ns_get_size(size_t offset) diff --git a/lttng-events.h b/lttng-events.h index 05309174..52402198 100644 --- a/lttng-events.h +++ b/lttng-events.h @@ -731,8 +731,7 @@ int lttng_add_cgroup_ns_to_ctx(struct lttng_ctx **ctx) } #endif -#if defined(CONFIG_IPC_NS) && \ - (LINUX_VERSION_CODE >= KERNEL_VERSION(3,8,0)) +#if defined(CONFIG_IPC_NS) int lttng_add_ipc_ns_to_ctx(struct lttng_ctx **ctx); #else static inline @@ -742,8 +741,7 @@ int lttng_add_ipc_ns_to_ctx(struct lttng_ctx **ctx) } #endif -#if !defined(LTTNG_MNT_NS_MISSING_HEADER) && \ - (LINUX_VERSION_CODE >= KERNEL_VERSION(3,8,0)) +#if !defined(LTTNG_MNT_NS_MISSING_HEADER) int lttng_add_mnt_ns_to_ctx(struct lttng_ctx **ctx); #else static inline @@ -753,8 +751,7 @@ int lttng_add_mnt_ns_to_ctx(struct lttng_ctx **ctx) } #endif -#if defined(CONFIG_NET_NS) && \ - (LINUX_VERSION_CODE >= KERNEL_VERSION(3,8,0)) +#if defined(CONFIG_NET_NS) int lttng_add_net_ns_to_ctx(struct lttng_ctx **ctx); #else static inline @@ -764,8 +761,7 @@ int lttng_add_net_ns_to_ctx(struct lttng_ctx **ctx) } #endif -#if defined(CONFIG_PID_NS) && \ - (LINUX_VERSION_CODE >= KERNEL_VERSION(3,8,0)) +#if defined(CONFIG_PID_NS) int lttng_add_pid_ns_to_ctx(struct lttng_ctx **ctx); #else static inline @@ -775,8 +771,7 @@ int lttng_add_pid_ns_to_ctx(struct lttng_ctx **ctx) } #endif -#if defined(CONFIG_USER_NS) && \ - (LINUX_VERSION_CODE >= KERNEL_VERSION(3,8,0)) +#if defined(CONFIG_USER_NS) int lttng_add_user_ns_to_ctx(struct lttng_ctx **ctx); #else static inline @@ -786,8 +781,7 @@ int lttng_add_user_ns_to_ctx(struct lttng_ctx **ctx) } #endif -#if defined(CONFIG_UTS_NS) && \ - (LINUX_VERSION_CODE >= KERNEL_VERSION(3,8,0)) +#if defined(CONFIG_UTS_NS) int lttng_add_uts_ns_to_ctx(struct lttng_ctx **ctx); #else static inline