Home
last modified time | relevance | path

Searched refs:regs (Results 1 – 25 of 57) sorted by relevance

123

/net/netfilter/
Dnf_tables_core.c78 struct nft_regs *regs) in nft_bitwise_fast_eval() argument
81 u32 *src = &regs->data[priv->sreg]; in nft_bitwise_fast_eval()
82 u32 *dst = &regs->data[priv->dreg]; in nft_bitwise_fast_eval()
88 struct nft_regs *regs) in nft_cmp_fast_eval() argument
92 if (((regs->data[priv->sreg] & priv->mask) == priv->data) ^ priv->inv) in nft_cmp_fast_eval()
94 regs->verdict.code = NFT_BREAK; in nft_cmp_fast_eval()
98 struct nft_regs *regs) in nft_cmp16_fast_eval() argument
101 const u64 *reg_data = (const u64 *)&regs->data[priv->sreg]; in nft_cmp16_fast_eval()
108 regs->verdict.code = NFT_BREAK; in nft_cmp16_fast_eval()
114 const struct nft_regs *regs) in __nft_trace_verdict() argument
[all …]
Dnft_synproxy.c45 struct nft_regs *regs, in nft_synproxy_eval_v4() argument
61 regs->verdict.code = NF_STOLEN; in nft_synproxy_eval_v4()
67 regs->verdict.code = NF_STOLEN; in nft_synproxy_eval_v4()
69 regs->verdict.code = NF_DROP; in nft_synproxy_eval_v4()
76 struct nft_regs *regs, in nft_synproxy_eval_v6() argument
92 regs->verdict.code = NF_STOLEN; in nft_synproxy_eval_v6()
98 regs->verdict.code = NF_STOLEN; in nft_synproxy_eval_v6()
100 regs->verdict.code = NF_DROP; in nft_synproxy_eval_v6()
107 struct nft_regs *regs, in nft_synproxy_do_eval() argument
117 regs->verdict.code = NFT_BREAK; in nft_synproxy_do_eval()
[all …]
Dnft_xfrm.c119 struct nft_regs *regs, in nft_xfrm_state_get_key() argument
122 u32 *dest = &regs->data[priv->dreg]; in nft_xfrm_state_get_key()
127 regs->verdict.code = NFT_BREAK; in nft_xfrm_state_get_key()
156 regs->verdict.code = NFT_BREAK; in nft_xfrm_state_get_key()
160 struct nft_regs *regs, in nft_xfrm_get_eval_in() argument
167 regs->verdict.code = NFT_BREAK; in nft_xfrm_get_eval_in()
172 nft_xfrm_state_get_key(priv, regs, state); in nft_xfrm_get_eval_in()
176 struct nft_regs *regs, in nft_xfrm_get_eval_out() argument
187 nft_xfrm_state_get_key(priv, regs, dst->xfrm); in nft_xfrm_get_eval_out()
191 regs->verdict.code = NFT_BREAK; in nft_xfrm_get_eval_out()
[all …]
Dnft_bitwise.c64 struct nft_regs *regs, const struct nft_pktinfo *pkt) in nft_bitwise_eval() argument
67 const u32 *src = &regs->data[priv->sreg]; in nft_bitwise_eval()
68 u32 *dst = &regs->data[priv->dreg]; in nft_bitwise_eval()
270 struct nft_offload_reg *reg = &ctx->regs[priv->dreg]; in nft_bitwise_offload()
293 if (!track->regs[priv->sreg].selector) in nft_bitwise_reduce()
296 bitwise = nft_expr_priv(track->regs[priv->dreg].selector); in nft_bitwise_reduce()
297 if (track->regs[priv->sreg].selector == track->regs[priv->dreg].selector && in nft_bitwise_reduce()
298 track->regs[priv->sreg].num_reg == 0 && in nft_bitwise_reduce()
299 track->regs[priv->dreg].bitwise && in nft_bitwise_reduce()
300 track->regs[priv->dreg].bitwise->ops == expr->ops && in nft_bitwise_reduce()
[all …]
Dnft_tproxy.c22 struct nft_regs *regs, in nft_tproxy_eval_v4() argument
35 regs->verdict.code = NFT_BREAK; in nft_tproxy_eval_v4()
41 regs->verdict.code = NFT_BREAK; in nft_tproxy_eval_v4()
55 taddr = nft_reg_load_be32(&regs->data[priv->sreg_addr]); in nft_tproxy_eval_v4()
59 tport = nft_reg_load_be16(&regs->data[priv->sreg_port]); in nft_tproxy_eval_v4()
80 regs->verdict.code = NFT_BREAK; in nft_tproxy_eval_v4()
85 struct nft_regs *regs, in nft_tproxy_eval_v6() argument
102 regs->verdict.code = NFT_BREAK; in nft_tproxy_eval_v6()
109 regs->verdict.code = NFT_BREAK; in nft_tproxy_eval_v6()
123 memcpy(&taddr, &regs->data[priv->sreg_addr], sizeof(taddr)); in nft_tproxy_eval_v6()
[all …]
Dnft_socket.c20 struct nft_regs *regs, struct sock *sk, in nft_socket_wildcard() argument
33 regs->verdict.code = NFT_BREAK; in nft_socket_wildcard()
85 struct nft_regs *regs, in nft_socket_eval() argument
91 u32 *dest = &regs->data[priv->dreg]; in nft_socket_eval()
100 regs->verdict.code = NFT_BREAK; in nft_socket_eval()
112 regs->verdict.code = NFT_BREAK; in nft_socket_eval()
118 regs->verdict.code = NFT_BREAK; in nft_socket_eval()
121 nft_socket_wildcard(pkt, regs, sk, dest); in nft_socket_eval()
126 regs->verdict.code = NFT_BREAK; in nft_socket_eval()
133 regs->verdict.code = NFT_BREAK; in nft_socket_eval()
[all …]
Dnft_nat.c34 const struct nft_regs *regs, in nft_nat_setup_addr() argument
40 regs->data[priv->sreg_addr_min]; in nft_nat_setup_addr()
42 regs->data[priv->sreg_addr_max]; in nft_nat_setup_addr()
45 memcpy(range->min_addr.ip6, &regs->data[priv->sreg_addr_min], in nft_nat_setup_addr()
47 memcpy(range->max_addr.ip6, &regs->data[priv->sreg_addr_max], in nft_nat_setup_addr()
54 const struct nft_regs *regs, in nft_nat_setup_proto() argument
58 nft_reg_load16(&regs->data[priv->sreg_proto_min]); in nft_nat_setup_proto()
60 nft_reg_load16(&regs->data[priv->sreg_proto_max]); in nft_nat_setup_proto()
104 struct nft_regs *regs, in nft_nat_eval() argument
115 nft_nat_setup_addr(&range, regs, priv); in nft_nat_eval()
[all …]
Dnft_fib_inet.c15 struct nft_regs *regs, in nft_fib_inet_eval() argument
25 return nft_fib4_eval(expr, regs, pkt); in nft_fib_inet_eval()
27 return nft_fib4_eval_type(expr, regs, pkt); in nft_fib_inet_eval()
34 return nft_fib6_eval(expr, regs, pkt); in nft_fib_inet_eval()
36 return nft_fib6_eval_type(expr, regs, pkt); in nft_fib_inet_eval()
41 regs->verdict.code = NF_DROP; in nft_fib_inet_eval()
Dnft_fib_netdev.c22 struct nft_regs *regs, in nft_fib_netdev_eval() argument
32 return nft_fib4_eval(expr, regs, pkt); in nft_fib_netdev_eval()
34 return nft_fib4_eval_type(expr, regs, pkt); in nft_fib_netdev_eval()
43 return nft_fib6_eval(expr, regs, pkt); in nft_fib_netdev_eval()
45 return nft_fib6_eval_type(expr, regs, pkt); in nft_fib_netdev_eval()
50 regs->verdict.code = NFT_BREAK; in nft_fib_netdev_eval()
Dnft_exthdr.c47 struct nft_regs *regs, in nft_exthdr_ipv6_eval() argument
51 u32 *dest = &regs->data[priv->dreg]; in nft_exthdr_ipv6_eval()
71 regs->verdict.code = NFT_BREAK; in nft_exthdr_ipv6_eval()
142 struct nft_regs *regs, in nft_exthdr_ipv4_eval() argument
146 u32 *dest = &regs->data[priv->dreg]; in nft_exthdr_ipv4_eval()
167 regs->verdict.code = NFT_BREAK; in nft_exthdr_ipv4_eval()
191 struct nft_regs *regs, in nft_exthdr_tcp_eval() argument
197 u32 *dest = &regs->data[priv->dreg]; in nft_exthdr_tcp_eval()
231 regs->verdict.code = NFT_BREAK; in nft_exthdr_tcp_eval()
235 struct nft_regs *regs, in nft_exthdr_tcp_set_eval() argument
[all …]
Dnft_osf.c20 static void nft_osf_eval(const struct nft_expr *expr, struct nft_regs *regs, in nft_osf_eval() argument
24 u32 *dest = &regs->data[priv->dreg]; in nft_osf_eval()
32 regs->verdict.code = NFT_BREAK; in nft_osf_eval()
39 regs->verdict.code = NFT_BREAK; in nft_osf_eval()
43 regs->verdict.code = NFT_BREAK; in nft_osf_eval()
147 osf = nft_expr_priv(track->regs[priv->dreg].selector); in nft_osf_reduce()
154 if (!track->regs[priv->dreg].bitwise) in nft_osf_reduce()
Dnft_fwd_netdev.c25 struct nft_regs *regs, in nft_fwd_netdev_eval() argument
29 int oif = regs->data[priv->sreg_dev]; in nft_fwd_netdev_eval()
37 regs->verdict.code = NF_STOLEN; in nft_fwd_netdev_eval()
78 int oif = ctx->regs[priv->sreg_dev].data.data[0]; in nft_fwd_netdev_offload()
95 struct nft_regs *regs, in nft_fwd_neigh_eval() argument
99 void *addr = &regs->data[priv->sreg_addr]; in nft_fwd_neigh_eval()
100 int oif = regs->data[priv->sreg_dev]; in nft_fwd_neigh_eval()
152 regs->verdict.code = verdict; in nft_fwd_neigh_eval()
Dnft_ct.c51 struct nft_regs *regs, in nft_ct_get_eval() argument
55 u32 *dest = &regs->data[priv->dreg]; in nft_ct_get_eval()
219 regs->verdict.code = NFT_BREAK; in nft_ct_get_eval()
224 struct nft_regs *regs, in nft_ct_set_zone_eval() argument
231 u16 value = nft_reg_load16(&regs->data[priv->sreg]); in nft_ct_set_zone_eval()
262 regs->verdict.code = NF_DROP; in nft_ct_set_zone_eval()
273 struct nft_regs *regs, in nft_ct_set_eval() argument
279 u32 value = regs->data[priv->sreg]; in nft_ct_set_eval()
308 &regs->data[priv->sreg], in nft_ct_set_eval()
309 &regs->data[priv->sreg], in nft_ct_set_eval()
[all …]
Dnft_connlimit.c23 struct nft_regs *regs, in nft_connlimit_do_eval() argument
42 regs->verdict.code = NF_DROP; in nft_connlimit_do_eval()
47 regs->verdict.code = NF_DROP; in nft_connlimit_do_eval()
54 regs->verdict.code = NFT_BREAK; in nft_connlimit_do_eval()
123 struct nft_regs *regs, in nft_connlimit_obj_eval() argument
128 nft_connlimit_do_eval(priv, regs, pkt, NULL); in nft_connlimit_obj_eval()
180 struct nft_regs *regs, in nft_connlimit_eval() argument
185 nft_connlimit_do_eval(priv, regs, pkt, NULL); in nft_connlimit_eval()
Dnft_ct_fast.c8 struct nft_regs *regs, in nft_ct_get_fast_eval() argument
12 u32 *dest = &regs->data[priv->dreg]; in nft_ct_get_fast_eval()
34 regs->verdict.code = NFT_BREAK; in nft_ct_get_fast_eval()
57 regs->verdict.code = NFT_BREAK; in nft_ct_get_fast_eval()
Dnft_dynset.c48 struct nft_regs *regs) in nft_dynset_new() argument
60 &regs->data[priv->sreg_key], NULL, in nft_dynset_new()
61 &regs->data[priv->sreg_data], in nft_dynset_new()
81 struct nft_regs *regs, const struct nft_pktinfo *pkt) in nft_dynset_eval() argument
89 set->ops->delete(set, &regs->data[priv->sreg_key]); in nft_dynset_eval()
93 if (set->ops->update(set, &regs->data[priv->sreg_key], nft_dynset_new, in nft_dynset_eval()
94 expr, regs, &ext)) { in nft_dynset_eval()
101 nft_set_elem_update_expr(ext, regs, pkt); in nft_dynset_eval()
104 regs->verdict.code = NFT_BREAK; in nft_dynset_eval()
109 regs->verdict.code = NFT_BREAK; in nft_dynset_eval()
Dnft_payload.c160 struct nft_regs *regs, in nft_payload_eval() argument
165 u32 *dest = &regs->data[priv->dreg]; in nft_payload_eval()
208 regs->verdict.code = NFT_BREAK; in nft_payload_eval()
264 payload = nft_expr_priv(track->regs[priv->dreg].selector); in nft_payload_reduce()
272 if (!track->regs[priv->dreg].bitwise) in nft_payload_reduce()
310 struct nft_offload_reg *reg = &ctx->regs[priv->dreg]; in nft_payload_offload_ll()
379 struct nft_offload_reg *reg = &ctx->regs[priv->dreg]; in nft_payload_offload_ip()
419 struct nft_offload_reg *reg = &ctx->regs[priv->dreg]; in nft_payload_offload_ip6()
479 struct nft_offload_reg *reg = &ctx->regs[priv->dreg]; in nft_payload_offload_tcp()
507 struct nft_offload_reg *reg = &ctx->regs[priv->dreg]; in nft_payload_offload_udp()
[all …]
Dnft_hash.c27 struct nft_regs *regs, in nft_jhash_eval() argument
31 const void *data = &regs->data[priv->sreg]; in nft_jhash_eval()
37 regs->data[priv->dreg] = h + priv->offset; in nft_jhash_eval()
47 struct nft_regs *regs, in nft_symhash_eval() argument
56 regs->data[priv->dreg] = h + priv->offset; in nft_symhash_eval()
209 symhash = nft_expr_priv(track->regs[priv->dreg].selector); in nft_symhash_reduce()
216 if (!track->regs[priv->dreg].bitwise) in nft_symhash_reduce()
Dnft_meta.c310 struct nft_regs *regs, in nft_meta_get_eval() argument
315 u32 *dest = &regs->data[priv->dreg]; in nft_meta_get_eval()
414 regs->verdict.code = NFT_BREAK; in nft_meta_get_eval()
419 struct nft_regs *regs, in nft_meta_set_eval() argument
424 u32 *sreg = &regs->data[meta->sreg]; in nft_meta_set_eval()
719 struct nft_offload_reg *reg = &ctx->regs[priv->dreg]; in nft_meta_get_offload()
758 meta = nft_expr_priv(track->regs[priv->dreg].selector); in nft_meta_get_reduce()
765 if (!track->regs[priv->dreg].bitwise) in nft_meta_get_reduce()
789 if (!track->regs[i].selector) in nft_meta_set_reduce()
792 if (track->regs[i].selector->ops != &nft_meta_get_ops) in nft_meta_set_reduce()
[all …]
Dnft_range.c24 struct nft_regs *regs, const struct nft_pktinfo *pkt) in nft_range_eval() argument
29 d1 = memcmp(&regs->data[priv->sreg], &priv->data_from, priv->len); in nft_range_eval()
30 d2 = memcmp(&regs->data[priv->sreg], &priv->data_to, priv->len); in nft_range_eval()
34 regs->verdict.code = NFT_BREAK; in nft_range_eval()
38 regs->verdict.code = NFT_BREAK; in nft_range_eval()
Dnft_compat.c74 struct nft_regs *regs, in nft_target_eval_xt() argument
92 regs->verdict.code = NFT_CONTINUE; in nft_target_eval_xt()
95 regs->verdict.code = ret; in nft_target_eval_xt()
101 struct nft_regs *regs, in nft_target_eval_bridge() argument
119 regs->verdict.code = NF_ACCEPT; in nft_target_eval_bridge()
122 regs->verdict.code = NF_DROP; in nft_target_eval_bridge()
125 regs->verdict.code = NFT_CONTINUE; in nft_target_eval_bridge()
128 regs->verdict.code = NFT_RETURN; in nft_target_eval_bridge()
131 regs->verdict.code = ret; in nft_target_eval_bridge()
393 struct nft_regs *regs, in __nft_match_eval() argument
[all …]
Dnft_objref.c17 struct nft_regs *regs, in nft_objref_eval() argument
22 obj->ops->eval(obj, regs, pkt); in nft_objref_eval()
106 struct nft_regs *regs, in nft_objref_map_eval() argument
116 found = nft_set_do_lookup(net, set, &regs->data[priv->sreg], &ext); in nft_objref_map_eval()
120 regs->verdict.code = NFT_BREAK; in nft_objref_map_eval()
125 obj->ops->eval(obj, regs, pkt); in nft_objref_map_eval()
/net/bridge/netfilter/
Dnft_meta_bridge.c25 struct nft_regs *regs, in nft_meta_bridge_get_eval() argument
30 u32 *dest = &regs->data[priv->dreg]; in nft_meta_bridge_get_eval()
63 return nft_meta_get_eval(expr, regs, pkt); in nft_meta_bridge_get_eval()
69 regs->verdict.code = NFT_BREAK; in nft_meta_bridge_get_eval()
109 struct nft_regs *regs, in nft_meta_bridge_set_eval() argument
113 u32 *sreg = &regs->data[meta->sreg]; in nft_meta_bridge_set_eval()
123 nft_meta_set_eval(expr, regs, pkt); in nft_meta_bridge_set_eval()
158 if (!track->regs[i].selector) in nft_meta_bridge_set_reduce()
161 if (track->regs[i].selector->ops != &nft_meta_bridge_get_ops) in nft_meta_bridge_set_reduce()
/net/ipv4/netfilter/
Dnft_fib_ipv4.c27 void nft_fib4_eval_type(const struct nft_expr *expr, struct nft_regs *regs, in nft_fib4_eval_type() argument
32 u32 *dst = &regs->data[priv->dreg]; in nft_fib4_eval_type()
44 regs->verdict.code = NFT_BREAK; in nft_fib4_eval_type()
57 void nft_fib4_eval(const struct nft_expr *expr, struct nft_regs *regs, in nft_fib4_eval() argument
62 u32 *dest = &regs->data[priv->dreg]; in nft_fib4_eval()
98 regs->verdict.code = NFT_BREAK; in nft_fib4_eval()
/net/ipv6/netfilter/
Dnft_fib_ipv6.c127 void nft_fib6_eval_type(const struct nft_expr *expr, struct nft_regs *regs, in nft_fib6_eval_type() argument
132 u32 *dest = &regs->data[priv->dreg]; in nft_fib6_eval_type()
137 regs->verdict.code = NFT_BREAK; in nft_fib6_eval_type()
156 void nft_fib6_eval(const struct nft_expr *expr, struct nft_regs *regs, in nft_fib6_eval() argument
162 u32 *dest = &regs->data[priv->dreg]; in nft_fib6_eval()
179 regs->verdict.code = NFT_BREAK; in nft_fib6_eval()

123