Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1312580
| From | Lucas Tanure <tanure@linux.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH] sfc: Replace memset with eth_zero_addr |
| Date | 2016-01-20 00:30 +0100 |
| Message-ID | <qSNSO-6gl-19@gated-at.bofh.it> (permalink) |
| Organization | linux.* mail to news gateway |
Use eth_zero_addr to assign the zero address to the given address array instead of memset when second argument is address of zero. Signed-off-by: Lucas Tanure <tanure@linux.com> --- drivers/net/ethernet/sfc/ef10_sriov.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/sfc/ef10_sriov.c b/drivers/net/ethernet/sfc/ef10_sriov.c index 3c17f27..10f60db 100644 --- a/drivers/net/ethernet/sfc/ef10_sriov.c +++ b/drivers/net/ethernet/sfc/ef10_sriov.c @@ -527,7 +527,7 @@ int efx_ef10_sriov_set_vf_mac(struct efx_nic *efx, int vf_i, u8 *mac) return 0; fail: - memset(vf->mac, 0, ETH_ALEN); + eth_zero_addr(vf->mac); return rc; } -- 2.7.0
Back to linux.kernel | Previous | Next — Next in thread | Find similar | Unroll thread
[PATCH] sfc: Replace memset with eth_zero_addr Lucas Tanure <tanure@linux.com> - 2016-01-20 00:30 +0100
Re: [PATCH] sfc: Replace memset with eth_zero_addr Bert Kenward <bkenward@solarflare.com> - 2016-01-20 11:00 +0100
Re: [PATCH] sfc: Replace memset with eth_zero_addr David Miller <davem@davemloft.net> - 2016-01-20 11:30 +0100
Re: [PATCH] sfc: Replace memset with eth_zero_addr Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> - 2016-01-20 12:50 +0100
Re: [PATCH] sfc: Replace memset with eth_zero_addr Lucas Tanure <tanure@linux.com> - 2016-01-20 12:50 +0100
csiph-web