xfs
[Top] [All Lists]

Re: [PATCH] xfs: don't allocate an ioend for direct I/O completions

To: Dave Chinner <david@xxxxxxxxxxxxx>
Subject: Re: [PATCH] xfs: don't allocate an ioend for direct I/O completions
From: Christoph Hellwig <hch@xxxxxx>
Date: Mon, 2 Feb 2015 08:27:16 +0100
Cc: Brian Foster <bfoster@xxxxxxxxxx>, Christoph Hellwig <hch@xxxxxx>, xfs@xxxxxxxxxxx
Delivered-to: xfs@xxxxxxxxxxx
In-reply-to: <20150201230403.GD4251@dastard>
References: <1422485661-520-1-git-send-email-hch@xxxxxx> <20150130144223.GA27441@xxxxxxxxxxxxxx> <20150201230403.GD4251@dastard>
User-agent: Mutt/1.5.17 (2007-11-01)
On Mon, Feb 02, 2015 at 10:04:03AM +1100, Dave Chinner wrote:
> > A nit, but I guess you could kill the braces here now too.
> 
> Given it's a multi-line return statement, the braces are fine. FWIW,
> when we have a if () { return ...} else { return ... } we normally
> kill the else. i.e:
> 
>       if (rw & WRITE) {
>               return foo(
>                       bar,
>                       baz);
>       }
>       return .....;
> 
> So I modified it like this.

For an if/else that is 100% symmetric like read vs write I prefer
to keep the else, otherwise I agree.  But in the end it's a very
minor point, so it doesn't really matter.

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