AMD/IOMMU: correct IRTE updating
authorJan Beulich <jbeulich@suse.com>
Wed, 31 Jul 2019 11:27:52 +0000 (13:27 +0200)
committerJan Beulich <jbeulich@suse.com>
Wed, 31 Jul 2019 11:27:52 +0000 (13:27 +0200)
commit9e0e225a3aeccd807a8db88ba4669f8ab30ecc99
tree1350321d1eb77214c2637713bac7b08ea9cb7ab3
parent0e8e0a0854a00d81267a5e9c9616a3fbd2729747
AMD/IOMMU: correct IRTE updating

Flushing didn't get done along the lines of what the specification says.
Mark entries to be updated as not remapped (which will result in
interrupt requests to get target aborted, but the interrupts should be
masked anyway at that point in time), issue the flush, and only then
write the new entry.

In update_intremap_entry_from_msi_msg() also fold the duplicate initial
lock determination and acquire into just a single instance.

Signed-off-by: Jan Beulich <jbeulich@suse.com>
Acked-by: Andrew Cooper <andrew.cooper3@citrix.com>
Acked-by: Brian Woods <brian.woods@amd.com>
xen/drivers/passthrough/amd/iommu_intr.c