Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 275703
b: refs/heads/master
c: 43e5885
h: refs/heads/master
i:
  275701: 928f868
  275699: 80a268f
  275695: d423ffc
v: v3
  • Loading branch information
Emmanuel Grumbach authored and John W. Linville committed Nov 11, 2011
1 parent 2e6f24b commit fd9f470
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 17 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: 0ecfe806f146e0cb10c2c5abbb3bb4e91959e41a
refs/heads/master: 43e58856585f8c61e6a4a0f1fd6996d78799a973
33 changes: 17 additions & 16 deletions trunk/drivers/net/wireless/iwlwifi/iwl-trans-pcie.c
Original file line number Diff line number Diff line change
Expand Up @@ -990,29 +990,16 @@ static int iwl_trans_tx_stop(struct iwl_trans *trans)
return 0;
}

static void iwl_trans_pcie_disable_sync_irq(struct iwl_trans *trans)
static void iwl_trans_pcie_stop_device(struct iwl_trans *trans)
{
unsigned long flags;
struct iwl_trans_pcie *trans_pcie =
IWL_TRANS_GET_PCIE_TRANS(trans);
struct iwl_trans_pcie *trans_pcie = IWL_TRANS_GET_PCIE_TRANS(trans);

/* tell the device to stop sending interrupts */
spin_lock_irqsave(&trans->shrd->lock, flags);
iwl_disable_interrupts(trans);
spin_unlock_irqrestore(&trans->shrd->lock, flags);

/* wait to make sure we flush pending tasklet*/
synchronize_irq(bus(trans)->irq);
tasklet_kill(&trans_pcie->irq_tasklet);
}

static void iwl_trans_pcie_stop_device(struct iwl_trans *trans)
{
/* stop and reset the on-board processor */
iwl_write32(bus(trans), CSR_RESET, CSR_RESET_REG_FLAG_NEVO_RESET);

/* tell the device to stop sending interrupts */
iwl_trans_pcie_disable_sync_irq(trans);

/* device going down, Stop using ICT table */
iwl_disable_ict(trans);

Expand All @@ -1039,6 +1026,20 @@ static void iwl_trans_pcie_stop_device(struct iwl_trans *trans)

/* Stop the device, and put it in low power state */
iwl_apm_stop(priv(trans));

/* Upon stop, the APM issues an interrupt if HW RF kill is set.
* Clean again the interrupt here
*/
spin_lock_irqsave(&trans->shrd->lock, flags);
iwl_disable_interrupts(trans);
spin_unlock_irqrestore(&trans->shrd->lock, flags);

/* wait to make sure we flush pending tasklet*/
synchronize_irq(bus(trans)->irq);
tasklet_kill(&trans_pcie->irq_tasklet);

/* stop and reset the on-board processor */
iwl_write32(bus(trans), CSR_RESET, CSR_RESET_REG_FLAG_NEVO_RESET);
}

static int iwl_trans_pcie_tx(struct iwl_trans *trans, struct sk_buff *skb,
Expand Down

0 comments on commit fd9f470

Please sign in to comment.