qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] Are there any IOMMU emulation in QEMU for x86 platform
@ 2013-11-19  6:34 Jiang, Yunhong
  2013-11-19  9:13 ` Paolo Bonzini
  0 siblings, 1 reply; 4+ messages in thread
From: Jiang, Yunhong @ 2013-11-19  6:34 UTC (permalink / raw)
  To: qemu-devel@nongnu.org
  Cc: david@gibson.dropbear.id.au, eduard.munteanu@linux360.ro

Hi, all
	I noticed there are several patchset has been sent out about IOMMU emulation like http://lists.gnu.org/archive/html/qemu-devel/2011-10/msg03764.html, http://lists.gnu.org/archive/html/qemu-devel/2011-01/msg03196.html . Also I noticed that PPC platform has IOMMU emulation support in QEMU already. Are there any plan to support IOMMU emulation in QEMU for x86 now? 

	And also, does it requires the real host platform have the IOMMU to support the QEMU IOMMU emulation? Or it will be a purely software emulation?

Thanks
--jyh 

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Qemu-devel] Are there any IOMMU emulation in QEMU for x86 platform
  2013-11-19  6:34 [Qemu-devel] Are there any IOMMU emulation in QEMU for x86 platform Jiang, Yunhong
@ 2013-11-19  9:13 ` Paolo Bonzini
  2013-11-20  0:01   ` Jiang, Yunhong
  0 siblings, 1 reply; 4+ messages in thread
From: Paolo Bonzini @ 2013-11-19  9:13 UTC (permalink / raw)
  To: Jiang, Yunhong
  Cc: eduard.munteanu@linux360.ro, qemu-devel@nongnu.org,
	david@gibson.dropbear.id.au

Il 19/11/2013 07:34, Jiang, Yunhong ha scritto:
> Hi, all
> I noticed there are several patchset has been sent out about IOMMU emulation like
> http://lists.gnu.org/archive/html/qemu-devel/2011-10/msg03764.html,
> http://lists.gnu.org/archive/html/qemu-devel/2011-01/msg03196.html .
> Also I noticed that PPC platform has IOMMU emulation support in QEMU
> already. Are there any plan to support IOMMU emulation in QEMU for x86 now?

Not that I know of.  Of course, patches are welcome.

> 	And also, does it requires the real host platform have the IOMMU to support the QEMU IOMMU emulation? Or it will be a purely software emulation?

For emulated devices it could be purely software.  Nested device
assignment would require a host IOMMU, and would require the host IOMMU
driver to do some kind of shadow-paging.

Paolo

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Qemu-devel] Are there any IOMMU emulation in QEMU for x86 platform
  2013-11-19  9:13 ` Paolo Bonzini
@ 2013-11-20  0:01   ` Jiang, Yunhong
  2013-12-02  9:37     ` Knut Omang
  0 siblings, 1 reply; 4+ messages in thread
From: Jiang, Yunhong @ 2013-11-20  0:01 UTC (permalink / raw)
  To: Paolo Bonzini
  Cc: eduard.munteanu@linux360.ro, qemu-devel@nongnu.org,
	david@gibson.dropbear.id.au



> -----Original Message-----
> From: Paolo Bonzini [mailto:paolo.bonzini@gmail.com] On Behalf Of Paolo
> Bonzini
> Sent: Tuesday, November 19, 2013 1:14 AM
> To: Jiang, Yunhong
> Cc: qemu-devel@nongnu.org; david@gibson.dropbear.id.au;
> eduard.munteanu@linux360.ro
> Subject: Re: Are there any IOMMU emulation in QEMU for x86 platform
> 
> Il 19/11/2013 07:34, Jiang, Yunhong ha scritto:
> > Hi, all
> > I noticed there are several patchset has been sent out about IOMMU
> emulation like
> > http://lists.gnu.org/archive/html/qemu-devel/2011-10/msg03764.html,
> > http://lists.gnu.org/archive/html/qemu-devel/2011-01/msg03196.html .
> > Also I noticed that PPC platform has IOMMU emulation support in QEMU
> > already. Are there any plan to support IOMMU emulation in QEMU for
> x86 now?
> 
> Not that I know of.  Of course, patches are welcome.

Paolo, thanks for reply.

--jyh

> 
> > 	And also, does it requires the real host platform have the IOMMU to
> support the QEMU IOMMU emulation? Or it will be a purely software
> emulation?
> 
> For emulated devices it could be purely software.  Nested device
> assignment would require a host IOMMU, and would require the host
> IOMMU
> driver to do some kind of shadow-paging.
> 
> Paolo

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Qemu-devel] Are there any IOMMU emulation in QEMU for x86 platform
  2013-11-20  0:01   ` Jiang, Yunhong
@ 2013-12-02  9:37     ` Knut Omang
  0 siblings, 0 replies; 4+ messages in thread
From: Knut Omang @ 2013-12-02  9:37 UTC (permalink / raw)
  To: Jiang, Yunhong
  Cc: Paolo Bonzini, david@gibson.dropbear.id.au, qemu-devel@nongnu.org,
	eduard.munteanu@linux360.ro


On Wed, 2013-11-20 at 00:01 +0000, Jiang, Yunhong wrote:
> 
> > -----Original Message-----
> > From: Paolo Bonzini [mailto:paolo.bonzini@gmail.com] On Behalf Of Paolo
> > Bonzini
> > Sent: Tuesday, November 19, 2013 1:14 AM
> > To: Jiang, Yunhong
> > Cc: qemu-devel@nongnu.org; david@gibson.dropbear.id.au;
> > eduard.munteanu@linux360.ro
> > Subject: Re: Are there any IOMMU emulation in QEMU for x86 platform
> > 
> > Il 19/11/2013 07:34, Jiang, Yunhong ha scritto:
> > > Hi, all
> > > I noticed there are several patchset has been sent out about IOMMU
> > emulation like
> > > http://lists.gnu.org/archive/html/qemu-devel/2011-10/msg03764.html,
> > > http://lists.gnu.org/archive/html/qemu-devel/2011-01/msg03196.html .
> > > Also I noticed that PPC platform has IOMMU emulation support in QEMU
> > > already. Are there any plan to support IOMMU emulation in QEMU for
> > x86 now?
> > 
> > Not that I know of.  Of course, patches are welcome.

I have been working on some code to emulate an Intel IOMMU - I have a
simple patch to SeaBIOS to provide a minimal DMAR table and skeleton
device code that answers about what the kernel would expect to the Intel IOMMU 
Linux driver boot a VM with intel_iommu=on 

I got as far as when I was going to try to figure out how to emulate the interrupt remapping 
which appears to be where the kernel gets stuck after I got past the initial setup 
and invalidation cycles.

Unfortunately I haven't had much time to work on it lately, but I'll be
happy to share what I have so far. I have created branches of qemu and seabios here:

git://github.com/knuto/seabios.git
git://github.com/knuto/qemu.git

> > > 	And also, does it requires the real host platform have the IOMMU to
> > support the QEMU IOMMU emulation? Or it will be a purely software
> > emulation?
> > 
> > For emulated devices it could be purely software.  

I picture that the way forward should include some way of adapting to
what "real" hardware that exists and use the "best" approach from that.

> > Nested device
> > assignment would require a host IOMMU, and would require the host
> > IOMMU driver to do some kind of shadow-paging.
> > 
> > Paolo
> 

Knut Omang

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2013-12-02  9:38 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-11-19  6:34 [Qemu-devel] Are there any IOMMU emulation in QEMU for x86 platform Jiang, Yunhong
2013-11-19  9:13 ` Paolo Bonzini
2013-11-20  0:01   ` Jiang, Yunhong
2013-12-02  9:37     ` Knut Omang

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).