Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 300639
b: refs/heads/master
c: 88f10a1
h: refs/heads/master
i:
  300637: aebb8ed
  300635: beaeb87
  300631: 0e0ef04
  300623: 564cf3a
  300607: 2c87fea
v: v3
  • Loading branch information
Wey-Yi Guy authored and John W. Linville committed Apr 9, 2012
1 parent 5935582 commit 9fe37c0
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 21 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: aa27a703ce258176a309be55c186c3f36e377a82
refs/heads/master: 88f10a176c7364a700c8638732e2b3110beaceb6
33 changes: 13 additions & 20 deletions trunk/drivers/net/wireless/iwlwifi/iwl-agn.c
Original file line number Diff line number Diff line change
Expand Up @@ -1178,7 +1178,6 @@ static void iwl_debug_config(struct iwl_priv *priv)
static struct iwl_op_mode *iwl_op_mode_dvm_start(struct iwl_trans *trans,
const struct iwl_fw *fw)
{
int err = 0;
struct iwl_priv *priv;
struct ieee80211_hw *hw;
struct iwl_op_mode *op_mode;
Expand All @@ -1201,7 +1200,6 @@ static struct iwl_op_mode *iwl_op_mode_dvm_start(struct iwl_trans *trans,
if (!hw) {
pr_err("%s: Cannot allocate network device\n",
cfg(trans)->name);
err = -ENOMEM;
goto out;
}

Expand Down Expand Up @@ -1273,26 +1271,24 @@ static struct iwl_op_mode *iwl_op_mode_dvm_start(struct iwl_trans *trans,
IWL_INFO(priv, "Detected %s, REV=0x%X\n",
cfg(priv)->name, trans(priv)->hw_rev);

err = iwl_trans_start_hw(trans(priv));
if (err)
if (iwl_trans_start_hw(trans(priv)))
goto out_free_traffic_mem;

/*****************
* 3. Read EEPROM
*****************/
err = iwl_eeprom_init(trans(priv), trans(priv)->hw_rev);
/* Reset chip to save power until we load uCode during "up". */
iwl_trans_stop_hw(trans(priv));
if (err) {
/* Read the EEPROM */
if (iwl_eeprom_init(trans(priv), trans(priv)->hw_rev)) {
IWL_ERR(priv, "Unable to init EEPROM\n");
goto out_free_traffic_mem;
}
err = iwl_eeprom_check_version(priv);
if (err)
/* Reset chip to save power until we load uCode during "up". */
iwl_trans_stop_hw(trans(priv));

if (iwl_eeprom_check_version(priv))
goto out_free_eeprom;

err = iwl_eeprom_init_hw_params(priv);
if (err)
if (iwl_eeprom_init_hw_params(priv))
goto out_free_eeprom;

/* extract MAC Address */
Expand Down Expand Up @@ -1332,9 +1328,9 @@ static struct iwl_op_mode *iwl_op_mode_dvm_start(struct iwl_trans *trans,
* 5. Setup priv
*******************/

err = iwl_init_drv(priv);
if (err)
if (iwl_init_drv(priv))
goto out_free_eeprom;

/* At this point both hw and priv are initialized. */

/********************
Expand Down Expand Up @@ -1367,15 +1363,12 @@ static struct iwl_op_mode *iwl_op_mode_dvm_start(struct iwl_trans *trans,
*
* 7. Setup and register with mac80211 and debugfs
**************************************************/
err = iwlagn_mac_setup_register(priv, &fw->ucode_capa);
if (err)
if (iwlagn_mac_setup_register(priv, &fw->ucode_capa))
goto out_destroy_workqueue;

err = iwl_dbgfs_register(priv, DRV_NAME);
if (err)
if (iwl_dbgfs_register(priv, DRV_NAME))
IWL_ERR(priv,
"failed to create debugfs files. Ignoring error: %d\n",
err);
"failed to create debugfs files. Ignoring error\n");

return op_mode;

Expand Down

0 comments on commit 9fe37c0

Please sign in to comment.