projects
/
GitHub
/
moto-9609
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0a1b0ad
)
[LLC]: Use skb_reset_mac_header in llc_mac_hdr_init
author
Arnaldo Carvalho de Melo
<acme@redhat.com>
Sat, 10 Mar 2007 15:17:29 +0000
(12:17 -0300)
committer
David S. Miller
<davem@sunset.davemloft.net>
Thu, 26 Apr 2007 05:24:35 +0000
(22:24 -0700)
skb_push updates and returns skb->data, so we can just call
skb_reset_mac_header after the call to skb_push.
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/llc/llc_output.c
patch
|
blob
|
blame
|
history
diff --git
a/net/llc/llc_output.c
b/net/llc/llc_output.c
index 729e251082754c0d772392a0f58e8bde5c98ca87..754f4fedc852fb6181d5c5bed0146096d5ff12f4 100644
(file)
--- a/
net/llc/llc_output.c
+++ b/
net/llc/llc_output.c
@@
-41,7
+41,8
@@
int llc_mac_hdr_init(struct sk_buff *skb,
struct net_device *dev = skb->dev;
struct trh_hdr *trh;
- skb->mac.raw = skb_push(skb, sizeof(*trh));
+ skb_push(skb, sizeof(*trh));
+ skb_reset_mac_header(skb);
trh = tr_hdr(skb);
trh->ac = AC;
trh->fc = LLC_FRAME;
@@
-62,7
+63,8
@@
int llc_mac_hdr_init(struct sk_buff *skb,
unsigned short len = skb->len;
struct ethhdr *eth;
- skb->mac.raw = skb_push(skb, sizeof(*eth));
+ skb_push(skb, sizeof(*eth));
+ skb_reset_mac_header(skb);
eth = eth_hdr(skb);
eth->h_proto = htons(len);
memcpy(eth->h_dest, da, ETH_ALEN);