Lines Matching defs:iph
263 const struct iphdr *iph;
277 iph = ip_hdr(skb);
279 opt->optlen = iph->ihl*4 - sizeof(struct iphdr);
293 &iph->saddr,
294 &iph->daddr);
308 static bool ip_can_use_hint(const struct sk_buff *skb, const struct iphdr *iph,
311 return hint && !skb_dst(skb) && ip_hdr(hint)->daddr == iph->daddr &&
312 ip_hdr(hint)->tos == iph->tos;
321 const struct iphdr *iph = ip_hdr(skb);
327 if (ip_can_use_hint(skb, iph, hint)) {
328 err = ip_route_use_hint(skb, iph->daddr, iph->saddr, iph->tos,
337 !ip_is_fragment(iph)) {
338 switch (iph->protocol) {
343 /* must reload iph, skb->head might have changed */
344 iph = ip_hdr(skb);
353 /* must reload iph, skb->head might have changed */
354 iph = ip_hdr(skb);
365 err = ip_route_input_noref(skb, iph->daddr, iph->saddr,
366 iph->tos, dev);
387 if (iph->ihl > 5 && ip_rcv_options(skb, dev))
458 const struct iphdr *iph;
483 iph = ip_hdr(skb);
496 if (iph->ihl < 5 || iph->version != 4)
503 IPSTATS_MIB_NOECTPKTS + (iph->tos & INET_ECN_MASK),
506 if (!pskb_may_pull(skb, iph->ihl*4))
509 iph = ip_hdr(skb);
511 if (unlikely(ip_fast_csum((u8 *)iph, iph->ihl)))
514 len = iph_totlen(skb, iph);
519 } else if (len < (iph->ihl*4))
524 * Note this now means skb->len holds ntohs(iph->tot_len).
531 iph = ip_hdr(skb);
532 skb->transport_header = skb->network_header + iph->ihl*4;