From 3baa5b32a75379b6edfe05f84f91fbe130048ef7 Mon Sep 17 00:00:00 2001 From: Nam Cao Date: Fri, 2 Sep 2022 11:51:54 +0200 Subject: [PATCH] staging: rtl8723bs: delete rtw_odm.c and rtw_odm.h Remove rtw_odm.c and rtw_odm.h because the content of these files is not used. Signed-off-by: Nam Cao Link: https://lore.kernel.org/r/6870109ce0c51b4ab91ec370d8b2285dc635e5fe.1662111798.git.namcaov@gmail.com Signed-off-by: Greg Kroah-Hartman --- drivers/staging/rtl8723bs/Makefile | 1 - drivers/staging/rtl8723bs/core/rtw_odm.c | 116 ------------------ drivers/staging/rtl8723bs/include/drv_types.h | 1 - drivers/staging/rtl8723bs/include/rtw_odm.h | 24 ---- 4 files changed, 142 deletions(-) delete mode 100644 drivers/staging/rtl8723bs/core/rtw_odm.c delete mode 100644 drivers/staging/rtl8723bs/include/rtw_odm.h diff --git a/drivers/staging/rtl8723bs/Makefile b/drivers/staging/rtl8723bs/Makefile index bc7ff1dd14f9..590bde02058c 100644 --- a/drivers/staging/rtl8723bs/Makefile +++ b/drivers/staging/rtl8723bs/Makefile @@ -10,7 +10,6 @@ r8723bs-y = \ core/rtw_ieee80211.o \ core/rtw_mlme.o \ core/rtw_mlme_ext.o \ - core/rtw_odm.o \ core/rtw_pwrctrl.o \ core/rtw_recv.o \ core/rtw_rf.o \ diff --git a/drivers/staging/rtl8723bs/core/rtw_odm.c b/drivers/staging/rtl8723bs/core/rtw_odm.c deleted file mode 100644 index 47fd2ee9bb9f..000000000000 --- a/drivers/staging/rtl8723bs/core/rtw_odm.c +++ /dev/null @@ -1,116 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0 -/****************************************************************************** - * - * Copyright(c) 2013 Realtek Corporation. All rights reserved. - * - ******************************************************************************/ - -#include -#include -#include -#include - -#define RTW_ODM_COMP_MAX 32 - -static const char * const odm_ability_str[] = { - /* BIT0 */"ODM_BB_DIG", - /* BIT1 */"ODM_BB_RA_MASK", - /* BIT2 */"ODM_BB_DYNAMIC_TXPWR", - /* BIT3 */"ODM_BB_FA_CNT", - /* BIT4 */"ODM_BB_RSSI_MONITOR", - /* BIT5 */"ODM_BB_CCK_PD", - /* BIT6 */"ODM_BB_ANT_DIV", - /* BIT7 */"ODM_BB_PWR_SAVE", - /* BIT8 */"ODM_BB_PWR_TRAIN", - /* BIT9 */"ODM_BB_RATE_ADAPTIVE", - /* BIT10 */"ODM_BB_PATH_DIV", - /* BIT11 */"ODM_BB_PSD", - /* BIT12 */"ODM_BB_RXHP", - /* BIT13 */"ODM_BB_ADAPTIVITY", - /* BIT14 */"ODM_BB_DYNAMIC_ATC", - /* BIT15 */NULL, - /* BIT16 */"ODM_MAC_EDCA_TURBO", - /* BIT17 */"ODM_MAC_EARLY_MODE", - /* BIT18 */NULL, - /* BIT19 */NULL, - /* BIT20 */NULL, - /* BIT21 */NULL, - /* BIT22 */NULL, - /* BIT23 */NULL, - /* BIT24 */"ODM_RF_TX_PWR_TRACK", - /* BIT25 */"ODM_RF_RX_GAIN_TRACK", - /* BIT26 */"ODM_RF_CALIBRATION", -}; - -#define RTW_ODM_ABILITY_MAX 27 - -static const char * const odm_dbg_level_str[] = { - NULL, - "ODM_DBG_OFF", - "ODM_DBG_SERIOUS", - "ODM_DBG_WARNING", - "ODM_DBG_LOUD", - "ODM_DBG_TRACE", -}; - -#define RTW_ODM_DBG_LEVEL_NUM 6 - -void rtw_odm_dbg_level_msg(void *sel, struct adapter *adapter) -{ - u32 dbg_level; - int i; - - rtw_hal_get_def_var(adapter, HW_DEF_ODM_DBG_LEVEL, &dbg_level); - netdev_dbg(adapter->pnetdev, "odm.DebugLevel = %u\n", dbg_level); - for (i = 0; i < RTW_ODM_DBG_LEVEL_NUM; i++) { - if (odm_dbg_level_str[i]) - netdev_dbg(adapter->pnetdev, "%u %s\n", i, - odm_dbg_level_str[i]); - } -} - -inline void rtw_odm_dbg_level_set(struct adapter *adapter, u32 level) -{ - rtw_hal_set_def_var(adapter, HW_DEF_ODM_DBG_LEVEL, &level); -} - -void rtw_odm_ability_msg(void *sel, struct adapter *adapter) -{ - u32 ability = 0; - int i; - - rtw_hal_get_hwreg(adapter, HW_VAR_DM_FLAG, (u8 *)&ability); - netdev_dbg(adapter->pnetdev, "odm.SupportAbility = 0x%08x\n", ability); - for (i = 0; i < RTW_ODM_ABILITY_MAX; i++) { - if (odm_ability_str[i]) - netdev_dbg(adapter->pnetdev, "%cBIT%-2d %s\n", - (BIT0 << i) & ability ? '+' : ' ', i, - odm_ability_str[i]); - } -} - -void rtw_odm_adaptivity_parm_set(struct adapter *adapter, s8 TH_L2H_ini, - s8 TH_EDCCA_HL_diff, s8 IGI_Base, - bool ForceEDCCA, u8 AdapEn_RSSI, - u8 IGI_LowerBound) -{ - struct hal_com_data *pHalData = GET_HAL_DATA(adapter); - struct dm_odm_t *odm = &pHalData->odmpriv; - - odm->TH_L2H_ini = TH_L2H_ini; - odm->TH_EDCCA_HL_diff = TH_EDCCA_HL_diff; - odm->IGI_Base = IGI_Base; - odm->ForceEDCCA = ForceEDCCA; - odm->AdapEn_RSSI = AdapEn_RSSI; - odm->IGI_LowerBound = IGI_LowerBound; -} - -void rtw_odm_get_perpkt_rssi(void *sel, struct adapter *adapter) -{ - struct hal_com_data *hal_data = GET_HAL_DATA(adapter); - struct dm_odm_t *odm = &hal_data->odmpriv; - - netdev_dbg(adapter->pnetdev, - "RxRate = %s, RSSI_A = %d(%%), RSSI_B = %d(%%)\n", - HDATA_RATE(odm->RxRate), odm->RSSI_A, odm->RSSI_B); -} diff --git a/drivers/staging/rtl8723bs/include/drv_types.h b/drivers/staging/rtl8723bs/include/drv_types.h index bb4650f0b297..82159e1c7f9b 100644 --- a/drivers/staging/rtl8723bs/include/drv_types.h +++ b/drivers/staging/rtl8723bs/include/drv_types.h @@ -50,7 +50,6 @@ #include #include #include -#include #include "ioctl_cfg80211.h" diff --git a/drivers/staging/rtl8723bs/include/rtw_odm.h b/drivers/staging/rtl8723bs/include/rtw_odm.h deleted file mode 100644 index 6a431c121285..000000000000 --- a/drivers/staging/rtl8723bs/include/rtw_odm.h +++ /dev/null @@ -1,24 +0,0 @@ -/* SPDX-License-Identifier: GPL-2.0 */ -/****************************************************************************** - * - * Copyright(c) 2013 Realtek Corporation. All rights reserved. - * - ******************************************************************************/ -#ifndef __RTW_ODM_H__ -#define __RTW_ODM_H__ - -#include - -/* -* This file provides utilities/wrappers for rtw driver to use ODM -*/ - -void rtw_odm_dbg_level_msg(void *sel, struct adapter *adapter); -void rtw_odm_dbg_level_set(struct adapter *adapter, u32 level); - -void rtw_odm_ability_msg(void *sel, struct adapter *adapter); - -void rtw_odm_adaptivity_parm_set(struct adapter *adapter, s8 TH_L2H_ini, s8 TH_EDCCA_HL_diff, - s8 IGI_Base, bool ForceEDCCA, u8 AdapEn_RSSI, u8 IGI_LowerBound); -void rtw_odm_get_perpkt_rssi(void *sel, struct adapter *adapter); -#endif /* __RTW_ODM_H__ */