staging: ozwpan: ozproto.c fix for "WARNING: Prefer ether_addr_copy() over memcpy...
authorAnil Belur <askb23@gmail.com>
Mon, 19 May 2014 09:42:48 +0000 (19:42 +1000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 23 May 2014 12:10:50 +0000 (21:10 +0900)
Fixed the warning message by replacing memcpy() with ether_addr_copy()

Signed-off-by: Anil Belur <askb23@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/ozwpan/ozproto.c

index 767cac4930740556df0808a2b46d743e38719530..1102055991900b3e2ca6e7984c6caed6a2013f59 100644 (file)
@@ -792,7 +792,7 @@ int oz_get_pd_list(struct oz_mac_addr *addr, int max_count)
                if (count >= max_count)
                        break;
                pd = container_of(e, struct oz_pd, link);
-               memcpy(&addr[count++], pd->mac_addr, ETH_ALEN);
+               ether_addr_copy((u8 *)&addr[count++], pd->mac_addr);
        }
        spin_unlock_bh(&g_polling_lock);
        return count;