Re: [PATCH 1/2] iommu: call detach also for default_domain before attaching to new one

2016-02-25 Thread Joerg Roedel
Hi Marek, On Wed, Feb 17, 2016 at 03:42:54PM +0100, Marek Szyprowski wrote: > From driver perspective the default_domains don't really differ from the > 'other' domains. They are just allocated from the IOMMU core and used by > the IOMMU/DMA-mapping glue code. That's what I got from reading the co

Re: [PATCH 1/2] iommu: call detach also for default_domain before attaching to new one

2016-02-17 Thread Marek Szyprowski
Hello, On 2016-02-17 12:14, Joerg Roedel wrote: On Wed, Feb 17, 2016 at 08:35:10AM +0100, Marek Szyprowski wrote: Huh, I wasn't aware of this change in the iommu drivers api. For some drivers attach/detach callbacks does something more than just programming page table base register, like for ex

Re: [PATCH 1/2] iommu: call detach also for default_domain before attaching to new one

2016-02-17 Thread Joerg Roedel
On Wed, Feb 17, 2016 at 08:35:10AM +0100, Marek Szyprowski wrote: > Huh, I wasn't aware of this change in the iommu drivers api. For some > drivers attach/detach callbacks does something more than just programming > page table base register, like for example in case of exynos iommu it is > enabling

Re: [PATCH 1/2] iommu: call detach also for default_domain before attaching to new one

2016-02-16 Thread Marek Szyprowski
Hello, On 2016-02-16 16:59, Joerg Roedel wrote: On Tue, Feb 16, 2016 at 03:40:31PM +0100, Marek Szyprowski wrote: This patch ensures that devices attached to the default_domain will be first detached from it before attaching to new domain. To avoid forward declaration, __iommu_attach_group() fu

Re: [PATCH 1/2] iommu: call detach also for default_domain before attaching to new one

2016-02-16 Thread Joerg Roedel
On Tue, Feb 16, 2016 at 03:40:31PM +0100, Marek Szyprowski wrote: > This patch ensures that devices attached to the default_domain will be > first detached from it before attaching to new domain. To avoid forward > declaration, __iommu_attach_group() function has been moved to new place > in the so

[PATCH 1/2] iommu: call detach also for default_domain before attaching to new one

2016-02-16 Thread Marek Szyprowski
This patch ensures that devices attached to the default_domain will be first detached from it before attaching to new domain. To avoid forward declaration, __iommu_attach_group() function has been moved to new place in the source code. Signed-off-by: Marek Szyprowski --- drivers/iommu/iommu.c |