diff options
author | Omar Sandoval <osandov@fb.com> | 2016-07-15 12:12:48 -0700 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2016-07-26 18:35:05 +0200 |
commit | 1d6c7cb725bb7d25981d44915b316e24751b7b72 (patch) | |
tree | 7199982cc55d2a8631191bcd98ac9cbabd54f3b9 /kerncompat.h | |
parent | 029772be1152bbdf921ee74b95cfcde4003f5e46 (diff) |
btrfs-progs: fix btrfsck of space_cache=v2 bitmaps on big-endian
Copy le_test_bit() from the kernel and use that for the free space tree
bitmaps.
Signed-off-by: Omar Sandoval <osandov@fb.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'kerncompat.h')
-rw-r--r-- | kerncompat.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/kerncompat.h b/kerncompat.h index 378f0552..c9b9b797 100644 --- a/kerncompat.h +++ b/kerncompat.h @@ -55,7 +55,8 @@ #define gfp_t int #define get_cpu_var(p) (p) #define __get_cpu_var(p) (p) -#define BITS_PER_LONG (__SIZEOF_LONG__ * 8) +#define BITS_PER_BYTE 8 +#define BITS_PER_LONG (__SIZEOF_LONG__ * BITS_PER_BYTE) #define __GFP_BITS_SHIFT 20 #define __GFP_BITS_MASK ((int)((1 << __GFP_BITS_SHIFT) - 1)) #define GFP_KERNEL 0 |