[NET]: div64_64 consolidate (rev3)

Here is the current version of the 64 bit divide common code.

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Stephen Hemminger
2007-03-25 19:54:23 -07:00
committed by David S. Miller
parent 9d729f72dc
commit 3927f2e8f9
13 changed files with 60 additions and 63 deletions

View File

@@ -30,6 +30,11 @@
__rem; \
})
static inline uint64_t div64_64(uint64_t dividend, uint64_t divisor)
{
return dividend / divisor;
}
#elif BITS_PER_LONG == 32
extern uint32_t __div64_32(uint64_t *dividend, uint32_t divisor);
@@ -49,6 +54,8 @@ extern uint32_t __div64_32(uint64_t *dividend, uint32_t divisor);
__rem; \
})
extern uint64_t div64_64(uint64_t dividend, uint64_t divisor);
#else /* BITS_PER_LONG == ?? */
# error do_div() does not yet support the C64