Message ID | ec568a627d58773eb088b3ad5b1417d8ce540a9d.1695812791.git.fdmanana@suse.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | btrfs: some fixes and cleanups around btrfs_cow_block() | expand |
diff --git a/fs/btrfs/ctree.c b/fs/btrfs/ctree.c index a05c9204928e..8d29b9e09286 100644 --- a/fs/btrfs/ctree.c +++ b/fs/btrfs/ctree.c @@ -712,7 +712,7 @@ int btrfs_cow_block(struct btrfs_trans_handle *trans, return 0; } - search_start = buf->start & ~((u64)SZ_1G - 1); + search_start = round_down(buf->start, SZ_1G); /* * Before CoWing this block for later modification, check if it's