lkml.org 
[lkml]   [2019]   [Apr]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH v5 1/6] iommu: add generic boot option iommu.dma_mode
From
Date


On 2019/4/12 19:16, Joerg Roedel wrote:
> On Tue, Apr 09, 2019 at 08:53:03PM +0800, Zhen Lei wrote:
>> +static int __init iommu_dma_mode_setup(char *str)
>> +{
>> + if (!str)
>> + goto fail;
>> +
>> + if (!strncmp(str, "passthrough", 11))
>> + iommu_default_dma_mode = IOMMU_DMA_MODE_PASSTHROUGH;
>> + else if (!strncmp(str, "lazy", 4))
>> + iommu_default_dma_mode = IOMMU_DMA_MODE_LAZY;
>> + else if (!strncmp(str, "strict", 6))
>> + iommu_default_dma_mode = IOMMU_DMA_MODE_STRICT;
>> + else
>> + goto fail;
>> +
>> + pr_info("Force dma mode to be %d\n", iommu_default_dma_mode);
>
> Printing a number is not very desriptive or helpful to the user. Please
> print the name of the mode instead.

OK, thanks. I have given up adding iommu.dma_mode boot option according
to Robin and Will's suggestion. So these codes will be removed in v6.

>
>
> Regards,
>
> Joerg
>
> .
>

--
Thanks!
BestRegards

\
 
 \ /
  Last update: 2019-04-23 04:47    [W:0.062 / U:1.280 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site