[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250715182814.212708-4-straube.linux@gmail.com>
Date: Tue, 15 Jul 2025 20:28:06 +0200
From: Michael Straube <straube.linux@...il.com>
To: gregkh@...uxfoundation.org
Cc: hdegoede@...hat.com,
Larry.Finger@...inger.net,
linux-staging@...ts.linux.dev,
linux-kernel@...r.kernel.org,
Michael Straube <straube.linux@...il.com>
Subject: [PATCH 03/11] staging: rtl8723bs: remove function pointer hal_notch_filter
Remove function pointer hal_notch_filter and use hal_notch_filter_8723b
directly to reduce code complexity.
Signed-off-by: Michael Straube <straube.linux@...il.com>
---
drivers/staging/rtl8723bs/hal/hal_intf.c | 3 +--
drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c | 3 +--
drivers/staging/rtl8723bs/include/hal_intf.h | 2 +-
3 files changed, 3 insertions(+), 5 deletions(-)
diff --git a/drivers/staging/rtl8723bs/hal/hal_intf.c b/drivers/staging/rtl8723bs/hal/hal_intf.c
index eb34e39f3c64..a168852cb6c7 100644
--- a/drivers/staging/rtl8723bs/hal/hal_intf.c
+++ b/drivers/staging/rtl8723bs/hal/hal_intf.c
@@ -292,8 +292,7 @@ s32 rtw_hal_xmit_thread_handler(struct adapter *padapter)
void rtw_hal_notch_filter(struct adapter *adapter, bool enable)
{
- if (adapter->HalFunc.hal_notch_filter)
- adapter->HalFunc.hal_notch_filter(adapter, enable);
+ hal_notch_filter_8723b(adapter, enable);
}
void rtw_hal_reset_security_engine(struct adapter *adapter)
diff --git a/drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c b/drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c
index a6eab2819535..b746e3e05d16 100644
--- a/drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c
+++ b/drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c
@@ -1267,7 +1267,7 @@ void rtl8723b_SetBeaconRelatedRegisters(struct adapter *padapter)
rtw_write8(padapter, bcn_ctrl_reg, val8);
}
-static void hal_notch_filter_8723b(struct adapter *adapter, bool enable)
+void hal_notch_filter_8723b(struct adapter *adapter, bool enable)
{
if (enable)
rtw_write8(adapter, rOFDM0_RxDSP+1, rtw_read8(adapter, rOFDM0_RxDSP+1) | BIT1);
@@ -1316,7 +1316,6 @@ void UpdateHalRAMask8723B(struct adapter *padapter, u32 mac_id, u8 rssi_level)
void rtl8723b_set_hal_ops(struct hal_ops *pHalFunc)
{
pHalFunc->xmit_thread_handler = &hal_xmit_handler;
- pHalFunc->hal_notch_filter = &hal_notch_filter_8723b;
pHalFunc->c2h_handler = c2h_handler_8723b;
pHalFunc->c2h_id_filter_ccx = c2h_id_filter_ccx_8723b;
diff --git a/drivers/staging/rtl8723bs/include/hal_intf.h b/drivers/staging/rtl8723bs/include/hal_intf.h
index 3626e1505848..72ae4cdcf0dd 100644
--- a/drivers/staging/rtl8723bs/include/hal_intf.h
+++ b/drivers/staging/rtl8723bs/include/hal_intf.h
@@ -162,7 +162,6 @@ typedef s32 (*c2h_id_filter)(u8 *c2h_evt);
struct hal_ops {
s32 (*xmit_thread_handler)(struct adapter *padapter);
- void (*hal_notch_filter)(struct adapter *adapter, bool enable);
void (*hal_reset_security_engine)(struct adapter *adapter);
s32 (*c2h_handler)(struct adapter *padapter, u8 *c2h_evt);
c2h_id_filter c2h_id_filter_ccx;
@@ -282,4 +281,5 @@ void Hal_ReadEFuse(struct adapter *padapter, u8 efuseType, u16 _offset,
void Hal_GetEfuseDefinition(struct adapter *padapter, u8 efuseType, u8 type,
void *pOut, bool bPseudoTest);
u16 Hal_EfuseGetCurrentSize(struct adapter *padapter, u8 efuseType, bool bPseudoTest);
+void hal_notch_filter_8723b(struct adapter *adapter, bool enable);
#endif /* __HAL_INTF_H__ */
--
2.50.1
Powered by blists - more mailing lists