aboutsummaryrefslogtreecommitdiffstats
path: root/include/net
diff options
context:
space:
mode:
authorJamal Hadi Salim <hadi@cyberus.ca>2010-02-22 19:20:22 -0500
committerDavid S. Miller <davem@davemloft.net>2010-02-22 19:20:22 -0500
commitbd55775c8dd656fc69b3a42a1c4ab32abb7e8af9 (patch)
tree766b30d5fc29d5d4849a10a290db51fe0f7c3ad7 /include/net
parentbf825f81b454fae2ffe1b675f3a549656726440e (diff)
xfrm: SA lookups signature with mark
pass mark to all SA lookups to prepare them for when we add code to have them search. Signed-off-by: Jamal Hadi Salim <hadi@cyberus.ca> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net')
-rw-r--r--include/net/xfrm.h23
1 files changed, 16 insertions, 7 deletions
diff --git a/include/net/xfrm.h b/include/net/xfrm.h
index 39f151c7f251..693523c870b9 100644
--- a/include/net/xfrm.h
+++ b/include/net/xfrm.h
@@ -1319,7 +1319,7 @@ extern struct xfrm_state *xfrm_state_find(xfrm_address_t *daddr, xfrm_address_t
1319 struct flowi *fl, struct xfrm_tmpl *tmpl, 1319 struct flowi *fl, struct xfrm_tmpl *tmpl,
1320 struct xfrm_policy *pol, int *err, 1320 struct xfrm_policy *pol, int *err,
1321 unsigned short family); 1321 unsigned short family);
1322extern struct xfrm_state * xfrm_stateonly_find(struct net *net, 1322extern struct xfrm_state *xfrm_stateonly_find(struct net *net, u32 mark,
1323 xfrm_address_t *daddr, 1323 xfrm_address_t *daddr,
1324 xfrm_address_t *saddr, 1324 xfrm_address_t *saddr,
1325 unsigned short family, 1325 unsigned short family,
@@ -1328,8 +1328,14 @@ extern int xfrm_state_check_expire(struct xfrm_state *x);
1328extern void xfrm_state_insert(struct xfrm_state *x); 1328extern void xfrm_state_insert(struct xfrm_state *x);
1329extern int xfrm_state_add(struct xfrm_state *x); 1329extern int xfrm_state_add(struct xfrm_state *x);
1330extern int xfrm_state_update(struct xfrm_state *x); 1330extern int xfrm_state_update(struct xfrm_state *x);
1331extern struct xfrm_state *xfrm_state_lookup(struct net *net, xfrm_address_t *daddr, __be32 spi, u8 proto, unsigned short family); 1331extern struct xfrm_state *xfrm_state_lookup(struct net *net, u32 mark,
1332extern struct xfrm_state *xfrm_state_lookup_byaddr(struct net *net, xfrm_address_t *daddr, xfrm_address_t *saddr, u8 proto, unsigned short family); 1332 xfrm_address_t *daddr, __be32 spi,
1333 u8 proto, unsigned short family);
1334extern struct xfrm_state *xfrm_state_lookup_byaddr(struct net *net, u32 mark,
1335 xfrm_address_t *daddr,
1336 xfrm_address_t *saddr,
1337 u8 proto,
1338 unsigned short family);
1333#ifdef CONFIG_XFRM_SUB_POLICY 1339#ifdef CONFIG_XFRM_SUB_POLICY
1334extern int xfrm_tmpl_sort(struct xfrm_tmpl **dst, struct xfrm_tmpl **src, 1340extern int xfrm_tmpl_sort(struct xfrm_tmpl **dst, struct xfrm_tmpl **src,
1335 int n, unsigned short family); 1341 int n, unsigned short family);
@@ -1366,7 +1372,8 @@ struct xfrmk_spdinfo {
1366 u32 spdhmcnt; 1372 u32 spdhmcnt;
1367}; 1373};
1368 1374
1369extern struct xfrm_state *xfrm_find_acq_byseq(struct net *net, u32 seq); 1375extern struct xfrm_state *xfrm_find_acq_byseq(struct net *net, u32 mark,
1376 u32 seq);
1370extern int xfrm_state_delete(struct xfrm_state *x); 1377extern int xfrm_state_delete(struct xfrm_state *x);
1371extern int xfrm_state_flush(struct net *net, u8 proto, struct xfrm_audit *audit_info); 1378extern int xfrm_state_flush(struct net *net, u8 proto, struct xfrm_audit *audit_info);
1372extern void xfrm_sad_getinfo(struct net *net, struct xfrmk_sadinfo *si); 1379extern void xfrm_sad_getinfo(struct net *net, struct xfrmk_sadinfo *si);
@@ -1451,9 +1458,11 @@ struct xfrm_policy *xfrm_policy_byid(struct net *net, u8, int dir, u32 id, int d
1451int xfrm_policy_flush(struct net *net, u8 type, struct xfrm_audit *audit_info); 1458int xfrm_policy_flush(struct net *net, u8 type, struct xfrm_audit *audit_info);
1452u32 xfrm_get_acqseq(void); 1459u32 xfrm_get_acqseq(void);
1453extern int xfrm_alloc_spi(struct xfrm_state *x, u32 minspi, u32 maxspi); 1460extern int xfrm_alloc_spi(struct xfrm_state *x, u32 minspi, u32 maxspi);
1454struct xfrm_state * xfrm_find_acq(struct net *net, u8 mode, u32 reqid, u8 proto, 1461struct xfrm_state *xfrm_find_acq(struct net *net, struct xfrm_mark *mark,
1455 xfrm_address_t *daddr, xfrm_address_t *saddr, 1462 u8 mode, u32 reqid, u8 proto,
1456 int create, unsigned short family); 1463 xfrm_address_t *daddr,
1464 xfrm_address_t *saddr, int create,
1465 unsigned short family);
1457extern int xfrm_sk_policy_insert(struct sock *sk, int dir, struct xfrm_policy *pol); 1466extern int xfrm_sk_policy_insert(struct sock *sk, int dir, struct xfrm_policy *pol);
1458extern int xfrm_bundle_ok(struct xfrm_policy *pol, struct xfrm_dst *xdst, 1467extern int xfrm_bundle_ok(struct xfrm_policy *pol, struct xfrm_dst *xdst,
1459 struct flowi *fl, int family, int strict); 1468 struct flowi *fl, int family, int strict);