OSDN Git Service

iwlwifi: don't panic in error path on non-msix systems
authorShahar S Matityahu <shahar.s.matityahu@intel.com>
Mon, 15 Apr 2019 11:43:04 +0000 (14:43 +0300)
committerLuca Coelho <luciano.coelho@intel.com>
Thu, 18 Apr 2019 11:07:39 +0000 (14:07 +0300)
commit1c6bca6d75bca2cc47b5eafb9f7f16e368ffbeca
treea8df92050c1f296e2f39e53c792b9f7ae4241d61
parent614c70f35cd77a9af8e2ca841dcdb121cec3068f
iwlwifi: don't panic in error path on non-msix systems

The driver uses msix causes-register to handle both msix and non msix
interrupts when performing sync nmi.  On devices that do not support
msix this register is unmapped and accessing it causes a kernel panic.

Solve this by differentiating the two cases and accessing the proper
causes-register in each case.

Reported-by: Michal Hocko <mhocko@kernel.org>
Signed-off-by: Shahar S Matityahu <shahar.s.matityahu@intel.com>
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
drivers/net/wireless/intel/iwlwifi/pcie/trans.c