bcachefs: Reflink now respects quotas
authorKent Overstreet <kent.overstreet@linux.dev>
Tue, 11 Oct 2022 08:32:14 +0000 (04:32 -0400)
committerKent Overstreet <kent.overstreet@linux.dev>
Sun, 22 Oct 2023 21:09:43 +0000 (17:09 -0400)
commite8540e56812360d4253b6a30e46452ce7448b24b
treea11f21dfa9fc04ce338b3471e4873d966172c5f5
parentf42238b5cde2f1624b2be5f64c813e6127a8012a
bcachefs: Reflink now respects quotas

This adds a new helper, quota_reserve_range(), which takes a quota
reservation for unallocated blocks in a given file range, and uses it in
bch2_remap_file_range().

Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
fs/bcachefs/fs-io.c