]> git.karo-electronics.de Git - karo-tx-linux.git/commit
math64: New separate div64_u64_rem helper
authorMike Snitzer <snitzer@redhat.com>
Tue, 20 Aug 2013 19:05:17 +0000 (15:05 -0400)
committerMike Snitzer <snitzer@redhat.com>
Tue, 20 Aug 2013 19:05:17 +0000 (15:05 -0400)
commit20e8125736d0e96b64c9b6127241d2a13529180a
treee12eaa9ab3e5fddfd27f7697e7f5b0baf00150e5
parent429074fedc3a89ef16f2a79e45a7fcbfbaa99d2c
math64: New separate div64_u64_rem helper

Commit f792685006274a850e6cc0ea9ade275ccdfc90bc ("math64: New
div64_u64_rem helper") implemented div64_u64 in terms of div64_u64_rem.
But div64_u64_rem was removed because it slowed down div64_u64 (and
there were no other users of div64_u64_rem).

Device Mapper's I/O statistics support has a need for div64_u64_rem;
reintroduce this helper as a separate method that doesn't slow down
div64_u64, especially on 32-bit systems.

Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Cc: Stanislaw Gruszka <sgruszka@redhat.com>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Mikulas Patocka <mpatocka@redhat.com>
Signed-off-by: Alasdair Kergon <agk@redhat.com>
include/linux/math64.h
lib/div64.c