hv: vtd: fix a logic error when set iommu page walk coherent

Fix a logic error when set iommu page walk coherent.

Tracked-On: #3160
Signed-off-by: Binbin Wu <binbin.wu@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
This commit is contained in:
Binbin Wu 2019-05-23 11:46:52 +08:00 committed by ACRN System Integration
parent 517707dee4
commit b833e2f90c

View File

@ -495,7 +495,7 @@ static int32_t dmar_register_hrhd(struct dmar_drhd_rt *dmar_unit)
pr_fatal("%s: dmar unit doesn't support Extended Interrupt Mode!", __func__);
ret = -ENODEV;
} else {
if ((iommu_ecap_c(dmar_unit->ecap) == 0U) && (dmar_unit->drhd->ignore != 0U)) {
if ((iommu_ecap_c(dmar_unit->ecap) == 0U) && (!dmar_unit->drhd->ignore)) {
iommu_page_walk_coherent = false;
}