diff options
author | dingtianhong <dingtianhong@huawei.com> | 2013-12-30 08:41:10 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2013-12-31 22:48:32 +0100 |
commit | 202af853ccdf1c23e81d1899145d21e9a4c6d5a6 (patch) | |
tree | 8b55733ff10b92190ce74f9e1c3e68cc4b41edfc /drivers/net/ethernet/qlogic/netxen | |
parent | net: packetengines: slight optimization of addr (diff) | |
download | linux-202af853ccdf1c23e81d1899145d21e9a4c6d5a6.tar.xz linux-202af853ccdf1c23e81d1899145d21e9a4c6d5a6.zip |
net: netxen: slight optimization of addr compare
Use possibly more efficient ether_addr_equal
to instead of memcmp.
Cc: Manish Chopra <manish.chopra@qlogic.com>
Cc: Sony Chacko <sony.chacko@qlogic.com>
Cc: Rajesh Borundia <rajesh.borundia@qlogic.com>
Signed-off-by: Ding Tianhong <dingtianhong@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/qlogic/netxen')
-rw-r--r-- | drivers/net/ethernet/qlogic/netxen/netxen_nic_hw.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ethernet/qlogic/netxen/netxen_nic_hw.c b/drivers/net/ethernet/qlogic/netxen/netxen_nic_hw.c index b72b6bea326e..db4280ce9c09 100644 --- a/drivers/net/ethernet/qlogic/netxen/netxen_nic_hw.c +++ b/drivers/net/ethernet/qlogic/netxen/netxen_nic_hw.c @@ -661,7 +661,7 @@ static int nx_p3_nic_add_mac(struct netxen_adapter *adapter, list_for_each(head, del_list) { cur = list_entry(head, nx_mac_list_t, list); - if (memcmp(addr, cur->mac_addr, ETH_ALEN) == 0) { + if (ether_addr_equal(addr, cur->mac_addr)) { list_move_tail(head, &adapter->mac_list); return 0; } |