lkml.org 
[lkml]   [2003]   [Jan]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[PATCH][COMPAT] {get,put}_compat_timspec 6/8 s390x
Hi Linus,

Here is the s390x part of the patch. Martin has said that I should feed
these straight to you and he will fix up any problems later. Please apply
if you apply the gerneic part.
--
Cheers,
Stephen Rothwell sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/

diff -ruN 2.5.54-200301081106-32bit.2/arch/s390x/kernel/linux32.c 2.5.54-200301081106-32bit.3/arch/s390x/kernel/linux32.c
--- 2.5.54-200301081106-32bit.2/arch/s390x/kernel/linux32.c 2003-01-08 11:40:35.000000000 +1100
+++ 2.5.54-200301081106-32bit.3/arch/s390x/kernel/linux32.c 2003-01-08 17:14:08.000000000 +1100
@@ -1671,8 +1671,7 @@
set_fs (KERNEL_DS);
ret = sys_sched_rr_get_interval(pid, &t);
set_fs (old_fs);
- if (put_user (t.tv_sec, &interval->tv_sec) ||
- __put_user (t.tv_nsec, &interval->tv_nsec))
+ if (put_compat_timespec(&t, interval))
return -EFAULT;
return ret;
}
@@ -1806,8 +1805,7 @@
signotset(&these);

if (uts) {
- if (get_user (ts.tv_sec, &uts->tv_sec) ||
- get_user (ts.tv_nsec, &uts->tv_nsec))
+ if (get_compat_timespec(&ts, uts))
return -EINVAL;
if (ts.tv_nsec >= 1000000000L || ts.tv_nsec < 0
|| ts.tv_sec < 0)
@@ -4149,13 +4147,12 @@
mm_segment_t old_fs;
int ret;

- if (get_user (tmp.tv_sec, &timeout32->tv_sec) ||
- get_user (tmp.tv_nsec, &timeout32->tv_nsec))
+ if (timeout32 && get_compat_timespec(&tmp, timeout32))
return -EINVAL;

old_fs = get_fs();
set_fs(KERNEL_DS);
- ret = sys_futex(uaddr, op, val, &tmp);
+ ret = sys_futex(uaddr, op, val, timeout32 ? &tmp : NULL);
set_fs(old_fs);

return ret;
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
\
 
 \ /
  Last update: 2005-03-22 13:32    [W:1.857 / U:0.060 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site