[PATCH 1/4] Define INLINE_VSYSCALL on all ports
Adhemerval Zanella
adhemerval.zanella@linaro.org
Wed Apr 15 20:22:00 GMT 2015
This patch adds the INLINE_VSYSCALL definition on all remaning
architectures that miss it. It redirects to INLINE_SYSCALL.
--
* sysdeps/unix/sysv/linux/alpha/sysdep.h [INLINE_VSYSCALL]: Define
INLINE_SYSCALL.
* sysdeps/unix/sysv/linux/arm/sysdep.h [INLINE_VSYSCALL]: Likewise.
* sysdeps/unix/sysv/linux/hppa/sysdep.h [INLINE_VSYSCALL]: Likewise.
* sysdeps/unix/sysv/linux/ia64/sysdep.h [INLINE_VSYSCALL]: Likewise.
* sysdeps/unix/sysv/linux/m68k/sysdep.h [INLINE_VSYSCALL]: Likewise.
* sysdeps/unix/sysv/linux/mips/mips32/sysdep.h [INLINE_VSYSCALL]:
Likewise.
* sysdeps/unix/sysv/linux/mips/mips64/n32/sysdep.h [INLINE_VSYSCALL]:
Likewise.
* sysdeps/unix/sysv/linux/mips/mips64/n64/sysdep.h [INLINE_VSYSCALL]:
Likewise.
* sysdeps/unix/sysv/linux/nios2/sysdep.h [INLINE_VSYSCALL]: Likewise.
* sysdeps/unix/sysv/linux/sh/sysdep.h [INLINE_VSYSCALL]: Likewise.
* sysdeps/unix/sysv/linux/sparc/sysdep.h [INLINE_VSYSCALL]: Likewise.
---
diff --git a/sysdeps/unix/sysv/linux/alpha/sysdep.h b/sysdeps/unix/sysv/linux/alpha/sysdep.h
index a95b113..422f7e4 100644
--- a/sysdeps/unix/sysv/linux/alpha/sysdep.h
+++ b/sysdeps/unix/sysv/linux/alpha/sysdep.h
@@ -84,6 +84,10 @@
INLINE_SYSCALL1(name, nr, args); \
})
+#undef INLINE_VSYSCALL
+#define INLINE_VSYSCALL(name, nr, args...) \
+ INLINE_SYSCALL (name, nr, ##args)
+
#undef INTERNAL_SYSCALL
#define INTERNAL_SYSCALL(name, err_out, nr, args...) \
({ \
diff --git a/sysdeps/unix/sysv/linux/arm/sysdep.h b/sysdeps/unix/sysv/linux/arm/sysdep.h
index 37eac19..15bc357 100644
--- a/sysdeps/unix/sysv/linux/arm/sysdep.h
+++ b/sysdeps/unix/sysv/linux/arm/sysdep.h
@@ -328,6 +328,10 @@ __local_syscall_error: \
} \
(int) _sys_result; })
+#undef INLINE_VSYSCALL
+#define INLINE_VSYSCALL(name, nr, args...) \
+ INLINE_SYSCALL (name, nr, ##args)
+
#undef INTERNAL_SYSCALL_DECL
#define INTERNAL_SYSCALL_DECL(err) do { } while (0)
diff --git a/sysdeps/unix/sysv/linux/hppa/sysdep.h b/sysdeps/unix/sysv/linux/hppa/sysdep.h
index ac47814..f7aa68e 100644
--- a/sysdeps/unix/sysv/linux/hppa/sysdep.h
+++ b/sysdeps/unix/sysv/linux/hppa/sysdep.h
@@ -386,6 +386,10 @@ L(pre_end): ASM_LINE_SEP \
__sys_res; \
})
+#undef INLINE_VSYSCALL
+#define INLINE_VSYSCALL(name, nr, args...) \
+ INLINE_SYSCALL (name, nr, ##args)
+
/* INTERNAL_SYSCALL_DECL - Allows us to setup some function static
value to use within the context of the syscall
INTERNAL_SYSCALL_ERROR_P - Returns 0 if it wasn't an error, 1 otherwise
diff --git a/sysdeps/unix/sysv/linux/ia64/sysdep.h b/sysdeps/unix/sysv/linux/ia64/sysdep.h
index 03efae9..da9b1b11 100644
--- a/sysdeps/unix/sysv/linux/ia64/sysdep.h
+++ b/sysdeps/unix/sysv/linux/ia64/sysdep.h
@@ -251,6 +251,10 @@
} \
_retval; })
+#undef INLINE_VSYSCALL
+#define INLINE_VSYSCALL(name, nr, args...) \
+ INLINE_SYSCALL (name, nr, ##args)
+
#undef INTERNAL_SYSCALL_DECL
#define INTERNAL_SYSCALL_DECL(err) long int err __attribute__ ((unused))
diff --git a/sysdeps/unix/sysv/linux/m68k/sysdep.h b/sysdeps/unix/sysv/linux/m68k/sysdep.h
index 2b88add..3760452 100644
--- a/sysdeps/unix/sysv/linux/m68k/sysdep.h
+++ b/sysdeps/unix/sysv/linux/m68k/sysdep.h
@@ -266,6 +266,10 @@ SYSCALL_ERROR_LABEL: \
#undef INTERNAL_SYSCALL_ERRNO
#define INTERNAL_SYSCALL_ERRNO(val, err) (-(val))
+#undef INLINE_VSYSCALL
+#define INLINE_VSYSCALL(name, nr, args...) \
+ INLINE_SYSCALL (name, nr, ##args)
+
#define LOAD_ARGS_0()
#define LOAD_REGS_0
#define ASM_ARGS_0
diff --git a/sysdeps/unix/sysv/linux/mips/mips32/sysdep.h b/sysdeps/unix/sysv/linux/mips/mips32/sysdep.h
index e5025ba..2fa2d31 100644
--- a/sysdeps/unix/sysv/linux/mips/mips32/sysdep.h
+++ b/sysdeps/unix/sysv/linux/mips/mips32/sysdep.h
@@ -67,6 +67,10 @@
#undef INTERNAL_SYSCALL_ERRNO
#define INTERNAL_SYSCALL_ERRNO(val, err) ((void) (err), val)
+#undef INLINE_VSYSCALL
+#define INLINE_VSYSCALL(name, nr, args...) \
+ INLINE_SYSCALL (name, nr, ##args)
+
/* Note that the original Linux syscall restart convention required the
instruction immediately preceding SYSCALL to initialize $v0 with the
syscall number. Then if a restart triggered, $v0 would have been
diff --git a/sysdeps/unix/sysv/linux/mips/mips64/n32/sysdep.h b/sysdeps/unix/sysv/linux/mips/mips64/n32/sysdep.h
index ac663bc..7ccc9d3 100644
--- a/sysdeps/unix/sysv/linux/mips/mips64/n32/sysdep.h
+++ b/sysdeps/unix/sysv/linux/mips/mips64/n32/sysdep.h
@@ -69,6 +69,10 @@
#undef INTERNAL_SYSCALL_ERRNO
#define INTERNAL_SYSCALL_ERRNO(val, err) ((void) (err), val)
+#undef INLINE_VSYSCALL
+#define INLINE_VSYSCALL(name, nr, args...) \
+ INLINE_SYSCALL (name, nr, ##args)
+
/* Note that the original Linux syscall restart convention required the
instruction immediately preceding SYSCALL to initialize $v0 with the
syscall number. Then if a restart triggered, $v0 would have been
diff --git a/sysdeps/unix/sysv/linux/mips/mips64/n64/sysdep.h b/sysdeps/unix/sysv/linux/mips/mips64/n64/sysdep.h
index 312f210..e05ec07 100644
--- a/sysdeps/unix/sysv/linux/mips/mips64/n64/sysdep.h
+++ b/sysdeps/unix/sysv/linux/mips/mips64/n64/sysdep.h
@@ -65,6 +65,10 @@
#undef INTERNAL_SYSCALL_ERRNO
#define INTERNAL_SYSCALL_ERRNO(val, err) ((void) (err), val)
+#undef INLINE_VSYSCALL
+#define INLINE_VSYSCALL(name, nr, args...) \
+ INLINE_SYSCALL (name, nr, ##args)
+
/* Note that the original Linux syscall restart convention required the
instruction immediately preceding SYSCALL to initialize $v0 with the
syscall number. Then if a restart triggered, $v0 would have been
diff --git a/sysdeps/unix/sysv/linux/nios2/sysdep.h b/sysdeps/unix/sysv/linux/nios2/sysdep.h
index 66a77f4..8cbeb42 100644
--- a/sysdeps/unix/sysv/linux/nios2/sysdep.h
+++ b/sysdeps/unix/sysv/linux/nios2/sysdep.h
@@ -190,6 +190,10 @@
#define INTERNAL_SYSCALL_NCS(number, err, nr, args...) \
INTERNAL_SYSCALL_RAW(number, err, nr, args)
+#undef INLINE_VSYSCALL
+#define INLINE_VSYSCALL(name, nr, args...) \
+ INLINE_SYSCALL (name, nr, ##args)
+
#define LOAD_ARGS_0()
#define LOAD_REGS_0
#define ASM_ARGS_0
diff --git a/sysdeps/unix/sysv/linux/sh/sysdep.h b/sysdeps/unix/sysv/linux/sh/sysdep.h
index 5226ff6..041d1e8 100644
--- a/sysdeps/unix/sysv/linux/sh/sysdep.h
+++ b/sysdeps/unix/sysv/linux/sh/sysdep.h
@@ -297,6 +297,10 @@
} \
(int) resultvar; })
+#undef INLINE_VSYSCALL
+#define INLINE_VSYSCALL(name, nr, args...) \
+ INLINE_SYSCALL (name, nr, ##args)
+
#undef INTERNAL_SYSCALL
#define INTERNAL_SYSCALL(name, err, nr, args...) \
({ \
diff --git a/sysdeps/unix/sysv/linux/sparc/sysdep.h b/sysdeps/unix/sysv/linux/sparc/sysdep.h
index e215dbb..db4b993 100644
--- a/sysdeps/unix/sysv/linux/sparc/sysdep.h
+++ b/sysdeps/unix/sysv/linux/sparc/sysdep.h
@@ -45,6 +45,10 @@
(long) resultvar; \
})
+#undef INLINE_VSYSCALL
+#define INLINE_VSYSCALL(name, nr, args...) \
+ INLINE_SYSCALL (name, nr, ##args)
+
#undef INTERNAL_SYSCALL_DECL
#define INTERNAL_SYSCALL_DECL(err) \
register long err __asm__("g1");
More information about the Libc-alpha
mailing list