Home
last modified time | relevance | path

Searched refs:ip4 (Results 1 – 25 of 67) sorted by relevance

123

/linux-6.1.9/tools/testing/selftests/net/bpf/
Dnat6to4.c156 const struct iphdr *const ip4 = (void *)(eth + 1); in sched_cls_egress4_snat4_prog() local
171 if (ip4->version != 4) in sched_cls_egress4_snat4_prog()
175 if (ip4->ihl != 5) in sched_cls_egress4_snat4_prog()
179 if (bpf_htons(ip4->tot_len) > 0xFFFF - sizeof(struct ipv6hdr)) in sched_cls_egress4_snat4_prog()
185 for (int i = 0; i < sizeof(*ip4) / sizeof(__u16); ++i) in sched_cls_egress4_snat4_prog()
186 sum4 += ((__u16 *)ip4)[i]; in sched_cls_egress4_snat4_prog()
196 if (bpf_ntohs(ip4->tot_len) < sizeof(*ip4)) in sched_cls_egress4_snat4_prog()
200 if (ip4->frag_off & ~bpf_htons(IP_DF)) in sched_cls_egress4_snat4_prog()
203 switch (ip4->protocol) { in sched_cls_egress4_snat4_prog()
210 if (data + sizeof(*ip4) + sizeof(struct udphdr) > data_end) in sched_cls_egress4_snat4_prog()
[all …]
/linux-6.1.9/drivers/infiniband/core/
Dud_header.c121 { STRUCT_FIELD(ip4, ver),
125 { STRUCT_FIELD(ip4, hdr_len),
129 { STRUCT_FIELD(ip4, tos),
133 { STRUCT_FIELD(ip4, tot_len),
137 { STRUCT_FIELD(ip4, id),
141 { STRUCT_FIELD(ip4, frag_off),
145 { STRUCT_FIELD(ip4, ttl),
149 { STRUCT_FIELD(ip4, protocol),
153 { STRUCT_FIELD(ip4, check),
157 { STRUCT_FIELD(ip4, saddr),
[all …]
/linux-6.1.9/net/tipc/
Dudp_media.c430 struct sockaddr_in ip4; in __tipc_nl_add_udp_addr() local
432 memset(&ip4, 0, sizeof(ip4)); in __tipc_nl_add_udp_addr()
433 ip4.sin_family = AF_INET; in __tipc_nl_add_udp_addr()
434 ip4.sin_port = addr->port; in __tipc_nl_add_udp_addr()
435 ip4.sin_addr.s_addr = addr->ipv4.s_addr; in __tipc_nl_add_udp_addr()
436 if (nla_put(skb, nla_t, sizeof(ip4), &ip4)) in __tipc_nl_add_udp_addr()
589 struct sockaddr_in *ip4 = (struct sockaddr_in *)&sa; in tipc_parse_udp_addr() local
592 addr->port = ip4->sin_port; in tipc_parse_udp_addr()
593 addr->ipv4.s_addr = ip4->sin_addr.s_addr; in tipc_parse_udp_addr()
/linux-6.1.9/drivers/net/ethernet/intel/ixgbevf/
Dipsec.c180 __be32 spi, bool ip4) in ixgbevf_ipsec_find_rx_state() argument
189 ((ip4 && *daddr == rsa->xs->id.daddr.a4) || in ixgbevf_ipsec_find_rx_state()
190 (!ip4 && !memcmp(daddr, &rsa->xs->id.daddr.a6, in ixgbevf_ipsec_find_rx_state()
561 struct iphdr *ip4 = NULL; in ixgbevf_ipsec_rx() local
574 ip4 = (struct iphdr *)(skb->data + ETH_HLEN); in ixgbevf_ipsec_rx()
575 daddr = &ip4->daddr; in ixgbevf_ipsec_rx()
576 c_hdr = (u8 *)ip4 + ip4->ihl * 4; in ixgbevf_ipsec_rx()
598 xs = ixgbevf_ipsec_find_rx_state(ipsec, daddr, proto, spi, !!ip4); in ixgbevf_ipsec_rx()
/linux-6.1.9/drivers/net/
Damt.c233 &snode->source_addr.ip4, in amt_destroy_source()
234 &gnode->group_addr.ip4); in amt_destroy_source()
266 &gnode->group_addr.ip4); in amt_del_group()
352 &snode->source_addr.ip4, in amt_act_src()
353 &gnode->group_addr.ip4, in amt_act_src()
499 &gnode->group_addr.ip4); in amt_add_group()
598 &tunnel->ip4, ntohs(tunnel->source_port), in __amt_update_relay_status()
1078 fl4.daddr = tunnel->ip4; in amt_send_multicast_data()
1083 netdev_dbg(amt->dev, "no route to %pI4\n", &tunnel->ip4); in amt_send_multicast_data()
1132 fl4.daddr = tunnel->ip4; in amt_send_membership_query()
[all …]
/linux-6.1.9/net/ipv4/
Dxfrm4_protocol.c68 XFRM_TUNNEL_SKB_CB(skb)->tunnel.ip4 = NULL; in xfrm4_rcv_encap()
101 XFRM_TUNNEL_SKB_CB(skb)->tunnel.ip4 = NULL; in xfrm4_esp_rcv()
129 XFRM_TUNNEL_SKB_CB(skb)->tunnel.ip4 = NULL; in xfrm4_ah_rcv()
157 XFRM_TUNNEL_SKB_CB(skb)->tunnel.ip4 = NULL; in xfrm4_ipcomp_rcv()
Dip_vti.c61 XFRM_TUNNEL_SKB_CB(skb)->tunnel.ip4 = tunnel; in vti_input()
100 struct ip_tunnel *tunnel = XFRM_TUNNEL_SKB_CB(skb)->tunnel.ip4; in vti_rcv_cb()
182 fl->u.ip4.flowi4_oif = dev->ifindex; in vti_xmit()
183 fl->u.ip4.flowi4_flags |= FLOWI_FLAG_ANYSRC; in vti_xmit()
184 rt = __ip_route_output_key(dev_net(dev), &fl->u.ip4); in vti_xmit()
Dnetfilter.c89 struct rtable *rt = ip_route_output_key(net, &fl->u.ip4); in nf_ip_route()
Dfib_rules.c136 err = fib_table_lookup(tbl, &flp->u.ip4, in fib4_rule_action()
181 struct flowi4 *fl4 = &fl->u.ip4; in fib4_rule_match()
Ddatagram.c48 fl4 = &inet->cork.fl.u.ip4; in __ip4_datagram_connect()
/linux-6.1.9/net/netfilter/
Dnft_flow_offload.c234 fl.u.ip4.daddr = ct->tuplehash[dir].tuple.src.u3.ip; in nft_flow_route()
235 fl.u.ip4.saddr = ct->tuplehash[!dir].tuple.src.u3.ip; in nft_flow_route()
236 fl.u.ip4.flowi4_oif = nft_in(pkt)->ifindex; in nft_flow_route()
237 fl.u.ip4.flowi4_iif = this_dst->dev->ifindex; in nft_flow_route()
238 fl.u.ip4.flowi4_tos = RT_TOS(ip_hdr(pkt->skb)->tos); in nft_flow_route()
239 fl.u.ip4.flowi4_mark = pkt->skb->mark; in nft_flow_route()
240 fl.u.ip4.flowi4_flags = FLOWI_FLAG_ANYSRC; in nft_flow_route()
Dnft_rt.c32 fl.u.ip4.daddr = ip_hdr(skb)->saddr; in get_tcpmss()
/linux-6.1.9/net/bridge/
Dbr_mdb.c157 ip->dst.ip4 = entry->addr.u.ip4; in __mdb_entry_to_br_ip()
159 ip->src.ip4 = nla_get_in_addr(mdb_attrs[MDBE_ATTR_SOURCE]); in __mdb_entry_to_br_ip()
195 ent->addr.src.ip4)) { in __mdb_fill_srcs()
255 e.addr.u.ip4 = mp->addr.dst.ip4; in __mdb_fill_info()
279 if (mp->addr.src.ip4) { in __mdb_fill_info()
281 mp->addr.src.ip4)) in __mdb_fill_info()
520 if (pg->key.addr.src.ip4) in rtnl_mdb_nlmsg_size()
675 if (!ipv4_is_multicast(entry->addr.u.ip4)) { in is_valid_mdb_entry()
679 if (ipv4_is_local_multicast(entry->addr.u.ip4)) { in is_valid_mdb_entry()
Dbr_private_mcast_eht.h10 __be32 ip4; member
Dbr_multicast.c124 br_dst.dst.ip4 = dst; in br_mdb_ip4_get()
166 ip.dst.ip4 = ip_hdr(skb)->daddr; in br_mdb_get()
170 ip.src.ip4 = ip_hdr(skb)->saddr; in br_mdb_get()
174 ip.src.ip4 = 0; in br_mdb_get()
919 ihv3->srcs[lmqt_srcs++] = ent->addr.src.ip4; in br_ip4_multicast_alloc_query()
1124 ip4_dst = ip_dst ? ip_dst->dst.ip4 : htonl(INADDR_ALLHOSTS_GROUP); in br_multicast_alloc_query()
1126 ip4_dst, group->dst.ip4, in br_multicast_alloc_query()
1220 if (ip->src.ip4 == ent->addr.src.ip4) in br_multicast_find_group_src()
1245 if (ipv4_is_zeronet(src_ip->src.ip4) || in br_multicast_new_group_src()
1246 ipv4_is_multicast(src_ip->src.ip4)) in br_multicast_new_group_src()
[all …]
/linux-6.1.9/include/net/
Damt.h133 __be32 ip4; member
248 __be32 ip4; member
258 __be32 ip4; member
Dflow.h157 struct flowi4 ip4; member
175 return container_of(fl4, struct flowi, u.ip4); in flowi4_to_flowi()
Dxfrm.h603 struct ip_tunnel *ip4; member
1274 return (xfrm_address_t *)&fl->u.ip4.daddr; in xfrm_flowi_daddr()
1286 return (xfrm_address_t *)&fl->u.ip4.saddr; in xfrm_flowi_saddr()
1300 memcpy(&saddr->a4, &fl->u.ip4.saddr, sizeof(saddr->a4)); in xfrm_flowi_addr_get()
1301 memcpy(&daddr->a4, &fl->u.ip4.daddr, sizeof(daddr->a4)); in xfrm_flowi_addr_get()
1353 (const xfrm_address_t *)&fl->u.ip4.daddr, in xfrm_state_addr_flow_check()
1354 (const xfrm_address_t *)&fl->u.ip4.saddr); in xfrm_state_addr_flow_check()
1613 XFRM_TUNNEL_SKB_CB(skb)->tunnel.ip4 = NULL; in xfrm4_rcv_spi()
2025 if (XFRM_TUNNEL_SKB_CB(skb)->tunnel.ip4) in xfrm_tunnel_check()
/linux-6.1.9/drivers/infiniband/ulp/srp/
Dib_srp.h245 struct sockaddr_in ip4; member
251 struct sockaddr_in ip4; member
/linux-6.1.9/drivers/net/ipvlan/
Dipvlan.h79 struct in_addr ip4; /* IPv4 address on logical interface */ member
82 #define ip4addr ipu.ip4
/linux-6.1.9/include/linux/
Dif_bridge.h18 __be32 ip4; member
24 __be32 ip4; member
/linux-6.1.9/drivers/net/ethernet/intel/ixgbe/
Dixgbe_ipsec.c394 __be32 spi, bool ip4) in ixgbe_ipsec_find_rx_state() argument
405 ((ip4 && *daddr == rsa->xs->id.daddr.a4) || in ixgbe_ipsec_find_rx_state()
406 (!ip4 && !memcmp(daddr, &rsa->xs->id.daddr.a6, in ixgbe_ipsec_find_rx_state()
1168 struct iphdr *ip4 = NULL; in ixgbe_ipsec_rx() local
1181 ip4 = (struct iphdr *)(skb->data + ETH_HLEN); in ixgbe_ipsec_rx()
1182 daddr = &ip4->daddr; in ixgbe_ipsec_rx()
1183 c_hdr = (u8 *)ip4 + ip4->ihl * 4; in ixgbe_ipsec_rx()
1205 xs = ixgbe_ipsec_find_rx_state(ipsec, daddr, proto, spi, !!ip4); in ixgbe_ipsec_rx()
/linux-6.1.9/drivers/net/ethernet/mellanox/mlx5/core/en/tc/act/
Dpedit.h12 struct iphdr ip4; member
Dpedit.c12 [FLOW_ACT_MANGLE_HDR_TYPE_IP4] = offsetof(struct pedit_headers, ip4),
/linux-6.1.9/drivers/infiniband/hw/qedr/
Dqedr_roce_cm.c469 udh->ip4.protocol = IPPROTO_UDP; in qedr_gsi_build_header()
470 udh->ip4.tos = htonl(grh->flow_label); in qedr_gsi_build_header()
471 udh->ip4.frag_off = htons(IP_DF); in qedr_gsi_build_header()
472 udh->ip4.ttl = grh->hop_limit; in qedr_gsi_build_header()
475 udh->ip4.saddr = ipv4_addr; in qedr_gsi_build_header()
477 udh->ip4.daddr = ipv4_addr; in qedr_gsi_build_header()

123