diff options
author | Josef Bacik <josef@redhat.com> | 2011-08-20 08:29:51 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2011-08-21 10:02:00 -0400 |
commit | 6719db6a23d4b7f1e5052eedae394135e3aef9c1 (patch) | |
tree | 2faf96d69696df0edfc0ab4d8f0c980ee0b89986 /drivers | |
parent | c063d8a60fc912ae198f054608ad461a69dc9a19 (diff) |
Btrfs: fix 64 bit divide problem
This fixes a regression introduced by commit cdcb725c05fe ("Btrfs: check
if there is enough space for balancing smarter"). We can't do 64-bit
divides on 32-bit architectures.
In cases where we need to divide/multiply by 2 we should just left/right
shift respectively, and in cases where theres N number of devices use
do_div. Also make the counters u64 to match up with rw_devices.
Thanks,
Signed-off-by: Josef Bacik <josef@redhat.com>
Acked-and-tested-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers')
0 files changed, 0 insertions, 0 deletions