Lines Matching refs:xfrm_policy
63 static void __xfrm_policy_link(struct xfrm_policy *pol, int dir);
64 static struct xfrm_policy *__xfrm_policy_unlink(struct xfrm_policy *pol,
67 static inline bool xfrm_pol_hold_rcu(struct xfrm_policy *policy) in xfrm_pol_hold_rcu()
191 struct xfrm_policy *xp = from_timer(xp, t, timer); in xfrm_policy_timer()
263 struct xfrm_policy *xfrm_policy_alloc(struct net *net, gfp_t gfp) in xfrm_policy_alloc()
265 struct xfrm_policy *policy; in xfrm_policy_alloc()
267 policy = kzalloc(sizeof(struct xfrm_policy), gfp); in xfrm_policy_alloc()
287 struct xfrm_policy *policy = container_of(head, struct xfrm_policy, rcu); in xfrm_policy_destroy_rcu()
295 void xfrm_policy_destroy(struct xfrm_policy *policy) in xfrm_policy_destroy()
310 static void xfrm_policy_kill(struct xfrm_policy *policy) in xfrm_policy_kill()
398 struct xfrm_policy *pol; in xfrm_dst_hash_transfer()
433 struct xfrm_policy *pol; in xfrm_idx_hash_transfer()
571 struct xfrm_policy *pol; in xfrm_hash_rebuild()
572 struct xfrm_policy *policy; in xfrm_hash_rebuild()
659 struct xfrm_policy *p; in xfrm_gen_index()
701 static void xfrm_policy_requeue(struct xfrm_policy *old, in xfrm_policy_requeue()
702 struct xfrm_policy *new) in xfrm_policy_requeue()
728 static bool xfrm_policy_mark_match(struct xfrm_policy *policy, in xfrm_policy_mark_match()
729 struct xfrm_policy *pol) in xfrm_policy_mark_match()
743 int xfrm_policy_insert(int dir, struct xfrm_policy *policy, int excl) in xfrm_policy_insert()
746 struct xfrm_policy *pol; in xfrm_policy_insert()
747 struct xfrm_policy *delpol; in xfrm_policy_insert()
809 struct xfrm_policy *xfrm_policy_bysel_ctx(struct net *net, u32 mark, u32 if_id, in xfrm_policy_bysel_ctx()
815 struct xfrm_policy *pol, *ret; in xfrm_policy_bysel_ctx()
850 struct xfrm_policy *xfrm_policy_byid(struct net *net, u32 mark, u32 if_id, in xfrm_policy_byid()
854 struct xfrm_policy *pol, *ret; in xfrm_policy_byid()
898 struct xfrm_policy *pol; in xfrm_policy_flush_secctx_check()
948 struct xfrm_policy *pol; in xfrm_policy_flush()
997 int (*func)(struct xfrm_policy *, int, int, void*), in xfrm_policy_walk() argument
1000 struct xfrm_policy *pol; in xfrm_policy_walk()
1021 pol = container_of(x, struct xfrm_policy, walk); in xfrm_policy_walk()
1069 static int xfrm_policy_match(const struct xfrm_policy *pol, in xfrm_policy_match()
1091 static struct xfrm_policy *xfrm_policy_lookup_bytype(struct net *net, u8 type, in xfrm_policy_lookup_bytype()
1097 struct xfrm_policy *pol, *ret; in xfrm_policy_lookup_bytype()
1162 static struct xfrm_policy *xfrm_policy_lookup(struct net *net, in xfrm_policy_lookup()
1167 struct xfrm_policy *pol; in xfrm_policy_lookup()
1178 static struct xfrm_policy *xfrm_sk_policy_lookup(const struct sock *sk, int dir, in xfrm_sk_policy_lookup()
1182 struct xfrm_policy *pol; in xfrm_sk_policy_lookup()
1222 static void __xfrm_policy_link(struct xfrm_policy *pol, int dir) in __xfrm_policy_link()
1231 static struct xfrm_policy *__xfrm_policy_unlink(struct xfrm_policy *pol, in __xfrm_policy_unlink()
1251 static void xfrm_sk_policy_link(struct xfrm_policy *pol, int dir) in xfrm_sk_policy_link()
1256 static void xfrm_sk_policy_unlink(struct xfrm_policy *pol, int dir) in xfrm_sk_policy_unlink()
1261 int xfrm_policy_delete(struct xfrm_policy *pol, int dir) in xfrm_policy_delete()
1276 int xfrm_sk_policy_insert(struct sock *sk, int dir, struct xfrm_policy *pol) in xfrm_sk_policy_insert()
1279 struct xfrm_policy *old_pol; in xfrm_sk_policy_insert()
1312 static struct xfrm_policy *clone_policy(const struct xfrm_policy *old, int dir) in clone_policy()
1314 struct xfrm_policy *newp = xfrm_policy_alloc(xp_net(old), GFP_ATOMIC); in clone_policy()
1346 const struct xfrm_policy *p; in __xfrm_sk_clone_policy()
1347 struct xfrm_policy *np; in __xfrm_sk_clone_policy()
1383 xfrm_tmpl_resolve_one(struct xfrm_policy *policy, const struct flowi *fl, in xfrm_tmpl_resolve_one()
1442 xfrm_tmpl_resolve(struct xfrm_policy **pols, int npols, const struct flowi *fl, in xfrm_tmpl_resolve()
1569 static struct dst_entry *xfrm_bundle_create(struct xfrm_policy *policy, in xfrm_bundle_create()
1696 struct xfrm_policy **pols, in xfrm_expand_policies()
1741 xfrm_resolve_and_create_bundle(struct xfrm_policy **pols, int num_pols, in xfrm_resolve_and_create_bundle()
1772 memcpy(xdst->pols, pols, sizeof(struct xfrm_policy *) * num_pols); in xfrm_resolve_and_create_bundle()
1783 struct xfrm_policy *pol = from_timer(pol, t, polq.hold_timer); in xfrm_policy_queue_process()
1859 struct xfrm_policy *pol = xdst->pols[0]; in xdst_queue_output()
1960 struct xfrm_policy *pols[XFRM_POLICY_TYPE_MAX]; in xfrm_bundle_lookup()
2007 memcpy(xdst->pols, pols, sizeof(struct xfrm_policy *) * num_pols); in xfrm_bundle_lookup()
2049 struct xfrm_policy *pols[XFRM_POLICY_TYPE_MAX]; in xfrm_lookup_with_ifid()
2118 memcpy(pols, xdst->pols, sizeof(struct xfrm_policy *) * num_pols); in xfrm_lookup_with_ifid()
2323 struct xfrm_policy *pol; in __xfrm_policy_check()
2324 struct xfrm_policy *pols[XFRM_POLICY_TYPE_MAX]; in __xfrm_policy_check()
2964 static void xfrm_audit_common_policyinfo(struct xfrm_policy *xp, in xfrm_audit_common_policyinfo()
2998 void xfrm_audit_policy_add(struct xfrm_policy *xp, int result, bool task_valid) in xfrm_audit_policy_add()
3012 void xfrm_audit_policy_delete(struct xfrm_policy *xp, int result, in xfrm_audit_policy_delete()
3050 static struct xfrm_policy *xfrm_migrate_policy_find(const struct xfrm_selector *sel, in xfrm_migrate_policy_find()
3053 struct xfrm_policy *pol, *ret = NULL; in xfrm_migrate_policy_find()
3116 static int xfrm_policy_migrate(struct xfrm_policy *pol, in xfrm_policy_migrate()
3191 struct xfrm_policy *pol = NULL; in xfrm_migrate()