On Sun, Oct 06, 2019 at 05:46:05PM +0200, Christoph Hellwig wrote:
> In preparation for moving the XFS writeback code to fs/iomap.c, switch
> it to use struct iomap instead of the XFS-specific struct xfs_bmbt_irec.
> 
> Signed-off-by: Christoph Hellwig <h...@lst.de>
> Reviewed-by: Carlos Maiolino <cmaiol...@redhat.com>
> Reviewed-by: Darrick J. Wong <darrick.w...@oracle.com>
> ---
>  fs/xfs/libxfs/xfs_bmap.c | 14 +++++--
>  fs/xfs/libxfs/xfs_bmap.h |  3 +-
>  fs/xfs/xfs_aops.c        | 82 +++++++++++++++++++---------------------
>  fs/xfs/xfs_aops.h        |  2 +-
>  4 files changed, 50 insertions(+), 51 deletions(-)
> 
> diff --git a/fs/xfs/libxfs/xfs_bmap.c b/fs/xfs/libxfs/xfs_bmap.c
> index 4edc25a2ba80..d0e7f9ef7b85 100644
> --- a/fs/xfs/libxfs/xfs_bmap.c
> +++ b/fs/xfs/libxfs/xfs_bmap.c
> @@ -34,6 +34,7 @@
>  #include "xfs_ag_resv.h"
>  #include "xfs_refcount.h"
>  #include "xfs_icache.h"
> +#include "xfs_iomap.h"
>  
>  
>  kmem_zone_t          *xfs_bmap_free_item_zone;
> @@ -4454,16 +4455,21 @@ int
>  xfs_bmapi_convert_delalloc(
>       struct xfs_inode        *ip,
>       int                     whichfork,
> -     xfs_fileoff_t           offset_fsb,
> -     struct xfs_bmbt_irec    *imap,
> +     xfs_off_t               offset,
> +     struct iomap            *iomap,
>       unsigned int            *seq)
>  {
>       struct xfs_ifork        *ifp = XFS_IFORK_PTR(ip, whichfork);
>       struct xfs_mount        *mp = ip->i_mount;
> +     xfs_fileoff_t           offset_fsb = XFS_B_TO_FSBT(mp, offset);
>       struct xfs_bmalloca     bma = { NULL };
> +     u16                     flags = 0;
>       struct xfs_trans        *tp;
>       int                     error;
>  
> +     if (whichfork == XFS_COW_FORK)
> +             flags |= IOMAP_F_SHARED;

That seems out of place - I don't see anywhere in this patch that
moves/removes setting the IOMAP_F_SHARED flag. i.e this looks like a
change of behaviour....

Cheers,

Dave.
-- 
Dave Chinner
da...@fromorbit.com

Reply via email to