From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751763AbdHBCmq (ORCPT ); Tue, 1 Aug 2017 22:42:46 -0400 Received: from mail-pg0-f47.google.com ([74.125.83.47]:35065 "EHLO mail-pg0-f47.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751571AbdHBCmo (ORCPT ); Tue, 1 Aug 2017 22:42:44 -0400 Date: Tue, 1 Aug 2017 19:42:42 -0700 From: Stephen Hemminger To: Florian Fainelli Cc: netdev@vger.kernel.org, Stephen Hemminger , Haiyang Zhang , open list , edumazet@google.com, "open list:Hyper-V CORE AND DRIVERS" , davem@davemloft.net Subject: Re: [PATCH net 6/7] netvsc: Initialize 64-bit stats seqcount Message-ID: <20170801194242.0d79787d@xeon-e3> In-Reply-To: <20170801191113.8754-8-f.fainelli@gmail.com> References: <20170801191113.8754-1-f.fainelli@gmail.com> <20170801191113.8754-8-f.fainelli@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 1 Aug 2017 12:11:12 -0700 Florian Fainelli wrote: > On 32-bit hosts and with CONFIG_DEBUG_LOCK_ALLOC we should be seeing a > lockdep splat indicating this seqcount is not correctly initialized, fix > that. In commit 6c80f3fc2398 ("netvsc: report per-channel stats in > ethtool statistics") netdev_alloc_pcpu_stats() was removed in favor of > open-coding the 64-bits statistics, except that u64_stats_init() was > missed. > > Fixes: 6c80f3fc2398 ("netvsc: report per-channel stats in ethtool statistics") > Signed-off-by: Florian Fainelli > --- > drivers/net/hyperv/netvsc.c | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/drivers/net/hyperv/netvsc.c b/drivers/net/hyperv/netvsc.c > index 0a9167dd72fb..96f90c75d1b7 100644 > --- a/drivers/net/hyperv/netvsc.c > +++ b/drivers/net/hyperv/netvsc.c > @@ -1302,6 +1302,8 @@ int netvsc_device_add(struct hv_device *device, > struct netvsc_channel *nvchan = &net_device->chan_table[i]; > > nvchan->channel = device->channel; > + u64_stats_init(&nvchan->tx_stats.syncp); > + u64_stats_init(&nvchan->rx_stats.syncp); > } > > /* Enable NAPI handler before init callbacks */ Looks good, thanks. 32 bit guests are still supported but rarely tested. Signed-off-by: Stephen Hemminger