iwlwifi: dump debug data before stop device
authorShahar S Matityahu <shahar.s.matityahu@intel.com>
Mon, 11 Jun 2018 07:46:58 +0000 (10:46 +0300)
committerLuca Coelho <luciano.coelho@intel.com>
Mon, 8 Oct 2018 07:37:15 +0000 (10:37 +0300)
commit4244e7fc7037d247ed96f6e0bcddb4d72447ea73
treef0f1be8e41b23fca7690696a84c5a8da7ccd17f2
parent2ec3ef4614c9d50425334b2f2cd146740d9352e8
iwlwifi: dump debug data before stop device

Debug data dump is not working in flows that stop the device is used
in their error handling. During these flows the op mode mutex is
locked until the device stops.  Because of that, any assert generated
from the firmware can be handled only after the device already
stopped.

Since dumping cannot occour after stopping the device, split the the
dump function to two parts, Part that handles locking, and the part
that starts the actual dumping and call the second part in the op mode
stop device function.

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/fw/dbg.c
drivers/net/wireless/intel/iwlwifi/fw/dbg.h
drivers/net/wireless/intel/iwlwifi/mvm/mvm.h