Hi Baolu, On Thu, Nov 5, 2020 at 9:47 AM Lu Baolu <[email protected]> wrote: > > Hi Zhenzhong, > > On 11/4/20 4:19 PM, Zhenzhong Duan wrote: > > no_platform_optin is redundant with dmar_disabled and it's only used in > > platform_optin_force_iommu(), remove it and use dmar_disabled instead. > > It's actually not. > > If CONFIG_INTEL_IOMMU_DEFAULT_ON is not set, we will get "dmar_disable = > 1" and "no_platform_optin = 0". In this case, we must force the iommu on > and set dmar_disable = 0. > > The real use case: if a kernel built with [CONFIG_INTEL_IOMMU_DEFAULT_ON > = n] running on a platform with thunderbolt ports, we must force IOMMU > on so that the system could be protected from possible malicious > peripherals.
Thanks for your explanation, clear now and sorry for the noise. Regards Zhenzhong

