2
0
mirror of https://github.com/edk2-porting/linux-next.git synced 2024-12-24 05:04:00 +08:00

iwlwifi: separate the APM from the EEPROM

There is no link between the two. Ensure that the NIC is on outside
the code of the EEPROM handling.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
This commit is contained in:
Emmanuel Grumbach 2012-01-04 16:57:09 +02:00 committed by Wey-Yi Guy
parent a591697730
commit 8747bb4936
2 changed files with 4 additions and 4 deletions

View File

@ -1848,8 +1848,12 @@ int iwl_probe(struct iwl_bus *bus, const struct iwl_trans_ops *trans_ops,
/*****************
* 4. Read EEPROM
*****************/
/* switch the NIC on before accessing the EEPROM */
iwl_apm_init(priv);
/* Read the EEPROM */
err = iwl_eeprom_init(priv, hw_rev);
/* Reset chip to save power until we load uCode during "up". */
iwl_apm_stop(priv);
if (err) {
IWL_ERR(priv, "Unable to init EEPROM\n");
goto out_free_trans;

View File

@ -676,8 +676,6 @@ int iwl_eeprom_init(struct iwl_priv *priv, u32 hw_rev)
}
e = (__le16 *)shrd->eeprom;
iwl_apm_init(priv);
ret = iwl_eeprom_verify_signature(trans(priv));
if (ret < 0) {
IWL_ERR(priv, "EEPROM not found, EEPROM_GP=0x%08x\n", gp);
@ -758,8 +756,6 @@ done:
err:
if (ret)
iwl_eeprom_free(priv->shrd);
/* Reset chip to save power until we load uCode during "up". */
iwl_apm_stop(priv);
alloc_err:
return ret;
}