From: Amit Shah <amit.shah@qumranet.com>
To: Muli Ben-Yehuda <muli@il.ibm.com>
Cc: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>,
linux-kernel@vger.kernel.org, akpm@linux-foundation.org,
alexisb@us.ibm.com, andi@firstfloor.org, kvm@vger.kernel.org,
avi@qumranet.com
Subject: Re: [PATCH v2 -mm 0/2] x86: per-device dma_mapping_ops
Date: Mon, 26 May 2008 09:39:20 +0530 [thread overview]
Message-ID: <200805260939.21320.amit.shah@qumranet.com> (raw)
In-Reply-To: <20080525072011.GM7334@il.ibm.com>
On Sunday 25 May 2008 12:50:11 Muli Ben-Yehuda wrote:
> On Thu, May 22, 2008 at 04:13:02PM +0530, Amit Shah wrote:
> > OK; this sounds helpful. the hook can make a hypercall and confirm
> > with the host kernel if the device in question is an assigned
> > physical device. If yes, we replace the dma_ops. Though, the
> > original intent of having stackable ops is that we might want to go
> > through the swiotlb in the guest even for an assigned device if the
> > guest dma addresses are not in the addressable range of the guest
> > chipset.
> >
> > > created (it works with hot plugging). It enables IOMMUs to set up an
> > > appropriate dma_mapping_ops per device.
> >
> > From what we've discussed so far, it looks like stackable dma ops will
> > definitely be needed. Does this patchset provide something that stacking
> > won't?
>
> Yes---this patchset let's you have a per-device dma-ops, whereas with
> stackable you only get global dma-ops. I think it's clear we need
> both, and I think per-device dma-ops are the first thing that's
> needed. Stacking can then be introduced on a per-device basis.
When we would want stacking, we'll want it globally and not per-device, isn't
it? Or at least for devices on a particular bus.
When an IOMMU driver registers itself, it should tell which devices it's
interested in (each device behind a bus or by enumerating each device it
cares for). This should take care of all the scenarios and we won't have the
need for per-device dma_ops.
For something like pvdma, we can walk through the list of pci devices and make
a hypercall for each of them to get this information and have the pvdma
version of dma_ops registered for that device. This sounds like it's
per-device dma_ops, but it's not -- internally, the dma operations walk
through each of the IOMMUs registered and call them in sequence.
Does this work?
next prev parent reply other threads:[~2008-05-26 4:06 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-05-19 6:31 FUJITA Tomonori
2008-05-19 6:31 ` [PATCH v2 -mm 1/2] add the device argument to dma_mapping_error FUJITA Tomonori
2008-05-19 6:31 ` [PATCH v2 -mm 2/2] x86: per-device dma_mapping_ops support FUJITA Tomonori
2008-07-02 10:07 ` [PATCH v2 -mm 1/2] add the device argument to dma_mapping_error Andrew Morton
2008-07-02 10:18 ` Michael Buesch
2008-07-02 10:20 ` Michael Buesch
2008-07-02 10:41 ` Andrew Morton
2008-05-22 10:43 ` [PATCH v2 -mm 0/2] x86: per-device dma_mapping_ops Amit Shah
2008-05-25 7:20 ` Muli Ben-Yehuda
2008-05-26 4:09 ` Amit Shah [this message]
2008-05-26 6:11 ` FUJITA Tomonori
2008-05-26 16:44 ` Amit Shah
2008-05-26 23:50 ` FUJITA Tomonori
2008-05-27 4:53 ` Amit Shah
2008-05-27 5:24 ` FUJITA Tomonori
2008-05-27 5:54 ` Amit Shah
2008-05-28 10:19 ` FUJITA Tomonori
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200805260939.21320.amit.shah@qumranet.com \
--to=amit.shah@qumranet.com \
--cc=akpm@linux-foundation.org \
--cc=alexisb@us.ibm.com \
--cc=andi@firstfloor.org \
--cc=avi@qumranet.com \
--cc=fujita.tomonori@lab.ntt.co.jp \
--cc=kvm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=muli@il.ibm.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®