aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorHarald Welte <laforge@netfilter.org>2005-08-09 23:03:40 -0400
committerDavid S. Miller <davem@sunset.davemloft.net>2005-08-29 18:39:14 -0400
commit927ccbcc28dceee29dad876982768cca29738564 (patch)
treea5bc50c92c1627e373e3cf9efbaec5c1d3f1b2b7 /include
parentbd9a26b7f2ee7567571bb5b7acc1a256c544a0dd (diff)
[NETFILTER]: attribute count is an attribute of message type, not subsytem
Prior to this patch, every nfnetlink subsystem had to specify it's attribute count. However, in reality the attribute count depends on the message type within the subsystem, not the subsystem itself. This patch moves 'attr_count' from 'struct nfnetlink_subsys' into nfnl_callback to fix this. Signed-off-by: Harald Welte <laforge@netfilter.org> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include')
-rw-r--r--include/linux/netfilter/nfnetlink.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/linux/netfilter/nfnetlink.h b/include/linux/netfilter/nfnetlink.h
index 561f9df28808..b0feb2374079 100644
--- a/include/linux/netfilter/nfnetlink.h
+++ b/include/linux/netfilter/nfnetlink.h
@@ -85,9 +85,10 @@ struct nfgenmsg {
85 85
86struct nfnl_callback 86struct nfnl_callback
87{ 87{
88 kernel_cap_t cap_required; /* capabilities required for this msg */
89 int (*call)(struct sock *nl, struct sk_buff *skb, 88 int (*call)(struct sock *nl, struct sk_buff *skb,
90 struct nlmsghdr *nlh, struct nfattr *cda[], int *errp); 89 struct nlmsghdr *nlh, struct nfattr *cda[], int *errp);
90 kernel_cap_t cap_required; /* capabilities required for this msg */
91 u_int16_t attr_count; /* number of nfattr's */
91}; 92};
92 93
93struct nfnetlink_subsystem 94struct nfnetlink_subsystem
@@ -95,7 +96,6 @@ struct nfnetlink_subsystem
95 const char *name; 96 const char *name;
96 __u8 subsys_id; /* nfnetlink subsystem ID */ 97 __u8 subsys_id; /* nfnetlink subsystem ID */
97 __u8 cb_count; /* number of callbacks */ 98 __u8 cb_count; /* number of callbacks */
98 u_int32_t attr_count; /* number of nfattr's */
99 struct nfnl_callback *cb; /* callback for individual types */ 99 struct nfnl_callback *cb; /* callback for individual types */
100}; 100};
101 101