From: zippel@linux-m68k.org
To: linux-kernel@vger.kernel.org
Cc: akpm@linux-foundation.org
Subject: [PATCH 5/4] 2.6.25-rc5-mm1 specifc div64_u64 fixes
Date: Thu, 13 Mar 2008 01:22:40 +0100 [thread overview]
Message-ID: <20080313004903.046240368@linux-m68k.org> (raw)
In-Reply-To: 20080313002235.351414762@linux-m68k.org
[-- Attachment #1: div64_mm --]
[-- Type: text/plain, Size: 1463 bytes --]
Rename a few more div64_u64 which are only in -mm.
Signed-off-by: Roman Zippel <zippel@linux-m68k.org>
---
arch/x86/kvm/i8254.c | 6 +++---
kernel/time.c | 2 +-
2 files changed, 4 insertions(+), 4 deletions(-)
Index: linux-2.6-mm/arch/x86/kvm/i8254.c
===================================================================
--- linux-2.6-mm.orig/arch/x86/kvm/i8254.c
+++ linux-2.6-mm/arch/x86/kvm/i8254.c
@@ -35,7 +35,7 @@
#include "i8254.h"
#ifndef CONFIG_X86_64
-#define mod_64(x, y) ((x) - (y) * div64_64(x, y))
+#define mod_64(x, y) ((x) - (y) * div64_u64(x, y))
#else
#define mod_64(x, y) ((x) % (y))
#endif
@@ -60,8 +60,8 @@ static u64 muldiv64(u64 a, u32 b, u32 c)
rl = (u64)u.l.low * (u64)b;
rh = (u64)u.l.high * (u64)b;
rh += (rl >> 32);
- res.l.high = div64_64(rh, c);
- res.l.low = div64_64(((mod_64(rh, c) << 32) + (rl & 0xffffffff)), c);
+ res.l.high = div64_u64(rh, c);
+ res.l.low = div64_u64(((mod_64(rh, c) << 32) + (rl & 0xffffffff)), c);
return res.ll;
}
Index: linux-2.6-mm/kernel/time.c
===================================================================
--- linux-2.6-mm.orig/kernel/time.c
+++ linux-2.6-mm/kernel/time.c
@@ -272,7 +272,7 @@ EXPORT_SYMBOL(jiffies_to_usecs);
u64 jiffies_64_to_usecs(const u64 j)
{
- return div64_64(j*HZ_TO_USEC_NUM + HZ_TO_USEC_DEN-1, HZ_TO_USEC_DEN);
+ return div64_u64(j*HZ_TO_USEC_NUM + HZ_TO_USEC_DEN-1, HZ_TO_USEC_DEN);
}
EXPORT_SYMBOL(jiffies_64_to_usecs);
--
prev parent reply other threads:[~2008-03-13 1:02 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-03-13 0:22 [PATCH 0/4] [RFC] cleanup 64bit divide API zippel
2008-03-13 0:22 ` [PATCH 1/4] introduce explicit signed/unsigned 64bit divide zippel
2008-03-13 10:13 ` Geert Uytterhoeven
2008-03-13 14:59 ` Roman Zippel
2008-03-13 20:34 ` Andrew Morton
2008-03-14 17:45 ` Roman Zippel
2008-03-13 0:22 ` [PATCH 2/4] convert a few do_div user zippel
2008-03-18 20:10 ` Jörg-Volker Peetz
2008-03-13 0:22 ` [PATCH 3/4] rename div64_64 to div64_u64 zippel
2008-03-13 0:22 ` [PATCH 4/4] remove div_long_long_rem zippel
2008-03-13 0:22 ` zippel [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20080313004903.046240368@linux-m68k.org \
--to=zippel@linux-m68k.org \
--cc=akpm@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox