Re: [PATCH] Kill div64.h dupes, parenthesize do_div() macro params

From: Andrew Morton (
Date: Tue Jul 01 2003 - 21:32:50 EST

Bernardo Innocenti <> wrote:
> By the way, what do you think about getting rid of the do_div() macro
> altogether?

I think we leave it the way it is because 64-bit divides are slow.

It is very easy to go accidentally adding 64-bit divides. Say, by changing
the disk indexing to use 64-bit sector numbers as we did earlier in 2.5.

By requiring an explicit do_div we are made aware of all those 64-bit
divides and are made to think about them.

Why 64-bit divides in particular were victimised in this manner is a matter
for speculation ;)

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

This archive was generated by hypermail 2b29 : Mon Jul 07 2003 - 22:00:14 EST