[<prev] [next>] [day] [month] [year] [list]
Message-ID: <20190618023914.GA14730@hari-Inspiron-1545>
Date: Tue, 18 Jun 2019 08:09:14 +0530
From: Hariprasad Kelam <hariprasad.kelam@...il.com>
To: Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Payal Kshirsagar <payal.s.kshirsagar.98@...il.com>,
Hariprasad Kelam <hariprasad.kelam@...il.com>,
Quytelda Kahja <quytelda@...alin.org>,
Andrew Morton <akpm@...ux-foundation.org>,
devel@...verdev.osuosl.org, linux-kernel@...r.kernel.org
Subject: [Patch v3] staging: rtl8723bs: hal: odm_HWConfig: Unneeded variable:
"result". Return "HAL_STATUS_SUCCESS"
Remove function ODM_ConfigMACWithHeaderFile as trace is not necessary
and as it is getting called only once and call direct function
"ODM_ReadAndConfig_MP_8723B_MAC_REG"
Issue identified by coccicheck
Signed-off-by: Hariprasad Kelam <hariprasad.kelam@...il.com>
----
changes v2: fixed typo in commit message
changes v3: Remove function ODM_ConfigMACWithHeaderFile and replace
with ODM_ReadAndConfig_MP_8723B_MAC_REG
---
---
drivers/staging/rtl8723bs/hal/odm_HWConfig.c | 29 -------------------------
drivers/staging/rtl8723bs/hal/odm_HWConfig.h | 2 --
drivers/staging/rtl8723bs/hal/rtl8723b_phycfg.c | 2 +-
3 files changed, 1 insertion(+), 32 deletions(-)
diff --git a/drivers/staging/rtl8723bs/hal/odm_HWConfig.c b/drivers/staging/rtl8723bs/hal/odm_HWConfig.c
index d802a1f..22f7410 100644
--- a/drivers/staging/rtl8723bs/hal/odm_HWConfig.c
+++ b/drivers/staging/rtl8723bs/hal/odm_HWConfig.c
@@ -496,32 +496,3 @@ HAL_STATUS ODM_ConfigBBWithHeaderFile(
return HAL_STATUS_SUCCESS;
}
-HAL_STATUS ODM_ConfigMACWithHeaderFile(PDM_ODM_T pDM_Odm)
-{
- u8 result = HAL_STATUS_SUCCESS;
-
- ODM_RT_TRACE(
- pDM_Odm,
- ODM_COMP_INIT,
- ODM_DBG_LOUD,
- (
- "===>ODM_ConfigMACWithHeaderFile (%s)\n",
- (pDM_Odm->bIsMPChip) ? "MPChip" : "TestChip"
- )
- );
- ODM_RT_TRACE(
- pDM_Odm,
- ODM_COMP_INIT,
- ODM_DBG_LOUD,
- (
- "pDM_Odm->SupportPlatform: 0x%X, pDM_Odm->SupportInterface: 0x%X, pDM_Odm->BoardType: 0x%X\n",
- pDM_Odm->SupportPlatform,
- pDM_Odm->SupportInterface,
- pDM_Odm->BoardType
- )
- );
-
- READ_AND_CONFIG(8723B, _MAC_REG);
-
- return result;
-}
diff --git a/drivers/staging/rtl8723bs/hal/odm_HWConfig.h b/drivers/staging/rtl8723bs/hal/odm_HWConfig.h
index d3af1ca..945366b 100644
--- a/drivers/staging/rtl8723bs/hal/odm_HWConfig.h
+++ b/drivers/staging/rtl8723bs/hal/odm_HWConfig.h
@@ -140,8 +140,6 @@ HAL_STATUS ODM_ConfigBBWithHeaderFile(
PDM_ODM_T pDM_Odm, ODM_BB_Config_Type ConfigType
);
-HAL_STATUS ODM_ConfigMACWithHeaderFile(PDM_ODM_T pDM_Odm);
-
HAL_STATUS ODM_ConfigFWWithHeaderFile(
PDM_ODM_T pDM_Odm,
ODM_FW_Config_Type ConfigType,
diff --git a/drivers/staging/rtl8723bs/hal/rtl8723b_phycfg.c b/drivers/staging/rtl8723bs/hal/rtl8723b_phycfg.c
index 6da7f8e..25c75b9 100644
--- a/drivers/staging/rtl8723bs/hal/rtl8723b_phycfg.c
+++ b/drivers/staging/rtl8723bs/hal/rtl8723b_phycfg.c
@@ -375,7 +375,7 @@ s32 PHY_MACConfig8723B(struct adapter *Adapter)
/* */
rtStatus = phy_ConfigMACWithParaFile(Adapter, pszMACRegFile);
if (rtStatus == _FAIL) {
- ODM_ConfigMACWithHeaderFile(&pHalData->odmpriv);
+ ODM_ReadAndConfig_MP_8723B_MAC_REG(&pHalData->odmpriv);
rtStatus = _SUCCESS;
}
--
2.7.4
Powered by blists - more mailing lists