[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Y88OUobZeJH2ak+s@casper.infradead.org>
Date: Mon, 23 Jan 2023 22:46:42 +0000
From: Matthew Wilcox <willy@...radead.org>
To: Dan Williams <dan.j.williams@...el.com>
Cc: nvdimm@...ts.linux.dev, lsf-pc@...ts.linuxfoundation.org,
linux-rdma@...r.kernel.org, John Hubbard <jhubbard@...dia.com>,
dri-devel@...ts.freedesktop.org, Ming Lei <ming.lei@...hat.com>,
linux-block@...r.kernel.org, linux-mm@...ck.org,
iommu@...ts.linux.dev, netdev@...r.kernel.org,
Joao Martins <joao.m.martins@...cle.com>,
Jason Gunthorpe via Lsf-pc
<lsf-pc@...ts.linux-foundation.org>,
Logan Gunthorpe <logang@...tatee.com>,
Christoph Hellwig <hch@....de>
Subject: Re: [Lsf-pc] [LSF/MM/BPF proposal]: Physr discussion
On Mon, Jan 23, 2023 at 12:50:52PM -0800, Dan Williams wrote:
> Matthew Wilcox wrote:
> > On Mon, Jan 23, 2023 at 11:36:51AM -0800, Dan Williams wrote:
> > > Jason Gunthorpe via Lsf-pc wrote:
> > > > I would like to have a session at LSF to talk about Matthew's
> > > > physr discussion starter:
> > > >
> > > > https://lore.kernel.org/linux-mm/YdyKWeU0HTv8m7wD@casper.infradead.org/
> > > >
> > > > I have become interested in this with some immediacy because of
> > > > IOMMUFD and this other discussion with Christoph:
> > > >
> > > > https://lore.kernel.org/kvm/4-v2-472615b3877e+28f7-vfio_dma_buf_jgg@nvidia.com/
> > >
> > > I think this is a worthwhile discussion. My main hangup with 'struct
> > > page' elimination in general is that if anything needs to be allocated
> >
> > You're the first one to bring up struct page elimination. Neither Jason
> > nor I have that as our motivation.
>
> Oh, ok, then maybe I misread the concern in the vfio discussion. I
> thought the summary there is debating the ongoing requirement for
> 'struct page' for P2PDMA?
My reading of that thread is that while it started out that way, it
became more about "So what would a good interface be for doing this". And
Jason's right, he and I are approaching this from different directions.
My concern is from the GUP side where we start out by getting a folio
(which we know is physically contiguous) and decomposing it into pages.
Then we aggregate all those pages together which are physically contiguous
and stuff them into a bio_vec. After that, I lose interest; I was
planning on having DMA mapping interfaces which took in an array of
phyr and spat out scatterlists. Then we could shrink the scatterlist
by removing page_link and offset, leaving us with only dma_address,
length and maybe flags.
Powered by blists - more mailing lists