Lines Matching refs:skb
16 static unsigned int skb_headlen(const struct sk_buff *skb)
18 return skb->len - skb->data_len;
21 static unsigned int skb_headroom(const struct sk_buff *skb)
23 return skb->data - skb->head;
26 static int skb_checksum_start_offset(const struct sk_buff *skb)
28 return skb->csum_start - skb_headroom(skb);
32 int decap_sanity(struct __sk_buff *skb)
39 if (skb->protocol != __bpf_constant_htons(ETH_P_IPV6))
42 if (bpf_skb_load_bytes(skb, ETH_HLEN, &ip6h, sizeof(ip6h)))
48 if (bpf_skb_load_bytes(skb, ETH_HLEN + sizeof(ip6h), &udph, sizeof(udph)))
54 kskb = bpf_cast_to_kern_ctx(skb);
56 err = bpf_skb_adjust_room(skb, -(s32)(ETH_HLEN + sizeof(ip6h) + sizeof(udph)),