From: Martin Kaiser <martin@kaiser.cx>
To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Larry Finger <Larry.Finger@lwfinger.net>,
Phillip Potter <phil@philpotter.co.uk>,
Michael Straube <straube.linux@gmail.com>,
linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org,
Martin Kaiser <martin@kaiser.cx>
Subject: [PATCH 1/4] staging: r8188eu: remove constant parameter of phy_LCCalibrate_8188E
Date: Thu, 3 Feb 2022 21:32:14 +0100 [thread overview]
Message-ID: <20220203203217.252156-2-martin@kaiser.cx> (raw)
In-Reply-To: <20220203203217.252156-1-martin@kaiser.cx>
The only caller of phy_LCCalibrate_8188E sets is2t to false.
Remove this parameter and resulting dead code.
Signed-off-by: Martin Kaiser <martin@kaiser.cx>
---
drivers/staging/r8188eu/hal/HalPhyRf_8188e.c | 18 +++---------------
1 file changed, 3 insertions(+), 15 deletions(-)
diff --git a/drivers/staging/r8188eu/hal/HalPhyRf_8188e.c b/drivers/staging/r8188eu/hal/HalPhyRf_8188e.c
index 5f7a2668cabb..db87eaafb72f 100644
--- a/drivers/staging/r8188eu/hal/HalPhyRf_8188e.c
+++ b/drivers/staging/r8188eu/hal/HalPhyRf_8188e.c
@@ -821,10 +821,10 @@ static void phy_IQCalibrate_8188E(struct adapter *adapt, s32 result[][8], u8 t)
}
}
-static void phy_LCCalibrate_8188E(struct adapter *adapt, bool is2t)
+static void phy_LCCalibrate_8188E(struct adapter *adapt)
{
u8 tmpreg;
- u32 RF_Amode = 0, RF_Bmode = 0, LC_Cal;
+ u32 RF_Amode = 0, LC_Cal;
/* Check continuous TX and Packet TX */
tmpreg = rtw_read8(adapt, 0xd03);
@@ -839,17 +839,9 @@ static void phy_LCCalibrate_8188E(struct adapter *adapt, bool is2t)
/* Path-A */
RF_Amode = rtl8188e_PHY_QueryRFReg(adapt, RF_PATH_A, RF_AC, bMask12Bits);
- /* Path-B */
- if (is2t)
- RF_Bmode = rtl8188e_PHY_QueryRFReg(adapt, RF_PATH_B, RF_AC, bMask12Bits);
-
/* 2. Set RF mode = standby mode */
/* Path-A */
rtl8188e_PHY_SetRFReg(adapt, RF_PATH_A, RF_AC, bMask12Bits, (RF_Amode & 0x8FFFF) | 0x10000);
-
- /* Path-B */
- if (is2t)
- rtl8188e_PHY_SetRFReg(adapt, RF_PATH_B, RF_AC, bMask12Bits, (RF_Bmode & 0x8FFFF) | 0x10000);
}
/* 3. Read RF reg18 */
@@ -866,10 +858,6 @@ static void phy_LCCalibrate_8188E(struct adapter *adapt, bool is2t)
/* Path-A */
rtw_write8(adapt, 0xd03, tmpreg);
rtl8188e_PHY_SetRFReg(adapt, RF_PATH_A, RF_AC, bMask12Bits, RF_Amode);
-
- /* Path-B */
- if (is2t)
- rtl8188e_PHY_SetRFReg(adapt, RF_PATH_B, RF_AC, bMask12Bits, RF_Bmode);
} else {
/* Deal with Packet TX case */
rtw_write8(adapt, REG_TXPAUSE, 0x00);
@@ -999,5 +987,5 @@ void PHY_LCCalibrate_8188E(struct adapter *adapt)
timecount += 50;
}
- phy_LCCalibrate_8188E(adapt, false);
+ phy_LCCalibrate_8188E(adapt);
}
--
2.30.2
next prev parent reply other threads:[~2022-02-03 20:34 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-02-03 20:32 [PATCH 0/4] staging: r8188eu: remove unused code for RF_PATH_B Martin Kaiser
2022-02-03 20:32 ` Martin Kaiser [this message]
2022-02-03 20:32 ` [PATCH 2/4] staging: r8188eu: remove dead code for tx power tracking Martin Kaiser
2022-02-03 20:32 ` [PATCH 3/4] staging: r8188eu: remove constant parameter of odm_ConfigRFReg_8188E Martin Kaiser
2022-02-03 20:32 ` [PATCH 4/4] staging: r8188eu: remove constant variable eRFPath Martin Kaiser
2022-02-04 9:09 ` [PATCH v2 0/4] staging: r8188eu: remove unused code for RF_PATH_B Martin Kaiser
2022-02-04 9:09 ` [PATCH v2 1/4] staging: r8188eu: remove constant parameter of phy_LCCalibrate_8188E Martin Kaiser
2022-02-04 9:09 ` [PATCH v2 2/4] staging: r8188eu: remove dead code for tx power tracking Martin Kaiser
2022-02-04 9:09 ` [PATCH v2 3/4] staging: r8188eu: remove constant parameter of odm_ConfigRFReg_8188E Martin Kaiser
2022-02-04 9:09 ` [PATCH v2 4/4] staging: r8188eu: remove constant variable eRFPath Martin Kaiser
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=20220203203217.252156-2-martin@kaiser.cx \
--to=martin@kaiser.cx \
--cc=Larry.Finger@lwfinger.net \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-staging@lists.linux.dev \
--cc=phil@philpotter.co.uk \
--cc=straube.linux@gmail.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
all inboxes | Powered by JetHome®