lkml.org 
[lkml]   [2023]   [Jan]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [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.

\
 
 \ /
  Last update: 2023-03-26 23:47    [W:0.131 / U:0.020 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site