|
@@ -1,6 +1,7 @@
|
|
|
/******************************************************************************
|
|
|
*
|
|
|
* Copyright(c) 2003 - 2014 Intel Corporation. All rights reserved.
|
|
|
+ * Copyright(c) 2015 Intel Deutschland GmbH
|
|
|
*
|
|
|
* Portions of this file are derived from the ipw3945 project.
|
|
|
*
|
|
@@ -117,18 +118,20 @@ int iwl_poll_direct_bit(struct iwl_trans *trans, u32 addr, u32 mask,
|
|
|
}
|
|
|
IWL_EXPORT_SYMBOL(iwl_poll_direct_bit);
|
|
|
|
|
|
-u32 __iwl_read_prph(struct iwl_trans *trans, u32 ofs)
|
|
|
+u32 iwl_read_prph_no_grab(struct iwl_trans *trans, u32 ofs)
|
|
|
{
|
|
|
u32 val = iwl_trans_read_prph(trans, ofs);
|
|
|
trace_iwlwifi_dev_ioread_prph32(trans->dev, ofs, val);
|
|
|
return val;
|
|
|
}
|
|
|
+IWL_EXPORT_SYMBOL(iwl_read_prph_no_grab);
|
|
|
|
|
|
-void __iwl_write_prph(struct iwl_trans *trans, u32 ofs, u32 val)
|
|
|
+void iwl_write_prph_no_grab(struct iwl_trans *trans, u32 ofs, u32 val)
|
|
|
{
|
|
|
trace_iwlwifi_dev_iowrite_prph32(trans->dev, ofs, val);
|
|
|
iwl_trans_write_prph(trans, ofs, val);
|
|
|
}
|
|
|
+IWL_EXPORT_SYMBOL(iwl_write_prph_no_grab);
|
|
|
|
|
|
u32 iwl_read_prph(struct iwl_trans *trans, u32 ofs)
|
|
|
{
|
|
@@ -136,7 +139,7 @@ u32 iwl_read_prph(struct iwl_trans *trans, u32 ofs)
|
|
|
u32 val = 0x5a5a5a5a;
|
|
|
|
|
|
if (iwl_trans_grab_nic_access(trans, false, &flags)) {
|
|
|
- val = __iwl_read_prph(trans, ofs);
|
|
|
+ val = iwl_read_prph_no_grab(trans, ofs);
|
|
|
iwl_trans_release_nic_access(trans, &flags);
|
|
|
}
|
|
|
return val;
|
|
@@ -148,7 +151,7 @@ void iwl_write_prph(struct iwl_trans *trans, u32 ofs, u32 val)
|
|
|
unsigned long flags;
|
|
|
|
|
|
if (iwl_trans_grab_nic_access(trans, false, &flags)) {
|
|
|
- __iwl_write_prph(trans, ofs, val);
|
|
|
+ iwl_write_prph_no_grab(trans, ofs, val);
|
|
|
iwl_trans_release_nic_access(trans, &flags);
|
|
|
}
|
|
|
}
|
|
@@ -174,8 +177,9 @@ void iwl_set_bits_prph(struct iwl_trans *trans, u32 ofs, u32 mask)
|
|
|
unsigned long flags;
|
|
|
|
|
|
if (iwl_trans_grab_nic_access(trans, false, &flags)) {
|
|
|
- __iwl_write_prph(trans, ofs,
|
|
|
- __iwl_read_prph(trans, ofs) | mask);
|
|
|
+ iwl_write_prph_no_grab(trans, ofs,
|
|
|
+ iwl_read_prph_no_grab(trans, ofs) |
|
|
|
+ mask);
|
|
|
iwl_trans_release_nic_access(trans, &flags);
|
|
|
}
|
|
|
}
|
|
@@ -187,8 +191,9 @@ void iwl_set_bits_mask_prph(struct iwl_trans *trans, u32 ofs,
|
|
|
unsigned long flags;
|
|
|
|
|
|
if (iwl_trans_grab_nic_access(trans, false, &flags)) {
|
|
|
- __iwl_write_prph(trans, ofs,
|
|
|
- (__iwl_read_prph(trans, ofs) & mask) | bits);
|
|
|
+ iwl_write_prph_no_grab(trans, ofs,
|
|
|
+ (iwl_read_prph_no_grab(trans, ofs) &
|
|
|
+ mask) | bits);
|
|
|
iwl_trans_release_nic_access(trans, &flags);
|
|
|
}
|
|
|
}
|
|
@@ -200,8 +205,8 @@ void iwl_clear_bits_prph(struct iwl_trans *trans, u32 ofs, u32 mask)
|
|
|
u32 val;
|
|
|
|
|
|
if (iwl_trans_grab_nic_access(trans, false, &flags)) {
|
|
|
- val = __iwl_read_prph(trans, ofs);
|
|
|
- __iwl_write_prph(trans, ofs, (val & ~mask));
|
|
|
+ val = iwl_read_prph_no_grab(trans, ofs);
|
|
|
+ iwl_write_prph_no_grab(trans, ofs, (val & ~mask));
|
|
|
iwl_trans_release_nic_access(trans, &flags);
|
|
|
}
|
|
|
}
|