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]
Message-Id: <200906300045.n5U0j2To004168@rs49.luxsci.com>
Date:	Mon, 29 Jun 2009 20:42:51 -0400
From:	Ben Kibbey <bjk@...sci.net>
To:	Andrew Morton <akpm@...ux-foundation.org>
Cc:	netdev@...r.kernel.org, bugzilla-daemon@...zilla.kernel.org,
	bugme-daemon@...zilla.kernel.org,
	Stephen Hemminger <shemminger@...tta.com>
Subject: Re: [Bugme-new] [Bug 13589] New: usbnet and /proc/net/dev stats

On Mon, Jun 29, 2009 at 05:23:41PM -0700, Andrew Morton wrote:

All usbnet stats weren't getting updated (ifconfig, was always showing 0).
When applied to 2.6.30 this fixes it. Commit 805aaa29fa was the culprit and
reverting it re-adds usbnet_get_stats() but needed to be modified to add whats
in usbnet_netdev_ops:

--- /tmp/usbnet.c	2009-06-29 20:35:59.000000000 -0400
+++ usbnet.c	2009-06-20 11:40:41.000000000 -0400
@@ -1106,9 +1106,16 @@
 }
 EXPORT_SYMBOL_GPL(usbnet_disconnect);
 
+static struct net_device_stats *usbnet_get_stats (struct net_device *net)
+{
+       struct usbnet   *dev = netdev_priv(net);
+       return &dev->stats;
+}
+
 static const struct net_device_ops usbnet_netdev_ops = {
 	.ndo_open		= usbnet_open,
 	.ndo_stop		= usbnet_stop,
+	.ndo_get_stats		= usbnet_get_stats,
 	.ndo_start_xmit		= usbnet_start_xmit,
 	.ndo_tx_timeout		= usbnet_tx_timeout,
 	.ndo_change_mtu		= usbnet_change_mtu,

-- 
Ben Kibbey (bjk) @ FreeNode/OFTC/Jabber
--
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