Skip to content

Commit

Permalink
net/ncsi: use eth_zero_addr() to clear mac address
Browse files Browse the repository at this point in the history
Use eth_zero_addr() to clear mac address insetad of memset().

Signed-off-by: Miaohe Lin <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
  • Loading branch information
MiaoheLin authored and davem330 committed Jul 23, 2020
1 parent 8bf9d8e commit 49b0aa1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion net/ncsi/ncsi-rsp.c
Original file line number Diff line number Diff line change
Expand Up @@ -471,7 +471,7 @@ static int ncsi_rsp_handler_sma(struct ncsi_request *nr)
memcpy(&ncf->addrs[index], cmd->mac, ETH_ALEN);
} else {
clear_bit(cmd->index - 1, bitmap);
memset(&ncf->addrs[index], 0, ETH_ALEN);
eth_zero_addr(&ncf->addrs[index]);
}
spin_unlock_irqrestore(&nc->lock, flags);

Expand Down

0 comments on commit 49b0aa1

Please sign in to comment.