xfs
[Top] [All Lists]

Re: [PATCH v2] xfs: lobotomise xfs_trans_read_buf_map()

To: Dave Chinner <david@xxxxxxxxxxxxx>
Subject: Re: [PATCH v2] xfs: lobotomise xfs_trans_read_buf_map()
From: Christoph Hellwig <hch@xxxxxxxxxxxxx>
Date: Wed, 3 Dec 2014 02:53:41 -0800
Cc: Christoph Hellwig <hch@xxxxxxxxxxxxx>, xfs@xxxxxxxxxxx
Delivered-to: xfs@xxxxxxxxxxx
In-reply-to: <20141202230706.GH18131@dastard>
References: <1417473290-17544-1-git-send-email-david@xxxxxxxxxxxxx> <20141202165930.GA28571@xxxxxxxxxxxxx> <20141202224518.GG18131@dastard> <20141202230706.GH18131@dastard>
User-agent: Mutt/1.5.23 (2014-03-12)
>  /*
>   * Get and lock the buffer for the caller if it is not already
>   * locked within the given transaction.  If it has not yet been
> @@ -255,46 +248,11 @@ xfs_trans_read_buf_map(
>       struct xfs_buf          **bpp,
>       const struct xfs_buf_ops *ops)
>  {
> -     xfs_buf_t               *bp;
> -     xfs_buf_log_item_t      *bip;
> +     struct xfs_buf          *bp = NULL;
> +     struct xfs_buf_log_item *bip;
>       int                     error;
>  
>       *bpp = NULL;
> +     /*
> +      * If we've had a read error, then the contents of the buffer are
> +      * invalid and shoul dnot be used. To ensure that a followup read tries

                        should not

Otherwise looks fine,

Reviewed-by: Christoph Hellwig <hch@xxxxxx>

<Prev in Thread] Current Thread [Next in Thread>