diff options
author | Maxim Levitsky <mlevitsk@redhat.com> | 2021-11-23 19:10:35 +0300 |
---|---|---|
committer | Joerg Roedel <jroedel@suse.de> | 2021-12-17 11:20:43 +0300 |
commit | 01b297a48a26bcb96769505ac948db4603b72bd1 (patch) | |
tree | 0265d994eb16cc280359e42155d9f71dcc86dd60 /drivers/iommu | |
parent | a8d4a37d1bb93608501d0d0545f902061152669a (diff) | |
download | linux-01b297a48a26bcb96769505ac948db4603b72bd1.tar.xz |
iommu/amd: X2apic mode: re-enable after resume
Otherwise it is guaranteed to not work after the resume...
Fixes: 66929812955bb ("iommu/amd: Add support for X2APIC IOMMU interrupts")
Signed-off-by: Maxim Levitsky <mlevitsk@redhat.com>
Link: https://lore.kernel.org/r/20211123161038.48009-3-mlevitsk@redhat.com
Signed-off-by: Joerg Roedel <jroedel@suse.de>
Diffstat (limited to 'drivers/iommu')
-rw-r--r-- | drivers/iommu/amd/init.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/iommu/amd/init.c b/drivers/iommu/amd/init.c index 8dae85fcfc2e..b905604f434e 100644 --- a/drivers/iommu/amd/init.c +++ b/drivers/iommu/amd/init.c @@ -2172,7 +2172,6 @@ static int iommu_setup_intcapxt(struct amd_iommu *iommu) return ret; } - iommu_feature_enable(iommu, CONTROL_INTCAPXT_EN); return 0; } @@ -2195,6 +2194,10 @@ static int iommu_init_irq(struct amd_iommu *iommu) iommu->int_enabled = true; enable_faults: + + if (amd_iommu_xt_mode == IRQ_REMAP_X2APIC_MODE) + iommu_feature_enable(iommu, CONTROL_INTCAPXT_EN); + iommu_feature_enable(iommu, CONTROL_EVT_INT_EN); if (iommu->ppr_log != NULL) |