The patch titled add an inlined version of iter_div_u64_rem has been removed from the -mm tree. Its filename was add-an-inlined-version-of-iter_div_u64_rem.patch This patch was dropped because it was merged into mainline or a subsystem tree The current -mm tree may be found at http://userweb.kernel.org/~akpm/mmotm/ ------------------------------------------------------ Subject: add an inlined version of iter_div_u64_rem From: Jeremy Fitzhardinge <jeremy@xxxxxxxx> iter_div_u64_rem is used in the x86-64 vdso, which cannot call other kernel code. For this case, provide the always_inlined version, __iter_div_u64_rem. Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@xxxxxxxxxx> Cc: Ingo Molnar <mingo@xxxxxxx> Cc: Thomas Gleixner <tglx@xxxxxxxxxxxxx> Cc: john stultz <johnstul@xxxxxxxxxx> Cc: Segher Boessenkool <segher@xxxxxxxxxxxxxxxxxxx> Cc: Christian Kujau <lists@xxxxxxxxxxxxxxx> Cc: Robert Hancock <hancockr@xxxxxxx> Cc: Andi Kleen <andi@xxxxxxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- include/linux/math64.h | 19 +++++++++++++++++++ lib/div64.c | 15 +-------------- 2 files changed, 20 insertions(+), 14 deletions(-) diff -puN include/linux/math64.h~add-an-inlined-version-of-iter_div_u64_rem include/linux/math64.h --- a/include/linux/math64.h~add-an-inlined-version-of-iter_div_u64_rem +++ a/include/linux/math64.h @@ -83,4 +83,23 @@ static inline s64 div_s64(s64 dividend, u32 iter_div_u64_rem(u64 dividend, u32 divisor, u64 *remainder); +static __always_inline u32 +__iter_div_u64_rem(u64 dividend, u32 divisor, u64 *remainder) +{ + u32 ret = 0; + + while (dividend >= divisor) { + /* The following asm() prevents the compiler from + optimising this loop into a modulo operation. */ + asm("" : "+rm"(dividend)); + + dividend -= divisor; + ret++; + } + + *remainder = dividend; + + return ret; +} + #endif /* _LINUX_MATH64_H */ diff -puN lib/div64.c~add-an-inlined-version-of-iter_div_u64_rem lib/div64.c --- a/lib/div64.c~add-an-inlined-version-of-iter_div_u64_rem +++ a/lib/div64.c @@ -105,19 +105,6 @@ EXPORT_SYMBOL(div64_u64); */ u32 iter_div_u64_rem(u64 dividend, u32 divisor, u64 *remainder) { - u32 ret = 0; - - while (dividend >= divisor) { - /* The following asm() prevents the compiler from - optimising this loop into a modulo operation. */ - asm("" : "+rm"(dividend)); - - dividend -= divisor; - ret++; - } - - *remainder = dividend; - - return ret; + return __iter_div_u64_rem(dividend, divisor, remainder); } EXPORT_SYMBOL(iter_div_u64_rem); _ Patches currently in -mm which might be from jeremy@xxxxxxxx are linux-next.patch mm-remove-double-indirection-on-tlb-parameter-to-free_pgd_range-co.patch page-flags-record-page-flag-overlays-explicitly.patch page-flags-record-page-flag-overlays-explicitly-xen.patch slub-record-page-flag-overlays-explicitly.patch slob-record-page-flag-overlays-explicitly.patch -- To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html