]> err.no Git - linux-2.6/blobdiff - net/ipv4/xfrm4_policy.c
the scheduled ieee80211 softmac removal
[linux-2.6] / net / ipv4 / xfrm4_policy.c
index 656345f75e0da2a11d21f83627dafc78ef54425c..10ed70491434fe9240445ae71cff6c46259e9d74 100644 (file)
@@ -36,7 +36,7 @@ static struct dst_entry *xfrm4_dst_lookup(int tos, xfrm_address_t *saddr,
        if (saddr)
                fl.fl4_src = saddr->a4;
 
-       err = __ip_route_output_key(&rt, &fl);
+       err = __ip_route_output_key(&init_net, &rt, &fl);
        dst = &rt->u.dst;
        if (err)
                dst = ERR_PTR(err);
@@ -185,7 +185,7 @@ _decode_session4(struct sk_buff *skb, struct flowi *fl, int reverse)
        fl->fl4_tos = iph->tos;
 }
 
-static inline int xfrm4_garbage_collect(void)
+static inline int xfrm4_garbage_collect(struct dst_ops *ops)
 {
        xfrm4_policy_afinfo.garbage_collect();
        return (atomic_read(&xfrm4_dst_ops.entries) > xfrm4_dst_ops.gc_thresh*2);
@@ -247,6 +247,7 @@ static struct dst_ops xfrm4_dst_ops = {
        .local_out =            __ip_local_out,
        .gc_thresh =            1024,
        .entry_size =           sizeof(struct xfrm_dst),
+       .entries =              ATOMIC_INIT(0),
 };
 
 static struct xfrm_policy_afinfo xfrm4_policy_afinfo = {