lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Thu, 19 Apr 2007 21:04:54 +0900 (JST)
From:	YOSHIFUJI Hideaki / 吉藤英明 
	<yoshfuji@...ux-ipv6.org>
To:	tgraf@...g.ch, davem@...emloft.net
Cc:	davem@...emloft.net, netdev@...r.kernel.org
Subject: Re: [GIT PATCH] Exporting IPv6 statistics via netlink.

In article <20070419.175855.130993987.yoshfuji@...ux-ipv6.org> (at Thu, 19 Apr 2007 17:58:55 +0900 (JST)), YOSHIFUJI Hideaki / 吉藤英明 <yoshfuji@...ux-ipv6.org> says:

> In article <20070419084412.GD521@...tel.suug.ch> (at Thu, 19 Apr 2007 10:44:12 +0200), Thomas Graf <tgraf@...g.ch> says:
> 
> > * YOSHIFUJI Hideaki <yoshfuji@...ux-ipv6.org> 2007-04-19 15:42
> > > 
> > > Please consider pulling following changesets for supporting exporting
> > > stats information via netlink, on top of net-2.6.22.
> > 
> > The netlink bits are perfectly fine, why the dependency on proc fs?
> 
> I'll follow up to eliminate such dependency afterwards.

Here it is.

All changesets are available on the
    net-2.6.22-20070417-stats-20070419
branch at
    <git://git.linux-ipv6.org/gitroot/yoshfuji/linux-2.6-dev.git>.

---
[IPV6] SNMP: Export statistics via netlink without CONFIG_PROC_FS.

Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@...ux-ipv6.org>
---
 net/ipv6/proc.c |   10 ++++------
 1 files changed, 4 insertions(+), 6 deletions(-)

diff --git a/net/ipv6/proc.c b/net/ipv6/proc.c
index 5c3ce1c..c847cef 100644
--- a/net/ipv6/proc.c
+++ b/net/ipv6/proc.c
@@ -141,6 +141,7 @@ static struct snmp_mib snmp6_udplite6_list[] = {
 	SNMP_MIB_ITEM("UdpLite6OutDatagrams", UDP_MIB_OUTDATAGRAMS),
 	SNMP_MIB_SENTINEL
 };
+#endif	/* CONFIG_PROC_FS */
 
 static unsigned long
 fold_field(void *mib[], int offt)
@@ -155,6 +156,7 @@ fold_field(void *mib[], int offt)
 	return res;
 }
 
+#ifdef CONFIG_PROC_FS
 static inline void
 snmp6_seq_show_item(struct seq_file *seq, void **mib, struct snmp_mib *itemlist)
 {
@@ -206,6 +208,7 @@ static const struct file_operations snmp6_seq_fops = {
 	.llseek	 = seq_lseek,
 	.release = single_release,
 };
+#endif	/* CONFIG_PROC_FS */
 
 static inline void
 __snmp6_fill_stats(u64 *stats, void **mib, int items, int bytes)
@@ -232,6 +235,7 @@ snmp6_fill_stats(u64 *stats, struct inet6_dev *idev, int attrtype, int bytes)
 	}
 }
 
+#ifdef CONFIG_PROC_FS
 int snmp6_register_dev(struct inet6_dev *idev)
 {
 	struct proc_dir_entry *p;
@@ -309,12 +313,6 @@ int snmp6_unregister_dev(struct inet6_dev *idev)
 	return 0;
 }
 
-void
-snmp6_fill_stats(u64 *stats, struct inet6_dev *idev, int attrtype, int bytes)
-{
-	memset(stats, 0, sizeof(bytes));
-}
-
 #endif	/* CONFIG_PROC_FS */
 
 int snmp6_alloc_dev(struct inet6_dev *idev)
-- 
1.5.1

-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ