lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<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

Powered by Openwall GNU/*/Linux Powered by OpenVZ