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] [thread-next>] [day] [month] [year] [list]
Message-ID: <Y8ZUXEB/W+K0Jt6k@infradead.org>
Date:   Mon, 16 Jan 2023 23:55:08 -0800
From:   Christoph Hellwig <hch@...radead.org>
To:     David Howells <dhowells@...hat.com>
Cc:     Al Viro <viro@...iv.linux.org.uk>,
        Christoph Hellwig <hch@...radead.org>,
        Matthew Wilcox <willy@...radead.org>,
        Jens Axboe <axboe@...nel.dk>, Jan Kara <jack@...e.cz>,
        Jeff Layton <jlayton@...nel.org>,
        Logan Gunthorpe <logang@...tatee.com>,
        linux-fsdevel@...r.kernel.org, linux-block@...r.kernel.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH v6 02/34] iov_iter: Use IOCB/IOMAP_WRITE/op_is_write
 rather than iterator direction

On Mon, Jan 16, 2023 at 11:08:17PM +0000, David Howells wrote:
> Use information other than the iterator direction to determine the
> direction of the I/O:
> 
>  (*) If a kiocb is available, use the IOCB_WRITE flag.
> 
>  (*) If an iomap_iter is available, use the IOMAP_WRITE flag.
> 
>  (*) If a request is available, use op_is_write().

The really should be three independent patches.  Plus another one
to drop the debug checks in cifs.

The changes themselves look good to me.

>  
> +static unsigned char iov_iter_rw(const struct iov_iter *i)
> +{
> +	return i->data_source ? WRITE : READ;
> +}

It might as well make sense to just open code this in the only
caller as well (yet another patch).

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ