Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f1e8524c authored by Sergio Paracuellos's avatar Sergio Paracuellos Committed by Greg Kroah-Hartman
Browse files

staging: ks7010: use ether_addr_equal in hostif_data_request



Use ether_addr_equal to compare addresses in ether_addr_equal
function instead of comparing using memcmp.

Signed-off-by: default avatarSergio Paracuellos <sergio.paracuellos@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent e9eb9a9d
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1059,7 +1059,7 @@ int hostif_data_request(struct ks_wlan_private *priv, struct sk_buff *skb)

	/* skb check */
	eth = (struct ethhdr *)skb->data;
	if (memcmp(&priv->eth_addr[0], eth->h_source, ETH_ALEN) != 0) {
	if (!ether_addr_equal(&priv->eth_addr[0], eth->h_source)) {
		netdev_err(priv->net_dev, "invalid mac address !!\n");
		netdev_err(priv->net_dev, "ethernet->h_source=%pM\n", eth->h_source);
		ret = -ENXIO;