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: <Y8jZVNfeo3LWsIpV@infradead.org>
Date:   Wed, 18 Jan 2023 21:47:00 -0800
From:   Christoph Hellwig <hch@...radead.org>
To:     Al Viro <viro@...iv.linux.org.uk>
Cc:     Christoph Hellwig <hch@...radead.org>,
        David Howells <dhowells@...hat.com>,
        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,
        Peter Zijlstra <peterz@...radead.org>,
        David Hildenbrand <david@...hat.com>
Subject: Re: [PATCH v6 03/34] iov_iter: Pass I/O direction into
 iov_iter_get_pages*()

On Thu, Jan 19, 2023 at 12:15:44AM +0000, Al Viro wrote:
> Actually, looking at that thing...  Currently we use it only for
> FOLL_PCI_P2PDMA.  It alters behaviour of get_user_pages_fast(), but...
> it is completely ignored for ITER_BVEC or ITER_PIPE.  So how the
> hell is it supposed to work?

It broadens the acceptance criteria for UBUF/IOVEC types.  It doesn't
change behavior for already accepted memory for those or any others.

> Could somebody give a braindump on that thing?  It looks like we
> have pages that should not be DMA'd to/from unless driver takes
> some precautions and we want to make sure they won't be fed to
> drivers that don't take such.  With checks done in a very odd
> place...

Yes, normal gup excludes P2P pages.  This flag allows it to get them.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ