提交 8791d432 编写于 作者: D David Sterba

btrfs: use round_up wrapper in num_extent_pages

Reviewed-by: NNikolay Borisov <nborisov@suse.com>
Signed-off-by: NDavid Sterba <dsterba@suse.com>
上级 65ad0104
......@@ -442,8 +442,8 @@ void wait_on_extent_buffer_writeback(struct extent_buffer *eb);
static inline unsigned long num_extent_pages(const struct extent_buffer *eb)
{
return ((eb->start + eb->len + PAGE_SIZE - 1) >> PAGE_SHIFT) -
(eb->start >> PAGE_SHIFT);
return (round_up(eb->start + eb->len, PAGE_SIZE) >> PAGE_SHIFT) -
(eb->start >> PAGE_SHIFT);
}
static inline void extent_buffer_get(struct extent_buffer *eb)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册