Re: [PATCH 5/5] iommu: Allow default domain type to be set on the kernel command line

2017-01-26 Thread Will Deacon
On Thu, Jan 26, 2017 at 06:15:55PM +0100, Joerg Roedel wrote:
> On Thu, Jan 19, 2017 at 06:19:15PM +, Will Deacon wrote:
> > Rather than modify each IOMMU driver to provide different semantics for
> > DMA domains, instead we introduce a command line parameter that can be
> > used to change the type of the default domain. Passthrough can then be
> > specified using "iommu.default_domain=identity" on the kernel command
> > line.
> 
> I like the general idea of this, but the above is a terrible name for a
> kernel commandline-parameter. The x86 iommus support iommu=pt which is
> pretty much the same as this patch does.

Happy to bikeshed the name ;)

> How about something like "iommu.passthrough=0/1"? And please add the
> parameter to the kernel documentation too.

Sure, if you think that the identity domain is the only thing we'll ever
want to set (so far, it's the only thing people have asked me for).

Will
___
iommu mailing list
iommu@lists.linux-foundation.org
https://lists.linuxfoundation.org/mailman/listinfo/iommu


Re: [PATCH 5/5] iommu: Allow default domain type to be set on the kernel command line

2017-01-26 Thread Robin Murphy
On 26/01/17 17:15, Joerg Roedel wrote:
> On Thu, Jan 19, 2017 at 06:19:15PM +, Will Deacon wrote:
>> Rather than modify each IOMMU driver to provide different semantics for
>> DMA domains, instead we introduce a command line parameter that can be
>> used to change the type of the default domain. Passthrough can then be
>> specified using "iommu.default_domain=identity" on the kernel command
>> line.
> 
> I like the general idea of this, but the above is a terrible name for a
> kernel commandline-parameter. The x86 iommus support iommu=pt which is
> pretty much the same as this patch does.

Indeed, I was keen on making "iommu=pt" also do this default domain
switch itself so we wouldn't need a new option - it didn't *appear* that
that would break the AMD driver (as the only other default domain user
supporting identity domains) but I may have overlooked something.

Robin.

> How about something like "iommu.passthrough=0/1"? And please add the
> parameter to the kernel documentation too.
> 
> 
>   Joerg
> 

___
iommu mailing list
iommu@lists.linux-foundation.org
https://lists.linuxfoundation.org/mailman/listinfo/iommu


Re: [PATCH 5/5] iommu: Allow default domain type to be set on the kernel command line

2017-01-26 Thread Joerg Roedel
On Thu, Jan 19, 2017 at 06:19:15PM +, Will Deacon wrote:
> Rather than modify each IOMMU driver to provide different semantics for
> DMA domains, instead we introduce a command line parameter that can be
> used to change the type of the default domain. Passthrough can then be
> specified using "iommu.default_domain=identity" on the kernel command
> line.

I like the general idea of this, but the above is a terrible name for a
kernel commandline-parameter. The x86 iommus support iommu=pt which is
pretty much the same as this patch does.

How about something like "iommu.passthrough=0/1"? And please add the
parameter to the kernel documentation too.


Joerg

___
iommu mailing list
iommu@lists.linux-foundation.org
https://lists.linuxfoundation.org/mailman/listinfo/iommu