summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/rtlwifi/rtl8192de
diff options
context:
space:
mode:
authorRickard Strandqvist <rickard_strandqvist@spectrumdigital.se>2014-06-01 22:14:38 +0200
committerJohn W. Linville <linville@tuxdriver.com>2014-06-19 15:49:14 -0400
commit7949513b315ac70abcd292170ba1099a9a56dbfe (patch)
tree93dc947223e1260840886b54d4c63629927c4362 /drivers/net/wireless/rtlwifi/rtl8192de
parent57eaeb6efa1f732ecf61130d7e0bb67c3ad9e4af (diff)
downloadtalos-op-linux-7949513b315ac70abcd292170ba1099a9a56dbfe.tar.gz
talos-op-linux-7949513b315ac70abcd292170ba1099a9a56dbfe.zip
net: wireless: rtlwifi: rtl8192de: phy.c: Cleaning up uninitialized variable
There is a risk that the variables will be used without being initialized. Have also moved variable to the part of the code where it is used. This was largely found by using a static code analysis program called cppcheck. Signed-off-by: Rickard Strandqvist <rickard_strandqvist@spectrumdigital.se> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/rtlwifi/rtl8192de')
-rw-r--r--drivers/net/wireless/rtlwifi/rtl8192de/phy.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/net/wireless/rtlwifi/rtl8192de/phy.c b/drivers/net/wireless/rtlwifi/rtl8192de/phy.c
index 3d1f0dd4e52d..592125a5f19c 100644
--- a/drivers/net/wireless/rtlwifi/rtl8192de/phy.c
+++ b/drivers/net/wireless/rtlwifi/rtl8192de/phy.c
@@ -203,11 +203,12 @@ u32 rtl92d_phy_query_bb_reg(struct ieee80211_hw *hw, u32 regaddr, u32 bitmask)
struct rtl_priv *rtlpriv = rtl_priv(hw);
struct rtl_hal *rtlhal = rtl_hal(rtlpriv);
u32 returnvalue, originalvalue, bitshift;
- u8 dbi_direct;
RT_TRACE(rtlpriv, COMP_RF, DBG_TRACE, "regaddr(%#x), bitmask(%#x)\n",
regaddr, bitmask);
if (rtlhal->during_mac1init_radioa || rtlhal->during_mac0init_radiob) {
+ u8 dbi_direct = 0;
+
/* mac1 use phy0 read radio_b. */
/* mac0 use phy1 read radio_b. */
if (rtlhal->during_mac1init_radioa)
OpenPOWER on IntegriCloud