[PATCH 30/40] trace syscalls: Convert remaining kernel/compat.c syscalls to COMPAT_SYSCALL_DEFINE

Ian Munsie imunsie at au1.ibm.com
Wed Jun 23 20:03:11 EST 2010


From: Ian Munsie <imunsie at au1.ibm.com>

This patch converts the remaining system calls from kernel/compat.c to
use the COMPAT_SYSCALL_DEFINE family of macros.

The particular system calls in question did not originally have the
asmlinkage tag which will be added by this conversion.

Signed-off-by: Ian Munsie <imunsie at au1.ibm.com>
---
 kernel/compat.c |   34 +++++++++++++++++-----------------
 1 files changed, 17 insertions(+), 17 deletions(-)

diff --git a/kernel/compat.c b/kernel/compat.c
index 7ab99e1..81762e4 100644
--- a/kernel/compat.c
+++ b/kernel/compat.c
@@ -535,9 +535,9 @@ int put_compat_itimerspec(struct compat_itimerspec __user *dst,
 	return 0;
 }
 
-long compat_sys_timer_create(clockid_t which_clock,
-			struct compat_sigevent __user *timer_event_spec,
-			timer_t __user *created_timer_id)
+COMPAT_SYSCALL_DEFINE3(timer_create, clockid_t, which_clock,
+			struct compat_sigevent __user *, timer_event_spec,
+			timer_t __user *, created_timer_id)
 {
 	struct sigevent __user *event = NULL;
 
@@ -553,9 +553,9 @@ long compat_sys_timer_create(clockid_t which_clock,
 	return sys_timer_create(which_clock, event, created_timer_id);
 }
 
-long compat_sys_timer_settime(timer_t timer_id, int flags,
-			  struct compat_itimerspec __user *new,
-			  struct compat_itimerspec __user *old)
+COMPAT_SYSCALL_DEFINE4(timer_settime, timer_t, timer_id, int, flags,
+			  struct compat_itimerspec __user *, new,
+			  struct compat_itimerspec __user *, old)
 {
 	long err;
 	mm_segment_t oldfs;
@@ -576,8 +576,8 @@ long compat_sys_timer_settime(timer_t timer_id, int flags,
 	return err;
 }
 
-long compat_sys_timer_gettime(timer_t timer_id,
-		struct compat_itimerspec __user *setting)
+COMPAT_SYSCALL_DEFINE2(timer_gettime, timer_t, timer_id,
+		struct compat_itimerspec __user *, setting)
 {
 	long err;
 	mm_segment_t oldfs;
@@ -593,8 +593,8 @@ long compat_sys_timer_gettime(timer_t timer_id,
 	return err;
 }
 
-long compat_sys_clock_settime(clockid_t which_clock,
-		struct compat_timespec __user *tp)
+COMPAT_SYSCALL_DEFINE2(clock_settime, clockid_t, which_clock,
+		struct compat_timespec __user *, tp)
 {
 	long err;
 	mm_segment_t oldfs;
@@ -610,8 +610,8 @@ long compat_sys_clock_settime(clockid_t which_clock,
 	return err;
 }
 
-long compat_sys_clock_gettime(clockid_t which_clock,
-		struct compat_timespec __user *tp)
+COMPAT_SYSCALL_DEFINE2(clock_gettime, clockid_t, which_clock,
+		struct compat_timespec __user *, tp)
 {
 	long err;
 	mm_segment_t oldfs;
@@ -627,8 +627,8 @@ long compat_sys_clock_gettime(clockid_t which_clock,
 	return err;
 }
 
-long compat_sys_clock_getres(clockid_t which_clock,
-		struct compat_timespec __user *tp)
+COMPAT_SYSCALL_DEFINE2(clock_getres, clockid_t, which_clock,
+		struct compat_timespec __user *, tp)
 {
 	long err;
 	mm_segment_t oldfs;
@@ -668,9 +668,9 @@ static long compat_clock_nanosleep_restart(struct restart_block *restart)
 	return err;
 }
 
-long compat_sys_clock_nanosleep(clockid_t which_clock, int flags,
-			    struct compat_timespec __user *rqtp,
-			    struct compat_timespec __user *rmtp)
+COMPAT_SYSCALL_DEFINE4(clock_nanosleep, clockid_t, which_clock, int, flags,
+			    struct compat_timespec __user *, rqtp,
+			    struct compat_timespec __user *, rmtp)
 {
 	long err;
 	mm_segment_t oldfs;
-- 
1.7.1



More information about the Linuxppc-dev mailing list