projects
/
lttng-modules.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
docs: Add links to project resources
[lttng-modules.git]
/
lttng-syscalls.c
diff --git
a/lttng-syscalls.c
b/lttng-syscalls.c
index b43dd570a029d1d5b1a4f6160765ae31668a6003..97a12c4835a896e0a0e050c98d5aa5cd0e25af5a 100644
(file)
--- a/
lttng-syscalls.c
+++ b/
lttng-syscalls.c
@@
-27,6
+27,7
@@
#include <wrapper/rcu.h>
#include <wrapper/syscall.h>
#include <lttng-events.h>
#include <wrapper/rcu.h>
#include <wrapper/syscall.h>
#include <lttng-events.h>
+#include <lttng-kernel-version.h>
#ifndef CONFIG_COMPAT
# ifndef is_compat_task
#ifndef CONFIG_COMPAT
# ifndef is_compat_task
@@
-36,7
+37,14
@@
/* in_compat_syscall appears in kernel 4.6. */
#ifndef in_compat_syscall
/* in_compat_syscall appears in kernel 4.6. */
#ifndef in_compat_syscall
- #define in_compat_syscall() is_compat_task()
+# define in_compat_syscall() is_compat_task()
+#endif
+
+/* in_x32_syscall appears in kernel 4.7. */
+#if (LTTNG_LINUX_VERSION_CODE < LTTNG_KERNEL_VERSION(4,7,0))
+# ifdef CONFIG_X86_X32_ABI
+# define in_x32_syscall() is_x32_task()
+# endif
#endif
enum sc_type {
#endif
enum sc_type {
@@
-81,7
+89,7
@@
struct timeval;
struct itimerval;
struct itimerspec;
struct itimerval;
struct itimerspec;
-#if (L
INUX_VERSION_CODE >=
KERNEL_VERSION(5,6,0))
+#if (L
TTNG_LINUX_VERSION_CODE >= LTTNG_
KERNEL_VERSION(5,6,0))
typedef __kernel_old_time_t time_t;
#endif
typedef __kernel_old_time_t time_t;
#endif
@@
-392,6
+400,12
@@
void syscall_entry_probe(void *__data, struct pt_regs *regs, long id)
const struct trace_syscall_entry *table, *entry;
size_t table_len;
const struct trace_syscall_entry *table, *entry;
size_t table_len;
+#ifdef CONFIG_X86_X32_ABI
+ if (in_x32_syscall()) {
+ /* x32 system calls are not supported. */
+ return;
+ }
+#endif
if (unlikely(in_compat_syscall())) {
struct lttng_syscall_filter *filter = chan->sc_filter;
if (unlikely(in_compat_syscall())) {
struct lttng_syscall_filter *filter = chan->sc_filter;
@@
-539,6
+553,12
@@
void syscall_exit_probe(void *__data, struct pt_regs *regs, long ret)
size_t table_len;
long id;
size_t table_len;
long id;
+#ifdef CONFIG_X86_X32_ABI
+ if (in_x32_syscall()) {
+ /* x32 system calls are not supported. */
+ return;
+ }
+#endif
id = syscall_get_nr(current, regs);
if (unlikely(in_compat_syscall())) {
struct lttng_syscall_filter *filter = chan->sc_filter;
id = syscall_get_nr(current, regs);
if (unlikely(in_compat_syscall())) {
struct lttng_syscall_filter *filter = chan->sc_filter;
This page took
0.027154 seconds
and
4
git commands to generate.