From: Peter Wu <peter@lekensteyn.nl>
To: Larry Finger <Larry.Finger@lwfinger.net>,
John W Linville <linville@tuxdriver.com>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Chaoming_Li <chaoming_li@realsil.com.cn>,
linux-wireless@vger.kernel.org, linux-kernel@vger.kernel.org,
lekensteyn@gmail.com
Subject: [PATCH 2/3] staging/rtl8821ae: avoid accessing RCR directly
Date: Thu, 20 Mar 2014 19:52:23 +0100 [thread overview]
Message-ID: <1395341544-21464-3-git-send-email-peter@lekensteyn.nl> (raw)
In-Reply-To: <1395341544-21464-1-git-send-email-peter@lekensteyn.nl>
Similar to "rtlwifi: avoid accessing RCR directly", this patch avoids
accessing receive_config directly and uses get_hw_reg. There is no
functional change.
Signed-off-by: Peter Wu <peter@lekensteyn.nl>
---
drivers/staging/rtl8821ae/rtl8821ae/hw.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/drivers/staging/rtl8821ae/rtl8821ae/hw.c b/drivers/staging/rtl8821ae/rtl8821ae/hw.c
index 5ed7a11..e4dbf05 100644
--- a/drivers/staging/rtl8821ae/rtl8821ae/hw.c
+++ b/drivers/staging/rtl8821ae/rtl8821ae/hw.c
@@ -1633,12 +1633,13 @@ static int _rtl8821ae_set_media_status(struct ieee80211_hw *hw,
void rtl8821ae_set_check_bssid(struct ieee80211_hw *hw, bool check_bssid)
{
struct rtl_priv *rtlpriv = rtl_priv(hw);
- struct rtl_pci *rtlpci = rtl_pcidev(rtl_pcipriv(hw));
- u32 reg_rcr = rtlpci->receive_config;
+ u32 reg_rcr;
if (rtlpriv->psc.rfpwr_state != ERFON)
return;
+ rtlpriv->cfg->ops->get_hw_reg(hw, HW_VAR_RCR, (u8 *)(®_rcr));
+
if (check_bssid == true) {
reg_rcr |= (RCR_CBSSID_DATA | RCR_CBSSID_BCN);
rtlpriv->cfg->ops->set_hw_reg(hw, HW_VAR_RCR,
--
1.9.1
next prev parent reply other threads:[~2014-03-20 18:52 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-03-20 18:52 [PATCH 0/3] rtlwifi (and staging rtl8821ae) cleanups Peter Wu
2014-03-20 18:52 ` [PATCH v2 1/3] rtlwifi: remove unused allow_all_destaddr functions Peter Wu
2014-03-20 18:52 ` Peter Wu [this message]
2014-03-20 18:52 ` [PATCH 3/3] staging/rtl8821ae: remove unused allow_all_destaddr function Peter Wu
2014-03-20 19:48 ` [PATCH 0/3] rtlwifi (and staging rtl8821ae) cleanups Larry Finger
2014-03-20 20:05 ` Greg Kroah-Hartman
2014-03-20 21:01 ` Peter Wu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1395341544-21464-3-git-send-email-peter@lekensteyn.nl \
--to=peter@lekensteyn.nl \
--cc=Larry.Finger@lwfinger.net \
--cc=chaoming_li@realsil.com.cn \
--cc=gregkh@linuxfoundation.org \
--cc=lekensteyn@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-wireless@vger.kernel.org \
--cc=linville@tuxdriver.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox