Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=49ed67a9eee3c756263feed4474e4fcf5c8eaed2
Commit:     49ed67a9eee3c756263feed4474e4fcf5c8eaed2
Parent:     bf99f1bde3b3009af74874f3465f6861431fbb66
Author:     YOSHIFUJI Hideaki <[EMAIL PROTECTED]>
AuthorDate: Fri Apr 20 15:56:48 2007 -0700
Committer:  David S. Miller <[EMAIL PROTECTED]>
CommitDate: Wed Apr 25 22:29:11 2007 -0700

    [IPV6] SNMP: Move some statistic bits to net/ipv6/proc.c.
    
    Signed-off-by: YOSHIFUJI Hideaki <[EMAIL PROTECTED]>
    Signed-off-by: David S. Miller <[EMAIL PROTECTED]>
---
 net/ipv6/af_inet6.c |   33 ---------------------------------
 net/ipv6/proc.c     |   30 ++++++++++++++++++++++++++++++
 2 files changed, 30 insertions(+), 33 deletions(-)

diff --git a/net/ipv6/af_inet6.c b/net/ipv6/af_inet6.c
index df31cdd..825d03e 100644
--- a/net/ipv6/af_inet6.c
+++ b/net/ipv6/af_inet6.c
@@ -712,39 +712,6 @@ int ipv6_opt_accepted(struct sock *sk, struct sk_buff *skb)
 
 EXPORT_SYMBOL_GPL(ipv6_opt_accepted);
 
-int
-snmp6_mib_init(void *ptr[2], size_t mibsize, size_t mibalign)
-{
-       if (ptr == NULL)
-               return -EINVAL;
-
-       ptr[0] = __alloc_percpu(mibsize);
-       if (!ptr[0])
-               goto err0;
-
-       ptr[1] = __alloc_percpu(mibsize);
-       if (!ptr[1])
-               goto err1;
-
-       return 0;
-
-err1:
-       free_percpu(ptr[0]);
-       ptr[0] = NULL;
-err0:
-       return -ENOMEM;
-}
-
-void
-snmp6_mib_free(void *ptr[2])
-{
-       if (ptr == NULL)
-               return;
-       free_percpu(ptr[0]);
-       free_percpu(ptr[1]);
-       ptr[0] = ptr[1] = NULL;
-}
-
 static int __init init_ipv6_mibs(void)
 {
        if (snmp6_mib_init((void **)ipv6_statistics, sizeof (struct 
ipstats_mib),
diff --git a/net/ipv6/proc.c b/net/ipv6/proc.c
index 0dc5515..5c3ce1c 100644
--- a/net/ipv6/proc.c
+++ b/net/ipv6/proc.c
@@ -346,4 +346,34 @@ int snmp6_free_dev(struct inet6_dev *idev)
        return 0;
 }
 
+int snmp6_mib_init(void *ptr[2], size_t mibsize, size_t mibalign)
+{
+       if (ptr == NULL)
+               return -EINVAL;
+
+       ptr[0] = __alloc_percpu(mibsize);
+       if (!ptr[0])
+               goto err0;
+
+       ptr[1] = __alloc_percpu(mibsize);
+       if (!ptr[1])
+               goto err1;
+
+       return 0;
+
+err1:
+       free_percpu(ptr[0]);
+       ptr[0] = NULL;
+err0:
+       return -ENOMEM;
+}
+
+void snmp6_mib_free(void *ptr[2])
+{
+       if (ptr == NULL)
+               return;
+       free_percpu(ptr[0]);
+       free_percpu(ptr[1]);
+       ptr[0] = ptr[1] = NULL;
+}
 
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to