]> git.baikalelectronics.ru Git - kernel.git/commit
iommu/amd: X2apic mode: mask/unmask interrupts on suspend/resume
authorMaxim Levitsky <mlevitsk@redhat.com>
Tue, 23 Nov 2021 16:10:37 +0000 (18:10 +0200)
committerJoerg Roedel <jroedel@suse.de>
Fri, 17 Dec 2021 08:30:18 +0000 (09:30 +0100)
commit784c7dcd5ada6ad12f96ae8223400697df3a4c86
tree127d93693c28fb537aba269f092ee481512b87a1
parentb39284be908af644ec35d3ff577891d2412c6bce
iommu/amd: X2apic mode: mask/unmask interrupts on suspend/resume

Use IRQCHIP_MASK_ON_SUSPEND to make the core irq code to
mask the iommu interrupt on suspend and unmask it on the resume.

Since now the unmask function updates the INTX settings,
that will restore them on resume from s3/s4.

Since IRQCHIP_MASK_ON_SUSPEND is only effective for interrupts
which are not wakeup sources, remove IRQCHIP_SKIP_SET_WAKE flag
and instead implement a dummy .irq_set_wake which doesn't allow
the interrupt to become a wakeup source.

Fixes: b96cf5fedc2fe ("iommu/amd: Add support for X2APIC IOMMU interrupts")
Signed-off-by: Maxim Levitsky <mlevitsk@redhat.com>
Link: https://lore.kernel.org/r/20211123161038.48009-5-mlevitsk@redhat.com
Signed-off-by: Joerg Roedel <jroedel@suse.de>
drivers/iommu/amd/init.c