diff options
author | Alexander Aring <alex.aring@gmail.com> | 2013-10-30 04:18:23 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2013-10-30 17:18:46 -0400 |
commit | 578d524127612354d91905f932ee88d73d8d1645 (patch) | |
tree | bfcb902eba18bd0e162eb28349985bab97e8f001 | |
parent | 3e69162ea4a9e927cb3619b96c86aae4ded60112 (diff) |
6lowpan: set 6lowpan network and transport header
This is necessary to access network header with the skb_network_header
function instead of calculate the position with mac_len, etc.
Do the same for the transport header, when we replace the IPv6 header
with the 6LoWPAN header.
Signed-off-by: Alexander Aring <alex.aring@gmail.com>
Acked-by: Werner Almesberger <werner@almesberger.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r-- | net/ieee802154/6lowpan.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/net/ieee802154/6lowpan.c b/net/ieee802154/6lowpan.c index e6db1f51bf5b..58c07fd967d1 100644 --- a/net/ieee802154/6lowpan.c +++ b/net/ieee802154/6lowpan.c | |||
@@ -654,7 +654,9 @@ static int lowpan_header_create(struct sk_buff *skb, | |||
654 | head[1] = iphc1; | 654 | head[1] = iphc1; |
655 | 655 | ||
656 | skb_pull(skb, sizeof(struct ipv6hdr)); | 656 | skb_pull(skb, sizeof(struct ipv6hdr)); |
657 | skb_reset_transport_header(skb); | ||
657 | memcpy(skb_push(skb, hc06_ptr - head), head, hc06_ptr - head); | 658 | memcpy(skb_push(skb, hc06_ptr - head), head, hc06_ptr - head); |
659 | skb_reset_network_header(skb); | ||
658 | 660 | ||
659 | lowpan_raw_dump_table(__func__, "raw skb data dump", skb->data, | 661 | lowpan_raw_dump_table(__func__, "raw skb data dump", skb->data, |
660 | skb->len); | 662 | skb->len); |