summaryrefslogtreecommitdiffstats
path: root/fs/btrfs/ordered-data.h
diff options
context:
space:
mode:
authorChris Mason <chris.mason@oracle.com>2008-07-23 15:26:26 +0200
committerChris Mason <chris.mason@oracle.com>2008-09-25 17:04:05 +0200
commit9ba4611a3a7902c6bad70c5c205de5161fcfc17b (patch)
tree6e4032526a727935600439fb8791a864218d7124 /fs/btrfs/ordered-data.h
parentBtrfs: Take the csum mutex while reading checksums (diff)
downloadlinux-9ba4611a3a7902c6bad70c5c205de5161fcfc17b.tar.xz
linux-9ba4611a3a7902c6bad70c5c205de5161fcfc17b.zip
Btrfs: Fix 32 bit compiles by using an unsigned long byte count in the ordered extent
The ordered extents have to fit in memory, so an unsigned long is sufficient. Signed-off-by: Chris Mason <chris.mason@oracle.com>
Diffstat (limited to 'fs/btrfs/ordered-data.h')
-rw-r--r--fs/btrfs/ordered-data.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/btrfs/ordered-data.h b/fs/btrfs/ordered-data.h
index 36e63f1f79b3..199cb0b4f1d9 100644
--- a/fs/btrfs/ordered-data.h
+++ b/fs/btrfs/ordered-data.h
@@ -95,7 +95,8 @@ struct btrfs_ordered_extent {
* calculates the total size you need to allocate for an ordered sum
* structure spanning 'bytes' in the file
*/
-static inline int btrfs_ordered_sum_size(struct btrfs_root *root, u64 bytes)
+static inline int btrfs_ordered_sum_size(struct btrfs_root *root,
+ unsigned long bytes)
{
unsigned long num_sectors = (bytes + root->sectorsize - 1) /
root->sectorsize;