diff options
author | Eric W. Biederman <ebiederm@xmission.com> | 2012-08-06 04:47:55 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2012-08-15 02:30:36 -0400 |
commit | b01a24078fa3fc4f0f447d1306ce5adc495ead86 (patch) | |
tree | 6949f590c81e2c1ce193b1bdaec68a60e9842879 /include/net | |
parent | bb2db45b5495455ec7580315029184550709f4a2 (diff) |
sctp: Make the mib per network namespace
Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Vlad Yasevich <vyasevich@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net')
-rw-r--r-- | include/net/netns/sctp.h | 3 | ||||
-rw-r--r-- | include/net/sctp/sctp.h | 9 |
2 files changed, 7 insertions, 5 deletions
diff --git a/include/net/netns/sctp.h b/include/net/netns/sctp.h index 9c20a82a77ec..06ccddf9566c 100644 --- a/include/net/netns/sctp.h +++ b/include/net/netns/sctp.h | |||
@@ -3,8 +3,11 @@ | |||
3 | 3 | ||
4 | struct sock; | 4 | struct sock; |
5 | struct proc_dir_entry; | 5 | struct proc_dir_entry; |
6 | struct sctp_mib; | ||
6 | 7 | ||
7 | struct netns_sctp { | 8 | struct netns_sctp { |
9 | DEFINE_SNMP_STAT(struct sctp_mib, sctp_statistics); | ||
10 | |||
8 | #ifdef CONFIG_PROC_FS | 11 | #ifdef CONFIG_PROC_FS |
9 | struct proc_dir_entry *proc_net_sctp; | 12 | struct proc_dir_entry *proc_net_sctp; |
10 | #endif | 13 | #endif |
diff --git a/include/net/sctp/sctp.h b/include/net/sctp/sctp.h index b49588a51d80..7dcd4dfd7c3f 100644 --- a/include/net/sctp/sctp.h +++ b/include/net/sctp/sctp.h | |||
@@ -221,11 +221,10 @@ extern struct kmem_cache *sctp_bucket_cachep __read_mostly; | |||
221 | #define sctp_bh_unlock_sock(sk) bh_unlock_sock(sk) | 221 | #define sctp_bh_unlock_sock(sk) bh_unlock_sock(sk) |
222 | 222 | ||
223 | /* SCTP SNMP MIB stats handlers */ | 223 | /* SCTP SNMP MIB stats handlers */ |
224 | DECLARE_SNMP_STAT(struct sctp_mib, sctp_statistics); | 224 | #define SCTP_INC_STATS(net, field) SNMP_INC_STATS((net)->sctp.sctp_statistics, field) |
225 | #define SCTP_INC_STATS(field) SNMP_INC_STATS(sctp_statistics, field) | 225 | #define SCTP_INC_STATS_BH(net, field) SNMP_INC_STATS_BH((net)->sctp.sctp_statistics, field) |
226 | #define SCTP_INC_STATS_BH(field) SNMP_INC_STATS_BH(sctp_statistics, field) | 226 | #define SCTP_INC_STATS_USER(net, field) SNMP_INC_STATS_USER((net)->sctp.sctp_statistics, field) |
227 | #define SCTP_INC_STATS_USER(field) SNMP_INC_STATS_USER(sctp_statistics, field) | 227 | #define SCTP_DEC_STATS(net, field) SNMP_DEC_STATS((net)->sctp.sctp_statistics, field) |
228 | #define SCTP_DEC_STATS(field) SNMP_DEC_STATS(sctp_statistics, field) | ||
229 | 228 | ||
230 | #endif /* !TEST_FRAME */ | 229 | #endif /* !TEST_FRAME */ |
231 | 230 | ||