staging: rtl8723bs: use ether_addr_equal in rtw_ap.c
Subsystems (3)
PATCH 1/1 staging: rtl8723bs: use ether_addr_equal in rtw_ap.c
Replace memcmp() with ether_addr_equal() for MAC address comparison. This is the preferred and more readable method in network code.
Signed-off-by rafiqul713 <[email protected]>
--- drivers/staging/rtl8723bs/core/rtw_ap.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)
drivers/staging/rtl8723bs/core/rtw_ap.c +3 -2
@@ -6,6 +6,7 @@******************************************************************************/ #include <drv_types.h> +#include <linux/etherdevice.h> #include <linux/unaligned.h> void init_mlme_ap_info (struct adapter *padapter)
@@ -1185,7 +1186,7 @@ int rtw_acl_add_sta(struct adapter *padapter, u8 *addr)list_for_each (plist, phead) { paclnode = list_entry(plist, struct rtw_wlan_acl_node, list); -if (!memcmp (paclnode->addr, addr,ETH_ALEN )) { +if (ether_addr_equal (paclnode->addr, addr)) {if (paclnode->valid == true) { added = true;break ;
@@ -1238,7 +1239,7 @@ void rtw_acl_remove_sta(struct adapter *padapter, u8 *addr) paclnode = list_entry(plist, struct rtw_wlan_acl_node, list);if ( - !memcmp (paclnode->addr, addr,ETH_ALEN ) || +ether_addr_equal (paclnode->addr, addr) ||is_broadcast_ether_addr (addr) ) {if (paclnode->valid) {
Signature · 1 line
2.34.1
Greg KH
maintainerQuoted 7 lines · On Sat, Nov 01, 2025 at 09:16:23PM +0100, rafiqul713 wrote:
Replace
memcmp()withether_addr_equal()for MAC address comparison. This is the preferred and more readable method in network code.Signed-off-by rafiqul713 <[email protected]>--- drivers/staging/rtl8723bs/core/rtw_ap.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)
I'm sorry, but I'm going to have to start ignoring patches from you as you have not taken any of the prior review comments and changed anything.
I recommend working on a different software project. Best of luck,
greg k-h