aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv6/xfrm6_policy.c
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2012-07-17 06:29:28 -0400
committerDavid S. Miller <davem@davemloft.net>2012-07-17 06:29:28 -0400
commit6700c2709c08d74ae2c3c29b84a30da012dbc7f1 (patch)
tree1d44f300ec3cf5f9845fba7a25491e33d666426f /net/ipv6/xfrm6_policy.c
parent02f3d4ce9e81434a365f4643020b0402f6fe3332 (diff)
net: Pass optional SKB and SK arguments to dst_ops->{update_pmtu,redirect}()
This will be used so that we can compose a full flow key. Even though we have a route in this context, we need more. In the future the routes will be without destination address, source address, etc. keying. One ipv4 route will cover entire subnets, etc. In this environment we have to have a way to possess persistent storage for redirects and PMTU information. This persistent storage will exist in the FIB tables, and that's why we'll need to be able to rebuild a full lookup flow key here. Using that flow key will do a fib_lookup() and create/update the persistent entry. Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv6/xfrm6_policy.c')
-rw-r--r--net/ipv6/xfrm6_policy.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/net/ipv6/xfrm6_policy.c b/net/ipv6/xfrm6_policy.c
index f5a9cb8257b9..ef39812107b1 100644
--- a/net/ipv6/xfrm6_policy.c
+++ b/net/ipv6/xfrm6_policy.c
@@ -207,20 +207,22 @@ static inline int xfrm6_garbage_collect(struct dst_ops *ops)
207 return dst_entries_get_fast(ops) > ops->gc_thresh * 2; 207 return dst_entries_get_fast(ops) > ops->gc_thresh * 2;
208} 208}
209 209
210static void xfrm6_update_pmtu(struct dst_entry *dst, u32 mtu) 210static void xfrm6_update_pmtu(struct dst_entry *dst, struct sock *sk,
211 struct sk_buff *skb, u32 mtu)
211{ 212{
212 struct xfrm_dst *xdst = (struct xfrm_dst *)dst; 213 struct xfrm_dst *xdst = (struct xfrm_dst *)dst;
213 struct dst_entry *path = xdst->route; 214 struct dst_entry *path = xdst->route;
214 215
215 path->ops->update_pmtu(path, mtu); 216 path->ops->update_pmtu(path, sk, skb, mtu);
216} 217}
217 218
218static void xfrm6_redirect(struct dst_entry *dst, struct sk_buff *skb) 219static void xfrm6_redirect(struct dst_entry *dst, struct sock *sk,
220 struct sk_buff *skb)
219{ 221{
220 struct xfrm_dst *xdst = (struct xfrm_dst *)dst; 222 struct xfrm_dst *xdst = (struct xfrm_dst *)dst;
221 struct dst_entry *path = xdst->route; 223 struct dst_entry *path = xdst->route;
222 224
223 path->ops->redirect(path, skb); 225 path->ops->redirect(path, sk, skb);
224} 226}
225 227
226static void xfrm6_dst_destroy(struct dst_entry *dst) 228static void xfrm6_dst_destroy(struct dst_entry *dst)