Re: [PATCH] intel-iommu: Synchronize gcmd value with global command register

2013-04-03 Thread Takao Indoh
(2013/04/03 17:24), David Woodhouse wrote: > On Wed, 2013-04-03 at 16:11 +0900, Takao Indoh wrote: >> (2013/04/02 23:05), Joerg Roedel wrote: >>> On Mon, Apr 01, 2013 at 02:45:18PM +0900, Takao Indoh wrote: enable_IR intel_enable_irq_remapping iommu_disable_irq_remapp

Re: [PATCH v2] irq: add quirk for broken interrupt remapping on 55XX chipsets

2013-04-03 Thread Bjorn Helgaas
[+cc David and iommu list, Yinghai, Jiang] On Mon, Mar 4, 2013 at 12:04 PM, Neil Horman wrote: > A few years back intel published a spec update: > http://www.intel.com/content/dam/doc/specification-update/5520-and-5500-chipset-ioh-specification-update.pdf > > For the 5520 and 5500 chipsets which

[PATCH] iommu/amd: Add workaround to propery clearing IOMMU status register

2013-04-03 Thread suravee.suthikulpanit
From: Suravee Suthikulpanit The IOMMU interrupt handling in bottom half must clear the PPR log interrupt and event log interrupt bits to re-enable the interrupt. This is done by writing 1 to the memory mapped register to clear the bit. Due to hardware bug, if the driver tries to clear this bit wh

Re: RFC: vfio API changes needed for powerpc

2013-04-03 Thread Scott Wood
On 04/02/2013 10:12:31 PM, Alex Williamson wrote: On Tue, 2013-04-02 at 17:44 -0500, Scott Wood wrote: > On 04/02/2013 04:32:04 PM, Alex Williamson wrote: > > On Tue, 2013-04-02 at 15:57 -0500, Scott Wood wrote: > > > On 04/02/2013 03:32:17 PM, Alex Williamson wrote: > > > > On x86 the interrupt

Re: RFC: vfio API changes needed for powerpc

2013-04-03 Thread Scott Wood
On 04/02/2013 10:37:20 PM, Alex Williamson wrote: On Tue, 2013-04-02 at 17:50 -0500, Scott Wood wrote: > On 04/02/2013 04:38:45 PM, Alex Williamson wrote: > > On Tue, 2013-04-02 at 16:08 -0500, Stuart Yoder wrote: > > > On Tue, Apr 2, 2013 at 3:57 PM, Scott Wood > > wrote: > > > >> >C. Expl

Re: RFC: vfio API changes needed for powerpc

2013-04-03 Thread Scott Wood
On 04/03/2013 02:43:06 PM, Stuart Yoder wrote: On Wed, Apr 3, 2013 at 2:18 PM, Scott Wood wrote: > On 04/03/2013 02:09:45 PM, Stuart Yoder wrote: >> >> > Would is be possible for userspace to simply leave room for MSI bank >> > mapping (how much room could be determined by something like >>

Re: RFC: vfio API changes needed for powerpc

2013-04-03 Thread Scott Wood
On 04/03/2013 02:09:45 PM, Stuart Yoder wrote: > Would is be possible for userspace to simply leave room for MSI bank > mapping (how much room could be determined by something like > VFIO_IOMMU_GET_MSI_BANK_COUNT) then document the API that userspace can > DMA_MAP starting at the 0x0 address o

Re: RFC: vfio API changes needed for powerpc

2013-04-03 Thread Stuart Yoder
On Wed, Apr 3, 2013 at 2:18 PM, Scott Wood wrote: > On 04/03/2013 02:09:45 PM, Stuart Yoder wrote: >> >> > Would is be possible for userspace to simply leave room for MSI bank >> > mapping (how much room could be determined by something like >> > VFIO_IOMMU_GET_MSI_BANK_COUNT) then document the AP

Re: RFC: vfio API changes needed for powerpc

2013-04-03 Thread Alex Williamson
On Wed, 2013-04-03 at 14:09 -0500, Stuart Yoder wrote: > > Would is be possible for userspace to simply leave room for MSI bank > > mapping (how much room could be determined by something like > > VFIO_IOMMU_GET_MSI_BANK_COUNT) then document the API that userspace can > > DMA_MAP starting at the 0x

Re: RFC: vfio API changes needed for powerpc

2013-04-03 Thread Scott Wood
On 04/03/2013 02:09:45 PM, Stuart Yoder wrote: > Would is be possible for userspace to simply leave room for MSI bank > mapping (how much room could be determined by something like > VFIO_IOMMU_GET_MSI_BANK_COUNT) then document the API that userspace can > DMA_MAP starting at the 0x0 address o

Re: RFC: vfio API changes needed for powerpc

2013-04-03 Thread Stuart Yoder
> Would is be possible for userspace to simply leave room for MSI bank > mapping (how much room could be determined by something like > VFIO_IOMMU_GET_MSI_BANK_COUNT) then document the API that userspace can > DMA_MAP starting at the 0x0 address of the aperture, growing up, and > VFIO will map bank

Re: RFC: vfio API changes needed for powerpc

2013-04-03 Thread Scott Wood
On 04/03/2013 01:32:26 PM, Stuart Yoder wrote: On Tue, Apr 2, 2013 at 5:50 PM, Scott Wood wrote: > On 04/02/2013 04:38:45 PM, Alex Williamson wrote: >> >> On Tue, 2013-04-02 at 16:08 -0500, Stuart Yoder wrote: >> > VFIO_IOMMU_MAP_MSI(iova, size) > > > Not sure how you mean "size" to be use

Re: RFC: vfio API changes needed for powerpc

2013-04-03 Thread Stuart Yoder
On Tue, Apr 2, 2013 at 5:50 PM, Scott Wood wrote: > On 04/02/2013 04:38:45 PM, Alex Williamson wrote: >> >> On Tue, 2013-04-02 at 16:08 -0500, Stuart Yoder wrote: >> > On Tue, Apr 2, 2013 at 3:57 PM, Scott Wood >> > wrote: >> > >> >C. Explicit mapping using normal DMA map. The last idea is

Re: RFC: vfio API changes needed for powerpc

2013-04-03 Thread Stuart Yoder
>> > Type1 is arbitrary. It might as well be named "brown" and this one >> > can be >> > "blue". >> >> The difference is that "type1" seems to refer to hardware that can do >> arbitrary 4K page mappings, possibly constrained by an aperture but >> nothing else. More than one IOMMU can reasonably

Re: [PATCH 5/5 v11] iommu/fsl: Freescale PAMU driver and iommu implementation.

2013-04-03 Thread Alex Williamson
On Tue, 2013-04-02 at 18:18 +0200, Joerg Roedel wrote: > Cc'ing Alex Williamson > > Alex, can you please review the iommu-group part of this patch? Sure, it looks pretty reasonable. AIUI, all PCI devices are below some kind of host bridge that is either new and supports partitioning or old and d

RE: [PATCH 5/5 v11] iommu/fsl: Freescale PAMU driver and iommu implementation.

2013-04-03 Thread Yoder Stuart-B08248
> -Original Message- > From: Sethi Varun-B16395 > Sent: Wednesday, April 03, 2013 12:12 AM > To: Wood Scott-B07421; Timur Tabi > Cc: Joerg Roedel; lkml; Kumar Gala; Yoder Stuart-B08248; > iommu@lists.linux-foundation.org; Benjamin > Herrenschmidt; linuxppc-...@lists.ozlabs.org > Subject:

Re: [PATCH] intel-iommu: Synchronize gcmd value with global command register

2013-04-03 Thread David Woodhouse
On Wed, 2013-04-03 at 16:11 +0900, Takao Indoh wrote: > (2013/04/02 23:05), Joerg Roedel wrote: > > On Mon, Apr 01, 2013 at 02:45:18PM +0900, Takao Indoh wrote: > >> > >> enable_IR > >>intel_enable_irq_remapping > >> iommu_disable_irq_remapping <== IRES/QIES/TES disabled here > >> d

Re: [PATCH 4/5 v11] iommu/fsl: Add additional iommu attributes required by the PAMU driver.

2013-04-03 Thread Joerg Roedel
On Wed, Apr 03, 2013 at 05:21:16AM +, Sethi Varun-B16395 wrote: > > I would prefer these PAMU specific enum and struct to be in a pamu- > > specific iommu-header. > > > > [Sethi Varun-B16395] But, these would be used by the IOMMU API users > (e.g. VFIO), they shouldn't depend on PAMU specific

Re: [PATCH] intel-iommu: Synchronize gcmd value with global command register

2013-04-03 Thread Takao Indoh
(2013/04/02 23:05), Joerg Roedel wrote: > On Mon, Apr 01, 2013 at 02:45:18PM +0900, Takao Indoh wrote: >> >> enable_IR >>intel_enable_irq_remapping >> iommu_disable_irq_remapping <== IRES/QIES/TES disabled here >> dmar_disable_qi <== do nothing >> dmar_enable_qi

RE: [PATCH 5/5 v11] iommu/fsl: Freescale PAMU driver and iommu implementation.

2013-04-03 Thread Sethi Varun-B16395
> -Original Message- > From: Joerg Roedel [mailto:j...@8bytes.org] > Sent: Tuesday, April 02, 2013 9:48 PM > To: Sethi Varun-B16395 > Cc: Yoder Stuart-B08248; Wood Scott-B07421; iommu@lists.linux- > foundation.org; linuxppc-...@lists.ozlabs.org; linux- > ker...@vger.kernel.org; ga...@kern