From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Miller Subject: Re: [RFC PATCH] net/mlx5e: Temp software stats variable is not required Date: Sat, 03 Nov 2018 19:36:17 -0700 (PDT) Message-ID: <20181103.193617.810293775666516890.davem@davemloft.net> References: <20181103015422.22978-1-saeedm@mellanox.com> Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: netdev@vger.kernel.org, arnd@arndb.de, akpm@linux-foundation.org, jgg@mellanox.com, eric.dumazet@gmail.com, eranbe@mellanox.com, leonro@mellanox.com To: saeedm@mellanox.com Return-path: Received: from shards.monkeyblade.net ([23.128.96.9]:59950 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726994AbeKDLta (ORCPT ); Sun, 4 Nov 2018 06:49:30 -0500 In-Reply-To: <20181103015422.22978-1-saeedm@mellanox.com> Sender: netdev-owner@vger.kernel.org List-ID: From: Saeed Mahameed Date: Fri, 2 Nov 2018 18:54:22 -0700 > +static void mlx5e_fold_sw_stats(struct mlx5e_priv *priv, struct rtnl_link_stats64 *s) > +{ > + int i; > + > + /* not required ? */ > + memset(s, 0, sizeof(*s)); Why wouldn't this be required? I can see that perhaps you can only zero out the statistics that are used in the ndo_get_stats64() code path, but that's different.