Josef Bacik
6719db6a23
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>
2011-08-21 07:02:00 -07:00
..
2011-08-02 21:14:05 -10:00
2010-05-25 10:34:58 -04:00
2009-10-05 09:44:45 -04:00
2011-07-27 12:46:48 -04:00
2009-01-06 09:38:55 -05:00
2011-08-01 14:30:46 -04:00
2011-05-02 13:57:19 +02:00
2011-07-27 12:46:47 -04:00
2011-08-18 10:38:03 -04:00
2011-07-27 12:46:46 -04:00
2011-07-26 16:49:47 -07:00
2011-05-06 12:34:10 +02:00
2011-05-06 12:34:03 +02:00
2011-08-01 14:30:48 -04:00
2011-07-27 16:43:52 -07:00
2011-07-27 12:46:46 -04:00
2011-05-21 09:27:38 -04:00
2008-09-25 11:04:06 -04:00
2011-08-02 21:14:05 -10:00
2011-08-01 14:30:50 -04:00
2011-08-01 14:30:50 -04:00
2011-05-02 13:57:21 +02:00
2011-08-21 07:02:00 -07:00
2011-08-01 14:27:34 -04:00
2011-08-18 10:38:03 -04:00
2011-08-16 21:09:31 -04:00
2011-05-06 12:34:03 +02:00
2009-06-10 11:29:53 -04:00
2011-05-23 13:24:39 -04:00
2011-06-04 08:11:22 -04:00
2011-04-25 16:46:11 +08:00
2011-08-18 10:16:03 -04:00
2011-08-18 10:38:03 -04:00
2011-05-26 17:52:15 -04:00
2010-12-22 23:15:47 +08:00
2011-07-27 12:46:46 -04:00
2011-07-27 12:46:46 -04:00
2011-02-16 15:37:58 -05:00
2011-08-01 14:30:48 -04:00
2011-03-28 05:37:33 -04:00
2010-12-22 23:15:45 +08:00
2010-12-09 13:57:15 -05:00
2011-01-28 16:40:37 -05:00
2008-09-25 11:03:56 -04:00
2011-07-27 16:18:13 -04:00
2011-08-01 14:30:44 -04:00
2011-06-10 14:59:52 +02:00
2011-07-27 12:46:45 -04:00
2011-07-08 23:25:45 -07:00
2011-06-17 14:54:18 -04:00
2011-08-01 14:30:47 -04:00
2011-05-28 07:00:39 -04:00
2011-05-02 13:57:22 +02:00
2011-08-16 21:09:15 -04:00
2011-05-04 14:01:26 +02:00
2008-09-25 15:41:59 -04:00
2011-08-16 21:09:31 -04:00
2011-08-16 21:09:15 -04:00
2011-07-11 09:58:45 -04:00
2011-02-01 11:12:29 -05:00
2011-03-22 17:44:17 -07:00