projects
/
platform
/
kernel
/
linux-stable.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
490953a
)
iwlwifi: fix indirect write bug
author
Amnon Paz
<amnonX.paz@intel.com>
Wed, 27 Feb 2013 09:28:16 +0000
(11:28 +0200)
committer
Johannes Berg
<johannes.berg@intel.com>
Wed, 6 Mar 2013 15:48:02 +0000
(16:48 +0100)
Fix a bug in writing to indirect (periphery) registers; although
writes seem successful the data is not written to the desired
address). Also fix address mask for HBUS_TARG_PRPH_RADDR and
HBUS_TARG_PRPH_WADDR registers.
Signed-off-by: Amnon Paz <amnonX.paz@intel.com>
Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
drivers/net/wireless/iwlwifi/pcie/trans.c
patch
|
blob
|
history
diff --git
a/drivers/net/wireless/iwlwifi/pcie/trans.c
b/drivers/net/wireless/iwlwifi/pcie/trans.c
index
d17fb4b
..
6649e37
100644
(file)
--- a/
drivers/net/wireless/iwlwifi/pcie/trans.c
+++ b/
drivers/net/wireless/iwlwifi/pcie/trans.c
@@
-715,7
+715,8
@@
static u32 iwl_trans_pcie_read32(struct iwl_trans *trans, u32 ofs)
static u32 iwl_trans_pcie_read_prph(struct iwl_trans *trans, u32 reg)
{
- iwl_trans_pcie_write32(trans, HBUS_TARG_PRPH_RADDR, reg | (3 << 24));
+ iwl_trans_pcie_write32(trans, HBUS_TARG_PRPH_RADDR,
+ ((reg & 0x000FFFFF) | (3 << 24)));
return iwl_trans_pcie_read32(trans, HBUS_TARG_PRPH_RDAT);
}
@@
-723,7
+724,7
@@
static void iwl_trans_pcie_write_prph(struct iwl_trans *trans, u32 addr,
u32 val)
{
iwl_trans_pcie_write32(trans, HBUS_TARG_PRPH_WADDR,
- ((addr & 0x000
0
FFFF) | (3 << 24)));
+ ((addr & 0x000
F
FFFF) | (3 << 24)));
iwl_trans_pcie_write32(trans, HBUS_TARG_PRPH_WDAT, val);
}