]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - net/ipv6/netfilter/nf_conntrack_proto_icmpv6.c
netfilter: conntrack: simplify event caching system
[karo-tx-linux.git] / net / ipv6 / netfilter / nf_conntrack_proto_icmpv6.c
index 41b8a956e1becaa1ef2261d5af1d7397291c764d..a0acd9655fef00564e789cd8e06b74c255eb1dfb 100644 (file)
@@ -104,7 +104,6 @@ static int icmpv6_packet(struct nf_conn *ct,
                        nf_ct_kill_acct(ct, ctinfo, skb);
        } else {
                atomic_inc(&ct->proto.icmp.count);
-               nf_conntrack_event_cache(IPCT_PROTOINFO_VOLATILE, ct);
                nf_ct_refresh_acct(ct, ctinfo, skb, nf_ct_icmpv6_timeout);
        }
 
@@ -269,6 +268,11 @@ static int icmpv6_nlattr_to_tuple(struct nlattr *tb[],
 
        return 0;
 }
+
+static int icmpv6_nlattr_tuple_size(void)
+{
+       return nla_policy_len(icmpv6_nla_policy, CTA_PROTO_MAX + 1);
+}
 #endif
 
 #ifdef CONFIG_SYSCTL
@@ -300,6 +304,7 @@ struct nf_conntrack_l4proto nf_conntrack_l4proto_icmpv6 __read_mostly =
        .error                  = icmpv6_error,
 #if defined(CONFIG_NF_CT_NETLINK) || defined(CONFIG_NF_CT_NETLINK_MODULE)
        .tuple_to_nlattr        = icmpv6_tuple_to_nlattr,
+       .nlattr_tuple_size      = icmpv6_nlattr_tuple_size,
        .nlattr_to_tuple        = icmpv6_nlattr_to_tuple,
        .nla_policy             = icmpv6_nla_policy,
 #endif