diff options
author | Satoru Takeuchi <takeuchi_satoru@jp.fujitsu.com> | 2014-07-25 08:07:48 (GMT) |
---|---|---|
committer | Chris Mason <clm@fb.com> | 2014-09-17 20:37:54 (GMT) |
commit | d1b00a4711d5b953b13ccc859bc30c447c96860e (patch) | |
tree | c5bd1a2a8a05d25316648577cd46679388b684f4 /fs | |
parent | 1a76e4ba5b18775e532faa4f8eb858c4553d196c (diff) | |
download | linux-d1b00a4711d5b953b13ccc859bc30c447c96860e.tar.xz |
btrfs: use IS_ALIGNED() for assertion in btrfs_lookup_csums_range() for simplicity
btrfs_lookup_csums_range() uses ALIGN() to check if "start"
and "end + 1" are aligned to "root->sectorsize". It's better to
replace these with IS_ALIGNED() for simplicity.
Signed-off-by: Satoru Takeuchi <takeuchi_satoru@jp.fujitsu.com>
Signed-off-by: Chris Mason <clm@fb.com>
Diffstat (limited to 'fs')
-rw-r--r-- | fs/btrfs/file-item.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/btrfs/file-item.c b/fs/btrfs/file-item.c index 991f056..6e6262e 100644 --- a/fs/btrfs/file-item.c +++ b/fs/btrfs/file-item.c @@ -329,8 +329,8 @@ int btrfs_lookup_csums_range(struct btrfs_root *root, u64 start, u64 end, u64 csum_end; u16 csum_size = btrfs_super_csum_size(root->fs_info->super_copy); - ASSERT(start == ALIGN(start, root->sectorsize) && - (end + 1) == ALIGN(end + 1, root->sectorsize)); + ASSERT(IS_ALIGNED(start, root->sectorsize) && + IS_ALIGNED(end + 1, root->sectorsize)); path = btrfs_alloc_path(); if (!path) |