From: Lennert Buytenhek Date: Wed, 23 Nov 2005 11:49:10 +0000 (+0100) Subject: [PATCH] pm3386: zero stats properly X-Git-Tag: v2.6.16-rc1~474^2~22^2~7^2~64 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=178f171da7f0ea5cfc1c45932680c81b3a8a0bd6;p=linux-2.6 [PATCH] pm3386: zero stats properly Zero our stats structure properly. Signed-off-by: Lennert Buytenhek Signed-off-by: Jeff Garzik --- diff --git a/drivers/net/ixp2000/pm3386.c b/drivers/net/ixp2000/pm3386.c index cf0681fb12..df960f1710 100644 --- a/drivers/net/ixp2000/pm3386.c +++ b/drivers/net/ixp2000/pm3386.c @@ -238,7 +238,7 @@ void pm3386_get_stats(int port, struct net_device_stats *stats) while (pm3386_port_reg_read(port, 0x500, 0x100) & 0x0001) ; - memset(stats, 0, sizeof(stats)); + memset(stats, 0, sizeof(*stats)); stats->rx_packets = pm3386_get_stat(port, 0x510); stats->tx_packets = pm3386_get_stat(port, 0x590);