summaryrefslogtreecommitdiff
path: root/fs/btrfs/inode.c
diff options
context:
space:
mode:
authorIngo Molnar <mingo@kernel.org>2025-03-08 20:09:27 +0100
committerIngo Molnar <mingo@kernel.org>2025-03-08 20:09:27 +0100
commit14296d0e85d45695ad2dc65b653b29e5a3514cdb (patch)
treec5d875755a94e8fa9d671d0cdd6f1e4755318698 /fs/btrfs/inode.c
parent6914f7e2e25fac9d1d2b62c208eaa5f2bf810fe9 (diff)
parent21e4543a2e2f8538373d1d19264c4bae6f13e798 (diff)
Merge branch 'linus' into x86/urgent, to pick up dependent patches
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'fs/btrfs/inode.c')
-rw-r--r--fs/btrfs/inode.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c
index a9322601ab5c..38756f8cef46 100644
--- a/fs/btrfs/inode.c
+++ b/fs/btrfs/inode.c
@@ -1382,8 +1382,13 @@ static noinline int cow_file_range(struct btrfs_inode *inode,
continue;
}
if (done_offset) {
- *done_offset = start - 1;
- return 0;
+ /*
+ * Move @end to the end of the processed range,
+ * and exit the loop to unlock the processed extents.
+ */
+ end = start - 1;
+ ret = 0;
+ break;
}
ret = -ENOSPC;
}