diff options
author | Thomas Zimmermann <tzimmermann@suse.de> | 2025-02-18 09:43:43 +0300 |
---|---|---|
committer | Thomas Zimmermann <tzimmermann@suse.de> | 2025-02-18 09:43:43 +0300 |
commit | 8bd1a8e7572c1012b19e4f57e2f49451820167ef (patch) | |
tree | d3e324f78d3b3bb7cf244be9c09ee463afd0ff7e /fs/xfs/libxfs/xfs_bmap.c | |
parent | b296955b3a740ecc8b3b08e34fd64f1ceabb8fb4 (diff) | |
parent | 0ed1356af8f629ae807963b7db4e501e3b580bc2 (diff) | |
download | linux-8bd1a8e7572c1012b19e4f57e2f49451820167ef.tar.xz |
Merge drm/drm-next into drm-misc-next
Backmerging to get bugfixes from v6.14-rc2.
Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
Diffstat (limited to 'fs/xfs/libxfs/xfs_bmap.c')
-rw-r--r-- | fs/xfs/libxfs/xfs_bmap.c | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/fs/xfs/libxfs/xfs_bmap.c b/fs/xfs/libxfs/xfs_bmap.c index 40ad22fb808b..0ef19f1469ec 100644 --- a/fs/xfs/libxfs/xfs_bmap.c +++ b/fs/xfs/libxfs/xfs_bmap.c @@ -3563,12 +3563,12 @@ xfs_bmap_btalloc_at_eof( int error; /* - * If there are already extents in the file, try an exact EOF block - * allocation to extend the file as a contiguous extent. If that fails, - * or it's the first allocation in a file, just try for a stripe aligned - * allocation. + * If there are already extents in the file, and xfs_bmap_adjacent() has + * given a better blkno, try an exact EOF block allocation to extend the + * file as a contiguous extent. If that fails, or it's the first + * allocation in a file, just try for a stripe aligned allocation. */ - if (ap->offset) { + if (ap->eof) { xfs_extlen_t nextminlen = 0; /* @@ -3736,7 +3736,8 @@ xfs_bmap_btalloc_best_length( int error; ap->blkno = XFS_INO_TO_FSB(args->mp, ap->ip->i_ino); - xfs_bmap_adjacent(ap); + if (!xfs_bmap_adjacent(ap)) + ap->eof = false; /* * Search for an allocation group with a single extent large enough for |