wifi: optimize the code [1/1]
authorlibo <bo.li@amlogic.com>
Thu, 2 Dec 2021 03:14:35 +0000 (11:14 +0800)
committerBruno Martins <bgcngm@gmail.com>
Thu, 25 Apr 2024 00:09:40 +0000 (01:09 +0100)
PD#SWPL-65570

Problem:
optimize the code

Solution:
optimize the code

Verify:
local

Signed-off-by: libo <bo.li@amlogic.com>
Change-Id: I4de5b003e61702b77dde1cbed8e044b9454e921a

bcmdhd.101.10.361.x/wl_cfg80211.c

index 8a317d8142babf25003032ab72f0d6577023a443..2739b3e5e382a95f49376f571f9d371f22cff7f8 100755 (executable)
@@ -17786,7 +17786,7 @@ s32 wl_cfg80211_get_p2p_dev_addr(struct net_device *net, struct ether_addr *p2pd
                return -1;
        if (!p2p_is_on(cfg)) {
                get_primary_mac(cfg, &primary_mac);
-               memcpy((void *)&p2pdev_addr, (void *)&primary_mac, ETHER_ADDR_LEN);
+               memcpy((void *)p2pdev_addr, (void *)&primary_mac, ETHER_ADDR_LEN);
        } else {
                memcpy(p2pdev_addr->octet, wl_to_p2p_bss_macaddr(cfg, P2PAPI_BSSCFG_DEVICE).octet,
                        ETHER_ADDR_LEN);