Lines Matching refs:handler

41 #define for_each_protocol_rcu(head, handler)		\  argument
42 for (handler = rcu_dereference(head); \
43 handler != NULL; \
44 handler = rcu_dereference(handler->next)) \
49 struct xfrm6_protocol *handler; in xfrm6_rcv_cb() local
55 for_each_protocol_rcu(*proto_handlers(protocol), handler) in xfrm6_rcv_cb()
56 if ((ret = handler->cb_handler(skb, err)) <= 0) in xfrm6_rcv_cb()
66 struct xfrm6_protocol *handler; in xfrm6_rcv_encap() local
96 for_each_protocol_rcu(*head, handler) in xfrm6_rcv_encap()
97 if ((ret = handler->input_handler(skb, nexthdr, spi, encap_type)) != -EINVAL) in xfrm6_rcv_encap()
112 struct xfrm6_protocol *handler; in xfrm6_esp_rcv() local
116 for_each_protocol_rcu(esp6_handlers, handler) in xfrm6_esp_rcv()
117 if ((ret = handler->handler(skb)) != -EINVAL) in xfrm6_esp_rcv()
129 struct xfrm6_protocol *handler; in xfrm6_esp_err() local
131 for_each_protocol_rcu(esp6_handlers, handler) in xfrm6_esp_err()
132 if (!handler->err_handler(skb, opt, type, code, offset, info)) in xfrm6_esp_err()
141 struct xfrm6_protocol *handler; in xfrm6_ah_rcv() local
145 for_each_protocol_rcu(ah6_handlers, handler) in xfrm6_ah_rcv()
146 if ((ret = handler->handler(skb)) != -EINVAL) in xfrm6_ah_rcv()
158 struct xfrm6_protocol *handler; in xfrm6_ah_err() local
160 for_each_protocol_rcu(ah6_handlers, handler) in xfrm6_ah_err()
161 if (!handler->err_handler(skb, opt, type, code, offset, info)) in xfrm6_ah_err()
170 struct xfrm6_protocol *handler; in xfrm6_ipcomp_rcv() local
174 for_each_protocol_rcu(ipcomp6_handlers, handler) in xfrm6_ipcomp_rcv()
175 if ((ret = handler->handler(skb)) != -EINVAL) in xfrm6_ipcomp_rcv()
187 struct xfrm6_protocol *handler; in xfrm6_ipcomp_err() local
189 for_each_protocol_rcu(ipcomp6_handlers, handler) in xfrm6_ipcomp_err()
190 if (!handler->err_handler(skb, opt, type, code, offset, info)) in xfrm6_ipcomp_err()
197 .handler = xfrm6_esp_rcv,
203 .handler = xfrm6_ah_rcv,
209 .handler = xfrm6_ipcomp_rcv,
233 int xfrm6_protocol_register(struct xfrm6_protocol *handler, in xfrm6_protocol_register() argument
240 int priority = handler->priority; in xfrm6_protocol_register()
261 handler->next = *pprev; in xfrm6_protocol_register()
262 rcu_assign_pointer(*pprev, handler); in xfrm6_protocol_register()
280 int xfrm6_protocol_deregister(struct xfrm6_protocol *handler, in xfrm6_protocol_deregister() argument
296 if (t == handler) { in xfrm6_protocol_deregister()
297 *pprev = handler->next; in xfrm6_protocol_deregister()