diff options
author | Joe Perches <joe@perches.com> | 2014-02-23 00:05:26 -0800 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2014-02-24 19:16:44 -0500 |
commit | 04091142826e5823e31cc6418942ac447b3edb0a (patch) | |
tree | dbc0275ae1f732f7985d601b91fbad0dba7ed01b /net/bridge/netfilter/ebt_snat.c | |
parent | e5a727f6632654098fa4e87d8551a5873e8f658a (diff) | |
download | linux-stable-04091142826e5823e31cc6418942ac447b3edb0a.tar.gz linux-stable-04091142826e5823e31cc6418942ac447b3edb0a.tar.bz2 linux-stable-04091142826e5823e31cc6418942ac447b3edb0a.zip |
bridge: netfilter: Use ether_addr_copy
Convert the uses of memcpy to ether_addr_copy because
for some architectures it is smaller and faster.
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/bridge/netfilter/ebt_snat.c')
-rw-r--r-- | net/bridge/netfilter/ebt_snat.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/bridge/netfilter/ebt_snat.c b/net/bridge/netfilter/ebt_snat.c index 0f6b118d6cb2..e56ccd060d26 100644 --- a/net/bridge/netfilter/ebt_snat.c +++ b/net/bridge/netfilter/ebt_snat.c @@ -24,7 +24,7 @@ ebt_snat_tg(struct sk_buff *skb, const struct xt_action_param *par) if (!skb_make_writable(skb, 0)) return EBT_DROP; - memcpy(eth_hdr(skb)->h_source, info->mac, ETH_ALEN); + ether_addr_copy(eth_hdr(skb)->h_source, info->mac); if (!(info->target & NAT_ARP_BIT) && eth_hdr(skb)->h_proto == htons(ETH_P_ARP)) { const struct arphdr *ap; |