From a43d9da65a93f23bb5b5341ff177ad817ffd4398 Mon Sep 17 00:00:00 2001 From: Adrian Szyndela Date: Fri, 1 Oct 2021 12:49:48 +0200 Subject: [PATCH] kdbus: add memfd_create() syscall number for aarch64 Citing Lukasz Stelmach : > The number of the memfd_syscall() on arm64 is the same as on arm only > for 32-bit processes. 64-bit process must use the number defined in the > asm-generic/unistd.h kernel header. Additionally, made other numbers same as in glib. Change-Id: Ibb038d5d0de13f8a7b88051364564c541ca0fa9a --- dbus/dbus-transport-kdbus.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/dbus/dbus-transport-kdbus.c b/dbus/dbus-transport-kdbus.c index 2eb532c..5bb82e5 100755 --- a/dbus/dbus-transport-kdbus.c +++ b/dbus/dbus-transport-kdbus.c @@ -57,10 +57,14 @@ #include #if LINUX_VERSION_CODE < KERNEL_VERSION(3, 17, 0) -# if defined(__arm__) || defined(__aarch64__) +# if defined(__arm__) # define __NR_memfd_create 385 -# elif defined(__i386__) || defined(__x86_64__) +# elif defined(__aarch64__) # define __NR_memfd_create 279 +# elif defined(__i386__) +# define __NR_memfd_create 356 +# elif defined(__x86_64__) +# define __NR_memfd_create 319 # else # error "Architecture not supported" # endif -- 2.7.4