diff options
author | Emmanuel Grumbach <emmanuel.grumbach@intel.com> | 2012-12-24 15:01:24 +0200 |
---|---|---|
committer | Johannes Berg <johannes.berg@intel.com> | 2013-01-03 15:29:46 +0100 |
commit | 7a65d17053c758109477f420e813ba2d826b0eae (patch) | |
tree | 9c53772ba9085c3afc72d75b3091f51fb37cf1ed /drivers/net/wireless/iwlwifi/iwl-test.c | |
parent | f317243a8ba1b05338bc03c6606a51021f249a67 (diff) |
iwlwifi: virtualize iwl_{grab,release}_nic_access
Since different transports have different ways to wake the
up the NIC, we need to virtualize it.
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl-test.c')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-test.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-test.c b/drivers/net/wireless/iwlwifi/iwl-test.c index 81e8c7126d7..08c1cfec859 100644 --- a/drivers/net/wireless/iwlwifi/iwl-test.c +++ b/drivers/net/wireless/iwlwifi/iwl-test.c @@ -467,13 +467,13 @@ static int iwl_test_indirect_read(struct iwl_test *tst, u32 addr, u32 size) if (IWL_ABS_PRPH_START <= addr && addr < IWL_ABS_PRPH_START + PRPH_END) { spin_lock_irqsave(&trans->reg_lock, flags); - iwl_grab_nic_access(trans); + iwl_trans_grab_nic_access(trans, false); iwl_write32(trans, HBUS_TARG_PRPH_RADDR, addr | (3 << 24)); for (i = 0; i < size; i += 4) *(u32 *)(tst->mem.addr + i) = iwl_read32(trans, HBUS_TARG_PRPH_RDAT); - iwl_release_nic_access(trans); + iwl_trans_release_nic_access(trans); spin_unlock_irqrestore(&trans->reg_lock, flags); } else { /* target memory (SRAM) */ _iwl_read_targ_mem_dwords(trans, addr, @@ -505,12 +505,12 @@ static int iwl_test_indirect_write(struct iwl_test *tst, u32 addr, if (size < 4) { memcpy(&val, buf, size); spin_lock_irqsave(&trans->reg_lock, flags); - iwl_grab_nic_access(trans); + iwl_trans_grab_nic_access(trans, false); iwl_write32(trans, HBUS_TARG_PRPH_WADDR, (addr & 0x0000FFFF) | ((size - 1) << 24)); iwl_write32(trans, HBUS_TARG_PRPH_WDAT, val); - iwl_release_nic_access(trans); + iwl_trans_release_nic_access(trans); /* needed after consecutive writes w/o read */ mmiowb(); spin_unlock_irqrestore(&trans->reg_lock, flags); |