PCI: vmd: Disable MSI remapping after suspend
authorNirmal Patel <nirmal.patel@linux.intel.com>
Wed, 9 Nov 2022 14:26:52 +0000 (07:26 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 31 Dec 2022 12:14:23 +0000 (13:14 +0100)
commit6e78ca677fa22998ec205182b7a7daf037672fd7
treea0a5ed5a58f57dc8db2c1bb25b466531772d5ca0
parent47e31b86edff36f2d26cbc88ce695d98ff804178
PCI: vmd: Disable MSI remapping after suspend

[ Upstream commit d899aa668498c07ff217b666ae9712990306e682 ]

MSI remapping is disabled by VMD driver for Intel's Icelake and
newer systems in order to improve performance by setting
VMCONFIG_MSI_REMAP. By design VMCONFIG_MSI_REMAP register is cleared
by firmware during boot. The same register gets cleared when system
is put in S3 power state. VMD driver needs to set this register again
in order to avoid interrupt issues with devices behind VMD if MSI
remapping was disabled before.

Link: https://lore.kernel.org/r/20221109142652.450998-1-nirmal.patel@linux.intel.com
Fixes: ee81ee84f873 ("PCI: vmd: Disable MSI-X remapping when possible")
Signed-off-by: Nirmal Patel <nirmal.patel@linux.intel.com>
Signed-off-by: Lorenzo Pieralisi <lpieralisi@kernel.org>
Reviewed-by: Francisco Munoz <francisco.munoz.ruiz@linux.intel.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/pci/controller/vmd.c