projects
/
GitHub
/
exynos8895
/
android_kernel_samsung_universal8895.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7fe40f7
)
[NET]: Micro optimization in eth_header()
author
Denis Vlasenko
<vda@ilport.com.ua>
Tue, 28 Jun 2005 22:49:06 +0000
(15:49 -0700)
committer
David S. Miller
<davem@davemloft.net>
Tue, 28 Jun 2005 22:49:06 +0000
(15:49 -0700)
Signed-off-by: Denis Vlasenko <vda@ilport.com.ua>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ethernet/eth.c
patch
|
blob
|
blame
|
history
diff --git
a/net/ethernet/eth.c
b/net/ethernet/eth.c
index 6617ea47d3656a6b6c6cfa94e546c12dc9648f8e..ab60ea63688e757b99de1afcc2a60a174899774e 100644
(file)
--- a/
net/ethernet/eth.c
+++ b/
net/ethernet/eth.c
@@
-92,10
+92,9
@@
int eth_header(struct sk_buff *skb, struct net_device *dev, unsigned short type,
* Set the source hardware address.
*/
- if(saddr)
- memcpy(eth->h_source,saddr,dev->addr_len);
- else
- memcpy(eth->h_source,dev->dev_addr,dev->addr_len);
+ if(!saddr)
+ saddr = dev->dev_addr;
+ memcpy(eth->h_source,saddr,dev->addr_len);
/*
* Anyway, the loopback-device should never use this function...