Re: [RESEND PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-07-29 Thread Joerg Roedel
On Thu, Jul 03, 2014 at 09:57:02AM -0600, Alex Williamson wrote: > The user of the IOMMU API domain expects to have full control of > the IOVA space for the domain. RMRRs are fundamentally incompatible > with that idea. We can neither map the RMRR into the IOMMU API > domain, nor can we

Re: [RESEND PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-07-29 Thread Joerg Roedel
On Thu, Jul 03, 2014 at 09:57:02AM -0600, Alex Williamson wrote: The user of the IOMMU API domain expects to have full control of the IOVA space for the domain. RMRRs are fundamentally incompatible with that idea. We can neither map the RMRR into the IOMMU API domain, nor can we guarantee

[RESEND PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-07-03 Thread Alex Williamson
The user of the IOMMU API domain expects to have full control of the IOVA space for the domain. RMRRs are fundamentally incompatible with that idea. We can neither map the RMRR into the IOMMU API domain, nor can we guarantee that the device won't continue DMA with the area described by the RMRR

[RESEND PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-07-03 Thread Alex Williamson
The user of the IOMMU API domain expects to have full control of the IOVA space for the domain. RMRRs are fundamentally incompatible with that idea. We can neither map the RMRR into the IOMMU API domain, nor can we guarantee that the device won't continue DMA with the area described by the RMRR

Re: [Intel-gfx] [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-19 Thread Daniel Vetter
On Thu, Jun 19, 2014 at 4:29 PM, Alex Williamson wrote: > But is there a way for software to discover its location from the > device? If so, then I think we can recreate all the identity maps we'd > need for a guest from the device. If not, then we'd need to figure out > some IOMMU API

Re: [Intel-gfx] [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-19 Thread Alex Williamson
On Thu, 2014-06-19 at 08:10 +0200, Daniel Vetter wrote: > On Thu, Jun 19, 2014 at 3:47 AM, Alex Williamson > wrote: > > Finding some more specs... the MGGC0 register (50h) seems to indicate > > the GTT stolen memory size is 2M, which sounds suspiciously like the 2M > > that the RMRR is reporting.

Re: [Intel-gfx] [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-19 Thread Daniel Vetter
On Thu, Jun 19, 2014 at 3:47 AM, Alex Williamson wrote: > Finding some more specs... the MGGC0 register (50h) seems to indicate > the GTT stolen memory size is 2M, which sounds suspiciously like the 2M > that the RMRR is reporting. However, from the IvyBridge MMIO, Media > Registers &

Re: [Intel-gfx] [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-19 Thread Daniel Vetter
On Thu, Jun 19, 2014 at 3:47 AM, Alex Williamson alex.william...@redhat.com wrote: Finding some more specs... the MGGC0 register (50h) seems to indicate the GTT stolen memory size is 2M, which sounds suspiciously like the 2M that the RMRR is reporting. However, from the IvyBridge MMIO, Media

Re: [Intel-gfx] [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-19 Thread Alex Williamson
On Thu, 2014-06-19 at 08:10 +0200, Daniel Vetter wrote: On Thu, Jun 19, 2014 at 3:47 AM, Alex Williamson alex.william...@redhat.com wrote: Finding some more specs... the MGGC0 register (50h) seems to indicate the GTT stolen memory size is 2M, which sounds suspiciously like the 2M that the

Re: [Intel-gfx] [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-19 Thread Daniel Vetter
On Thu, Jun 19, 2014 at 4:29 PM, Alex Williamson alex.william...@redhat.com wrote: But is there a way for software to discover its location from the device? If so, then I think we can recreate all the identity maps we'd need for a guest from the device. If not, then we'd need to figure out

Re: [Intel-gfx] [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-18 Thread Alex Williamson
On Wed, 2014-06-18 at 15:48 -0600, Alex Williamson wrote: > On Tue, 2014-06-17 at 15:44 +0200, Daniel Vetter wrote: > > On Tue, Jun 17, 2014 at 07:16:22AM -0600, Alex Williamson wrote: > > > On Tue, 2014-06-17 at 13:41 +0100, David Woodhouse wrote: > > > > On Tue, 2014-06-17 at 06:22 -0600, Alex

Re: [Intel-gfx] [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-18 Thread Alex Williamson
On Tue, 2014-06-17 at 15:44 +0200, Daniel Vetter wrote: > On Tue, Jun 17, 2014 at 07:16:22AM -0600, Alex Williamson wrote: > > On Tue, 2014-06-17 at 13:41 +0100, David Woodhouse wrote: > > > On Tue, 2014-06-17 at 06:22 -0600, Alex Williamson wrote: > > > > On Tue, 2014-06-17 at 08:04 +0100, David

Re: [Intel-gfx] [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-18 Thread Alex Williamson
On Tue, 2014-06-17 at 15:44 +0200, Daniel Vetter wrote: On Tue, Jun 17, 2014 at 07:16:22AM -0600, Alex Williamson wrote: On Tue, 2014-06-17 at 13:41 +0100, David Woodhouse wrote: On Tue, 2014-06-17 at 06:22 -0600, Alex Williamson wrote: On Tue, 2014-06-17 at 08:04 +0100, David Woodhouse

Re: [Intel-gfx] [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-18 Thread Alex Williamson
On Wed, 2014-06-18 at 15:48 -0600, Alex Williamson wrote: On Tue, 2014-06-17 at 15:44 +0200, Daniel Vetter wrote: On Tue, Jun 17, 2014 at 07:16:22AM -0600, Alex Williamson wrote: On Tue, 2014-06-17 at 13:41 +0100, David Woodhouse wrote: On Tue, 2014-06-17 at 06:22 -0600, Alex Williamson

Re: [Intel-gfx] [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-17 Thread Daniel Vetter
On Tue, Jun 17, 2014 at 10:59:51AM -0600, Alex Williamson wrote: > On Tue, 2014-06-17 at 18:45 +0200, Daniel Vetter wrote: > > On Tue, Jun 17, 2014 at 08:15:47AM -0600, Alex Williamson wrote: > > > On Tue, 2014-06-17 at 15:44 +0200, Daniel Vetter wrote: > > > > On Tue, Jun 17, 2014 at 07:16:22AM

Re: [Intel-gfx] [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-17 Thread Alex Williamson
On Tue, 2014-06-17 at 18:45 +0200, Daniel Vetter wrote: > On Tue, Jun 17, 2014 at 08:15:47AM -0600, Alex Williamson wrote: > > On Tue, 2014-06-17 at 15:44 +0200, Daniel Vetter wrote: > > > On Tue, Jun 17, 2014 at 07:16:22AM -0600, Alex Williamson wrote: > > > > On Tue, 2014-06-17 at 13:41 +0100,

Re: [Intel-gfx] [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-17 Thread Daniel Vetter
On Tue, Jun 17, 2014 at 08:15:47AM -0600, Alex Williamson wrote: > On Tue, 2014-06-17 at 15:44 +0200, Daniel Vetter wrote: > > On Tue, Jun 17, 2014 at 07:16:22AM -0600, Alex Williamson wrote: > > > On Tue, 2014-06-17 at 13:41 +0100, David Woodhouse wrote: > > > > On Tue, 2014-06-17 at 06:22 -0600,

Re: [Intel-gfx] [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-17 Thread Alex Williamson
On Tue, 2014-06-17 at 15:44 +0200, Daniel Vetter wrote: > On Tue, Jun 17, 2014 at 07:16:22AM -0600, Alex Williamson wrote: > > On Tue, 2014-06-17 at 13:41 +0100, David Woodhouse wrote: > > > On Tue, 2014-06-17 at 06:22 -0600, Alex Williamson wrote: > > > > On Tue, 2014-06-17 at 08:04 +0100, David

Re: [Intel-gfx] [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-17 Thread Daniel Vetter
On Tue, Jun 17, 2014 at 07:16:22AM -0600, Alex Williamson wrote: > On Tue, 2014-06-17 at 13:41 +0100, David Woodhouse wrote: > > On Tue, 2014-06-17 at 06:22 -0600, Alex Williamson wrote: > > > On Tue, 2014-06-17 at 08:04 +0100, David Woodhouse wrote: > > > > On Mon, 2014-06-16 at 23:35 -0600, Alex

Re: [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-17 Thread Alex Williamson
On Tue, 2014-06-17 at 13:41 +0100, David Woodhouse wrote: > On Tue, 2014-06-17 at 06:22 -0600, Alex Williamson wrote: > > On Tue, 2014-06-17 at 08:04 +0100, David Woodhouse wrote: > > > On Mon, 2014-06-16 at 23:35 -0600, Alex Williamson wrote: > > > > > > > > Any idea what an off-the-shelf Asus

Re: [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-17 Thread David Woodhouse
On Tue, 2014-06-17 at 06:22 -0600, Alex Williamson wrote: > On Tue, 2014-06-17 at 08:04 +0100, David Woodhouse wrote: > > On Mon, 2014-06-16 at 23:35 -0600, Alex Williamson wrote: > > > > > > Any idea what an off-the-shelf Asus motherboard would be doing with an > > > RMRR on the Intel HD

Re: [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-17 Thread Alex Williamson
On Tue, 2014-06-17 at 08:04 +0100, David Woodhouse wrote: > On Mon, 2014-06-16 at 23:35 -0600, Alex Williamson wrote: > > > > Any idea what an off-the-shelf Asus motherboard would be doing with an > > RMRR on the Intel HD graphics? > > > > dmar: RMRR base: 0x00bb80 end: 0x00bf9f

Re: [Intel-gfx] [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-17 Thread Daniel Vetter
On Tue, Jun 17, 2014 at 08:21:31AM +0100, David Woodhouse wrote: > On Tue, 2014-06-17 at 09:15 +0200, Daniel Vetter wrote: > > We've always been struggling with stolen handling, and we've' always > > been struggling with vt-d stuff. Also pass-through seems to be a major > > pain (I've never tried

Re: [Intel-gfx] [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-17 Thread David Woodhouse
On Tue, 2014-06-17 at 09:15 +0200, Daniel Vetter wrote: > We've always been struggling with stolen handling, and we've' always > been struggling with vt-d stuff. Also pass-through seems to be a major > pain (I've never tried myself). Given all that I'm voting for keeping > the RMRR and everything

Re: [Intel-gfx] [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-17 Thread Daniel Vetter
On Tue, Jun 17, 2014 at 9:04 AM, David Woodhouse wrote: > On Mon, 2014-06-16 at 23:35 -0600, Alex Williamson wrote: >> >> Any idea what an off-the-shelf Asus motherboard would be doing with an >> RMRR on the Intel HD graphics? >> >> dmar: RMRR base: 0x00bb80 end: 0x00bf9f >>

Re: [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-17 Thread David Woodhouse
On Mon, 2014-06-16 at 23:35 -0600, Alex Williamson wrote: > > Any idea what an off-the-shelf Asus motherboard would be doing with an > RMRR on the Intel HD graphics? > > dmar: RMRR base: 0x00bb80 end: 0x00bf9f > IOMMU: Setting identity map for device :00:02.0 [0xbb80 -

Re: [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-17 Thread David Woodhouse
On Mon, 2014-06-16 at 23:35 -0600, Alex Williamson wrote: Any idea what an off-the-shelf Asus motherboard would be doing with an RMRR on the Intel HD graphics? dmar: RMRR base: 0x00bb80 end: 0x00bf9f IOMMU: Setting identity map for device :00:02.0 [0xbb80 -

Re: [Intel-gfx] [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-17 Thread Daniel Vetter
On Tue, Jun 17, 2014 at 9:04 AM, David Woodhouse dw...@infradead.org wrote: On Mon, 2014-06-16 at 23:35 -0600, Alex Williamson wrote: Any idea what an off-the-shelf Asus motherboard would be doing with an RMRR on the Intel HD graphics? dmar: RMRR base: 0x00bb80 end: 0x00bf9f

Re: [Intel-gfx] [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-17 Thread David Woodhouse
On Tue, 2014-06-17 at 09:15 +0200, Daniel Vetter wrote: We've always been struggling with stolen handling, and we've' always been struggling with vt-d stuff. Also pass-through seems to be a major pain (I've never tried myself). Given all that I'm voting for keeping the RMRR and everything else

Re: [Intel-gfx] [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-17 Thread Daniel Vetter
On Tue, Jun 17, 2014 at 08:21:31AM +0100, David Woodhouse wrote: On Tue, 2014-06-17 at 09:15 +0200, Daniel Vetter wrote: We've always been struggling with stolen handling, and we've' always been struggling with vt-d stuff. Also pass-through seems to be a major pain (I've never tried

Re: [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-17 Thread Alex Williamson
On Tue, 2014-06-17 at 08:04 +0100, David Woodhouse wrote: On Mon, 2014-06-16 at 23:35 -0600, Alex Williamson wrote: Any idea what an off-the-shelf Asus motherboard would be doing with an RMRR on the Intel HD graphics? dmar: RMRR base: 0x00bb80 end: 0x00bf9f IOMMU:

Re: [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-17 Thread David Woodhouse
On Tue, 2014-06-17 at 06:22 -0600, Alex Williamson wrote: On Tue, 2014-06-17 at 08:04 +0100, David Woodhouse wrote: On Mon, 2014-06-16 at 23:35 -0600, Alex Williamson wrote: Any idea what an off-the-shelf Asus motherboard would be doing with an RMRR on the Intel HD graphics?

Re: [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-17 Thread Alex Williamson
On Tue, 2014-06-17 at 13:41 +0100, David Woodhouse wrote: On Tue, 2014-06-17 at 06:22 -0600, Alex Williamson wrote: On Tue, 2014-06-17 at 08:04 +0100, David Woodhouse wrote: On Mon, 2014-06-16 at 23:35 -0600, Alex Williamson wrote: Any idea what an off-the-shelf Asus motherboard

Re: [Intel-gfx] [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-17 Thread Daniel Vetter
On Tue, Jun 17, 2014 at 07:16:22AM -0600, Alex Williamson wrote: On Tue, 2014-06-17 at 13:41 +0100, David Woodhouse wrote: On Tue, 2014-06-17 at 06:22 -0600, Alex Williamson wrote: On Tue, 2014-06-17 at 08:04 +0100, David Woodhouse wrote: On Mon, 2014-06-16 at 23:35 -0600, Alex

Re: [Intel-gfx] [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-17 Thread Alex Williamson
On Tue, 2014-06-17 at 15:44 +0200, Daniel Vetter wrote: On Tue, Jun 17, 2014 at 07:16:22AM -0600, Alex Williamson wrote: On Tue, 2014-06-17 at 13:41 +0100, David Woodhouse wrote: On Tue, 2014-06-17 at 06:22 -0600, Alex Williamson wrote: On Tue, 2014-06-17 at 08:04 +0100, David Woodhouse

Re: [Intel-gfx] [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-17 Thread Daniel Vetter
On Tue, Jun 17, 2014 at 08:15:47AM -0600, Alex Williamson wrote: On Tue, 2014-06-17 at 15:44 +0200, Daniel Vetter wrote: On Tue, Jun 17, 2014 at 07:16:22AM -0600, Alex Williamson wrote: On Tue, 2014-06-17 at 13:41 +0100, David Woodhouse wrote: On Tue, 2014-06-17 at 06:22 -0600, Alex

Re: [Intel-gfx] [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-17 Thread Alex Williamson
On Tue, 2014-06-17 at 18:45 +0200, Daniel Vetter wrote: On Tue, Jun 17, 2014 at 08:15:47AM -0600, Alex Williamson wrote: On Tue, 2014-06-17 at 15:44 +0200, Daniel Vetter wrote: On Tue, Jun 17, 2014 at 07:16:22AM -0600, Alex Williamson wrote: On Tue, 2014-06-17 at 13:41 +0100, David

Re: [Intel-gfx] [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-17 Thread Daniel Vetter
On Tue, Jun 17, 2014 at 10:59:51AM -0600, Alex Williamson wrote: On Tue, 2014-06-17 at 18:45 +0200, Daniel Vetter wrote: On Tue, Jun 17, 2014 at 08:15:47AM -0600, Alex Williamson wrote: On Tue, 2014-06-17 at 15:44 +0200, Daniel Vetter wrote: On Tue, Jun 17, 2014 at 07:16:22AM -0600, Alex

Re: [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-16 Thread Alex Williamson
On Fri, 2014-06-13 at 10:30 -0600, Alex Williamson wrote: > The user of the IOMMU API domain expects to have full control of > the IOVA space for the domain. RMRRs are fundamentally incompatible > with that idea. We can neither map the RMRR into the IOMMU API > domain, nor can we guarantee that

Re: [PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-16 Thread Alex Williamson
On Fri, 2014-06-13 at 10:30 -0600, Alex Williamson wrote: The user of the IOMMU API domain expects to have full control of the IOVA space for the domain. RMRRs are fundamentally incompatible with that idea. We can neither map the RMRR into the IOMMU API domain, nor can we guarantee that the

[PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-13 Thread Alex Williamson
The user of the IOMMU API domain expects to have full control of the IOVA space for the domain. RMRRs are fundamentally incompatible with that idea. We can neither map the RMRR into the IOMMU API domain, nor can we guarantee that the device won't continue DMA with the area described by the RMRR

[PATCH v2] iommu/intel: Exclude devices using RMRRs from IOMMU API domains

2014-06-13 Thread Alex Williamson
The user of the IOMMU API domain expects to have full control of the IOVA space for the domain. RMRRs are fundamentally incompatible with that idea. We can neither map the RMRR into the IOMMU API domain, nor can we guarantee that the device won't continue DMA with the area described by the RMRR