Home
last modified time | relevance | path

Searched refs:ihl (Results 1 – 25 of 171) sorted by relevance

1234567

/Linux-v4.19/net/sched/
Dact_csum.c125 unsigned int ihl, unsigned int ipl, in tcf_csum_skb_nextlayer() argument
129 int hl = ihl + jhl; in tcf_csum_skb_nextlayer()
135 return (void *)(skb_network_header(skb) + ihl); in tcf_csum_skb_nextlayer()
138 static int tcf_csum_ipv4_icmp(struct sk_buff *skb, unsigned int ihl, in tcf_csum_ipv4_icmp() argument
143 icmph = tcf_csum_skb_nextlayer(skb, ihl, ipl, sizeof(*icmph)); in tcf_csum_ipv4_icmp()
148 skb->csum = csum_partial(icmph, ipl - ihl, 0); in tcf_csum_ipv4_icmp()
157 unsigned int ihl, unsigned int ipl) in tcf_csum_ipv4_igmp() argument
161 igmph = tcf_csum_skb_nextlayer(skb, ihl, ipl, sizeof(*igmph)); in tcf_csum_ipv4_igmp()
166 skb->csum = csum_partial(igmph, ipl - ihl, 0); in tcf_csum_ipv4_igmp()
174 static int tcf_csum_ipv6_icmp(struct sk_buff *skb, unsigned int ihl, in tcf_csum_ipv6_icmp() argument
[all …]
Dact_nat.c107 int ihl; in tcf_nat_act() local
157 ihl = iph->ihl * 4; in tcf_nat_act()
165 if (!pskb_may_pull(skb, ihl + sizeof(*tcph) + noff) || in tcf_nat_act()
166 skb_try_make_writable(skb, ihl + sizeof(*tcph) + noff)) in tcf_nat_act()
169 tcph = (void *)(skb_network_header(skb) + ihl); in tcf_nat_act()
178 if (!pskb_may_pull(skb, ihl + sizeof(*udph) + noff) || in tcf_nat_act()
179 skb_try_make_writable(skb, ihl + sizeof(*udph) + noff)) in tcf_nat_act()
182 udph = (void *)(skb_network_header(skb) + ihl); in tcf_nat_act()
195 if (!pskb_may_pull(skb, ihl + sizeof(*icmph) + noff)) in tcf_nat_act()
198 icmph = (void *)(skb_network_header(skb) + ihl); in tcf_nat_act()
[all …]
/Linux-v4.19/net/ipv4/
Dah4.c82 int l = iph->ihl*4 - sizeof(struct iphdr); in ip_clear_mutable_options()
128 int ihl = ip_hdrlen(skb); in ah_output_done() local
131 icv = ah_tmp_icv(ahp->ahash, iph, ihl); in ah_output_done()
137 if (top_iph->ihl != 5) { in ah_output_done()
139 memcpy(top_iph+1, iph+1, top_iph->ihl*4 - sizeof(struct iphdr)); in ah_output_done()
150 int ihl; in ah_output() local
173 ihl = ip_hdrlen(skb); in ah_output()
180 iph = ah_alloc_tmp(ahash, nfrags + sglists, ihl + seqhi_len); in ah_output()
183 seqhi = (__be32 *)((char *)iph + ihl); in ah_output()
197 if (top_iph->ihl != 5) { in ah_output()
[all …]
Dxfrm4_mode_transport.c25 int ihl = iph->ihl * 4; in xfrm4_transport_output() local
32 skb->transport_header = skb->network_header + ihl; in xfrm4_transport_output()
33 __skb_pull(skb, ihl); in xfrm4_transport_output()
34 memmove(skb_network_header(skb), iph, ihl); in xfrm4_transport_output()
48 int ihl = skb->data - skb_transport_header(skb); in xfrm4_transport_input() local
52 skb_network_header(skb), ihl); in xfrm4_transport_input()
55 ip_hdr(skb)->tot_len = htons(skb->len + ihl); in xfrm4_transport_input()
Dxfrm4_mode_beet.c24 iph->ihl = 5; in xfrm4_beet_make_header()
51 hdrlen + (XFRM_MODE_SKB_CB(skb)->ihl - sizeof(*top_iph))); in xfrm4_beet_output()
60 ph = __skb_pull(skb, XFRM_MODE_SKB_CB(skb)->ihl - hdrlen); in xfrm4_beet_output()
74 top_iph->ihl = sizeof(struct iphdr) / 4; in xfrm4_beet_output()
118 iph->ihl += optlen / 4; in xfrm4_beet_input()
123 iph->check = ip_fast_csum(skb_network_header(skb), iph->ihl); in xfrm4_beet_input()
Dip_input.c281 opt->optlen = iph->ihl*4 - sizeof(struct iphdr); in ip_rcv_options()
358 if (iph->ihl > 5 && ip_rcv_options(skb)) in ip_rcv_finish_core()
458 if (iph->ihl < 5 || iph->version != 4) in ip_rcv_core()
468 if (!pskb_may_pull(skb, iph->ihl*4)) in ip_rcv_core()
473 if (unlikely(ip_fast_csum((u8 *)iph, iph->ihl))) in ip_rcv_core()
480 } else if (len < (iph->ihl*4)) in ip_rcv_core()
492 skb->transport_header = skb->network_header + iph->ihl*4; in ip_rcv_core()
Dxfrm4_policy.c114 u8 *xprth = skb_network_header(skb) + iph->ihl * 4; in _decode_session4()
136 xprth = skb_network_header(skb) + iph->ihl * 4; in _decode_session4()
149 xprth = skb_network_header(skb) + iph->ihl * 4; in _decode_session4()
162 xprth = skb_network_header(skb) + iph->ihl * 4; in _decode_session4()
174 xprth = skb_network_header(skb) + iph->ihl * 4; in _decode_session4()
186 xprth = skb_network_header(skb) + iph->ihl * 4; in _decode_session4()
199 xprth = skb_network_header(skb) + iph->ihl * 4; in _decode_session4()
/Linux-v4.19/drivers/net/slip/
Dslhc.c263 th = (struct tcphdr *)(((unsigned char *)ip) + ip->ihl*4); in slhc_compress()
264 hlen = ip->ihl*4 + th->doff*4; in slhc_compress()
347 if(ip->version != cs->cs_ip.version || ip->ihl != cs->cs_ip.ihl in slhc_compress()
352 || (ip->ihl > 5 && memcmp(ip+1,cs->cs_ipopt,((ip->ihl)-5)*4) != 0) in slhc_compress()
472 if (ip->ihl > 5) in slhc_compress()
473 memcpy(cs->cs_ipopt, ip+1, ((ip->ihl) - 5) * 4); in slhc_compress()
541 hdrlen = ip->ihl * 4 + thp->doff * 4; in slhc_uncompress()
614 if (ip->ihl > 5) { in slhc_uncompress()
615 memcpy(cp, cs->cs_ipopt, (ip->ihl - 5) * 4); in slhc_uncompress()
616 cp += (ip->ihl - 5) * 4; in slhc_uncompress()
[all …]
/Linux-v4.19/net/ipv4/netfilter/
Dnf_log_ipv4.c80 ih->ihl * 4 > sizeof(struct iphdr)) { in dump_ipv4_packet()
85 optsize = ih->ihl * 4 - sizeof(struct iphdr); in dump_ipv4_packet()
104 iphoff+ih->ihl*4, logflags)) in dump_ipv4_packet()
111 iphoff+ih->ihl*4)) in dump_ipv4_packet()
142 ich = skb_header_pointer(skb, iphoff + ih->ihl * 4, in dump_ipv4_packet()
146 skb->len - iphoff - ih->ihl*4); in dump_ipv4_packet()
156 skb->len-iphoff-ih->ihl*4 < required_len[ich->type]) { in dump_ipv4_packet()
158 skb->len - iphoff - ih->ihl*4); in dump_ipv4_packet()
187 iphoff + ih->ihl*4+sizeof(_icmph)); in dump_ipv4_packet()
212 ah = skb_header_pointer(skb, iphoff+ih->ihl*4, in dump_ipv4_packet()
[all …]
Dnf_nat_snmp_basic_main.c133 struct udphdr *udph = (struct udphdr *)((__be32 *)iph + iph->ihl); in snmp_translate()
171 const struct udphdr *udph = (struct udphdr *)((__be32 *)iph + iph->ihl); in help()
188 if (ntohs(udph->len) != skb->len - (iph->ihl << 2)) { in help()
/Linux-v4.19/arch/arm64/include/asm/
Dchecksum.h29 static inline __sum16 ip_fast_csum(const void *iph, unsigned int ihl) in ip_fast_csum() argument
36 ihl -= 4; in ip_fast_csum()
42 } while (--ihl); in ip_fast_csum()
/Linux-v4.19/arch/powerpc/include/asm/
Dchecksum.h127 static inline __wsum ip_fast_csum_nofold(const void *iph, unsigned int ihl) in ip_fast_csum_nofold() argument
134 for (i = 0; i < ihl - 1; i++, ptr++) in ip_fast_csum_nofold()
147 : "r" (ihl - 2), "r" (*(const u32 *)iph), "r" (*ptr) in ip_fast_csum_nofold()
154 static inline __sum16 ip_fast_csum(const void *iph, unsigned int ihl) in ip_fast_csum() argument
156 return csum_fold(ip_fast_csum_nofold(iph, ihl)); in ip_fast_csum()
/Linux-v4.19/arch/x86/um/asm/
Dchecksum.h119 static inline __sum16 ip_fast_csum(const void *iph, unsigned int ihl) in ip_fast_csum() argument
143 : "=r" (sum), "=r" (iph), "=r" (ihl) in ip_fast_csum()
144 : "1" (iph), "2" (ihl) in ip_fast_csum()
/Linux-v4.19/arch/m68k/include/asm/
Dchecksum.h46 static inline __sum16 ip_fast_csum(const void *iph, unsigned int ihl) in ip_fast_csum() argument
61 : "=d" (sum), "=&a" (iph), "=&d" (ihl), "=&d" (tmp) in ip_fast_csum()
62 : "0" (sum), "1" (iph), "2" (ihl) in ip_fast_csum()
/Linux-v4.19/arch/parisc/include/asm/
Dchecksum.h42 static inline __sum16 ip_fast_csum(const void *iph, unsigned int ihl) in ip_fast_csum() argument
67 : "=r" (sum), "=r" (iph), "=r" (ihl) in ip_fast_csum()
68 : "1" (iph), "2" (ihl) in ip_fast_csum()
/Linux-v4.19/arch/arm/include/asm/
Dchecksum.h61 ip_fast_csum(const void *iph, unsigned int ihl) in ip_fast_csum() argument
81 : "=r" (sum), "=r" (iph), "=r" (ihl), "=r" (tmp1) in ip_fast_csum()
82 : "1" (iph), "2" (ihl) in ip_fast_csum()
/Linux-v4.19/arch/x86/include/asm/
Dchecksum_64.h46 static inline __sum16 ip_fast_csum(const void *iph, unsigned int ihl) in ip_fast_csum() argument
70 : "=r" (sum), "=r" (iph), "=r" (ihl) in ip_fast_csum()
71 : "1" (iph), "2" (ihl) in ip_fast_csum()
Dchecksum_32.h70 static inline __sum16 ip_fast_csum(const void *iph, unsigned int ihl) in ip_fast_csum() argument
94 : "=r" (sum), "=r" (iph), "=r" (ihl) in ip_fast_csum()
95 : "1" (iph), "2" (ihl) in ip_fast_csum()
/Linux-v4.19/arch/sh/include/asm/
Dchecksum_32.h89 static inline __sum16 ip_fast_csum(const void *iph, unsigned int ihl) in ip_fast_csum() argument
110 : "=r" (sum), "=r" (iph), "=r" (ihl), "=&r" (__dummy0), "=&z" (__dummy1) in ip_fast_csum()
111 : "1" (iph), "2" (ihl) in ip_fast_csum()
/Linux-v4.19/net/ipv6/
Dxfrm6_mode_transport.c53 int ihl = skb->data - skb_transport_header(skb); in xfrm6_transport_input() local
57 skb_network_header(skb), ihl); in xfrm6_transport_input()
60 ipv6_hdr(skb)->payload_len = htons(skb->len + ihl - in xfrm6_transport_input()
/Linux-v4.19/arch/arc/include/asm/
Dchecksum.h41 ip_fast_csum(const void *iph, unsigned int ihl) in ip_fast_csum() argument
62 : "r"(ihl) in ip_fast_csum()
/Linux-v4.19/arch/xtensa/include/asm/
Dchecksum.h90 static __inline__ __sum16 ip_fast_csum(const void *iph, unsigned int ihl) in ip_fast_csum() argument
117 : "=r" (sum), "=r" (iph), "=r" (ihl), "=&r" (tmp), in ip_fast_csum()
119 : "1" (iph), "2" (ihl) in ip_fast_csum()
/Linux-v4.19/samples/bpf/
Dparse_varlen.c62 ihl_len = iph->ihl * 4; in parse_ipv4()
68 ihl_len += iph->ihl * 4; in parse_ipv4()
95 ihl_len += iph->ihl * 4; in parse_ipv6()
/Linux-v4.19/include/net/netfilter/
Dnf_tables_ipv4.h31 if (iph->ihl < 5 || iph->version != 4) in __nft_set_pktinfo_ipv4_validate()
35 thoff = iph->ihl * 4; in __nft_set_pktinfo_ipv4_validate()
/Linux-v4.19/arch/s390/include/asm/
Dchecksum.h85 static inline __sum16 ip_fast_csum(const void *iph, unsigned int ihl) in ip_fast_csum() argument
87 return csum_fold(csum_partial(iph, ihl*4, 0)); in ip_fast_csum()

1234567