diff options
-rw-r--r-- | fs/btrfs/file.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/btrfs/file.c b/fs/btrfs/file.c index 20452c110d7d..fa48051484b8 100644 --- a/fs/btrfs/file.c +++ b/fs/btrfs/file.c | |||
@@ -2242,6 +2242,7 @@ static int find_desired_extent(struct inode *inode, loff_t *offset, int origin) | |||
2242 | if (lockend <= lockstart) | 2242 | if (lockend <= lockstart) |
2243 | lockend = lockstart + root->sectorsize; | 2243 | lockend = lockstart + root->sectorsize; |
2244 | 2244 | ||
2245 | lockend--; | ||
2245 | len = lockend - lockstart + 1; | 2246 | len = lockend - lockstart + 1; |
2246 | 2247 | ||
2247 | len = max_t(u64, len, root->sectorsize); | 2248 | len = max_t(u64, len, root->sectorsize); |