summaryrefslogtreecommitdiffstats
path: root/arch/mips/kernel/binfmt_elfn32.c
diff options
context:
space:
mode:
authorAtsushi Nemoto <anemo@mba.ocn.ne.jp>2006-02-20 17:25:06 +0100
committerRalf Baechle <ralf@linux-mips.org>2006-02-21 17:58:23 +0100
commit909fa64c8bf0ef20722cddaa402404fb1aa14a4a (patch)
tree6729397505d8039b6220c0753775ceb3918789f8 /arch/mips/kernel/binfmt_elfn32.c
parent[MIPS] Add topology_init. (diff)
downloadlinux-909fa64c8bf0ef20722cddaa402404fb1aa14a4a.tar.xz
linux-909fa64c8bf0ef20722cddaa402404fb1aa14a4a.zip
[MIPS] jiffies_to_compat_timeval fix
The last argument of div_long_long_rem() must be long. Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp> Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Diffstat (limited to 'arch/mips/kernel/binfmt_elfn32.c')
-rw-r--r--arch/mips/kernel/binfmt_elfn32.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/arch/mips/kernel/binfmt_elfn32.c b/arch/mips/kernel/binfmt_elfn32.c
index d8e2674a1543..4a9f1ecefaf2 100644
--- a/arch/mips/kernel/binfmt_elfn32.c
+++ b/arch/mips/kernel/binfmt_elfn32.c
@@ -103,8 +103,9 @@ jiffies_to_compat_timeval(unsigned long jiffies, struct compat_timeval *value)
* one divide.
*/
u64 nsec = (u64)jiffies * TICK_NSEC;
- value->tv_sec = div_long_long_rem(nsec, NSEC_PER_SEC, &value->tv_usec);
- value->tv_usec /= NSEC_PER_USEC;
+ long rem;
+ value->tv_sec = div_long_long_rem(nsec, NSEC_PER_SEC, &rem);
+ value->tv_usec = rem / NSEC_PER_USEC;
}
#define ELF_CORE_EFLAGS EF_MIPS_ABI2