[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <ZJkL9TRyIfcnUjIt@casper.infradead.org>
Date: Mon, 26 Jun 2023 04:54:29 +0100
From: Matthew Wilcox <willy@...radead.org>
To: Lu Hongfei <luhongfei@...o.com>
Cc: Christoph Hellwig <hch@...radead.org>,
"Darrick J. Wong" <djwong@...nel.org>, linux-xfs@...r.kernel.org,
linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org,
opensource.kernel@...o.com
Subject: Re: [PATCH] fs: iomap: replace the ternary conditional operator with
max_t()
On Mon, Jun 26, 2023 at 10:22:12AM +0800, Lu Hongfei wrote:
> It would be better to replace the traditional ternary conditional
> operator with max_t() in iomap_iter
No it wouldn't.
There are two possible meanings for iter->processed. Either we
processed a positive number of bytes, or it's an errno. max_t()
doesn't express that. Your patch adds confusion, not reduces it.
Powered by blists - more mailing lists