staging: rtl8723bs: remove custom is_zero_mac_addr() function

Remove the custom function is_zero_mac_addr() and replace all calls to it
with the default kernel function is_zero_ether_addr() to avoid
duplicating existing code.

Signed-off-by: Nikolay Kulikov <nikolayof23@gmail.com>
Link: https://patch.msgid.link/20260323150650.7168-5-nikolayof23@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Nikolay Kulikov 2026-03-23 18:06:06 +03:00 committed by Greg Kroah-Hartman
parent 4fa02e833e
commit 93854e4dd5
3 changed files with 2 additions and 8 deletions

View File

@ -11,7 +11,7 @@ u8 rtw_validate_bssid(u8 *bssid)
{
u8 ret = true;
if (is_zero_mac_addr(bssid) ||
if (is_zero_ether_addr(bssid) ||
is_broadcast_mac_addr(bssid) ||
is_multicast_mac_addr(bssid))
ret = false;

View File

@ -1675,7 +1675,7 @@ static int rtw_check_roaming_candidate(struct mlme_priv *mlme
goto exit;
/* got specific addr to roam */
if (!is_zero_mac_addr(mlme->roam_tgt_addr)) {
if (!is_zero_ether_addr(mlme->roam_tgt_addr)) {
if (!memcmp(mlme->roam_tgt_addr, competitor->network.mac_address, ETH_ALEN))
goto update;
else

View File

@ -518,12 +518,6 @@ static inline int is_broadcast_mac_addr(const u8 *addr)
(addr[3] == 0xff) && (addr[4] == 0xff) && (addr[5] == 0xff));
}
static inline int is_zero_mac_addr(const u8 *addr)
{
return ((addr[0] == 0x00) && (addr[1] == 0x00) && (addr[2] == 0x00) && \
(addr[3] == 0x00) && (addr[4] == 0x00) && (addr[5] == 0x00));
}
#define CFG_IEEE80211_RESERVE_FCS (1<<0)
#define CFG_IEEE80211_COMPUTE_FCS (1<<1)