iwlwifi: mvm: don't power off the device between INIT and OPER firmwares
authorEran Harary <eran.harary@intel.com>
Mon, 27 Apr 2015 07:29:31 +0000 (10:29 +0300)
committerEmmanuel Grumbach <emmanuel.grumbach@intel.com>
Tue, 28 Apr 2015 11:58:51 +0000 (14:58 +0300)
commit8d193ca26cc28019e760b77830295a0c349d90dc
treea6f6ab3f1292c21106fa941c2c9827b065b45370
parent553452e5ffc0ed13214a287549627d02d9d7fbdc
iwlwifi: mvm: don't power off the device between INIT and OPER firmwares

Our device needs two different firmwares: the INIT firmware
and the operational (OPER) firmware. The first one is run
when the driver loads and it returns calibrations results
as well as the NVM. The second one implements the WiFi
protocol.

If the wlan interface is not brought up, the device is put
to low power state: no firmware will be running. When the
interface is brought up, we would run the OPER firmware
only and reuse the results of the run of the INIT firmware
when the driver was loaded. This is changing with this
patch.
We now run the INIT firmware every time mac80211 calls
start(). The penalty for that is minimal since the INIT
firwmare run fast. I now also avoid to power down the device
between the INIT and OPER firmware on certains buses.

The motivation for this change is that there are components
on the device (MFUART) that are triggered by the INIT
firmware and need the device to be powered up in order to
keep running. Powering the device down between the INIT and
OPER firmware would stop these components and prevent them
from running again since they are triggered by the INIT
firmware only.
The new flow allows this and also allows to trigger these
components again when the interface is brought up after
it has been brought down.

Signed-off-by: Eran Harary <eran.harary@intel.com>
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
drivers/net/wireless/iwlwifi/iwl-trans.h
drivers/net/wireless/iwlwifi/mvm/fw.c
drivers/net/wireless/iwlwifi/mvm/mvm.h
drivers/net/wireless/iwlwifi/pcie/trans.c