Received: by 2002:a25:1506:0:0:0:0:0 with SMTP id 6csp5014926ybv; Mon, 17 Feb 2020 10:25:25 -0800 (PST) X-Google-Smtp-Source: APXvYqx5NSLFWehGJkH1+BNHuiermSfIyfgsRCITreSHDKLFmY8R9mXE7D9NBrYjRrUm3qIHFpPU X-Received: by 2002:a05:6830:99:: with SMTP id a25mr13630886oto.130.1581963925737; Mon, 17 Feb 2020 10:25:25 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1581963925; cv=none; d=google.com; s=arc-20160816; b=hAcksz2oEtAkvVG8iciL7WM88VTd6/iDjSqygi9QYmXXKm2HYdypS8LofHPkI5TfWr DxSxLqVggzqDjj1DVlhTyjnOzntb426X3yx/ymbsb3sFAA8nOnr21PKgJBD7uHKFk0nE A6jVcr4xn4bIiyRcko82leMhETpsxqYhWLE5YKgbt2XX3nUgj0GCqsJWBDNAJBA3DOZI fhEWqc9viqg2OBlHm4pcBn7Y/upKJyu3u++Nkrl9QGEKOuDmGKgDcczlxgf1a6xcUIfg BzMqeQNnayUx/nd7vHeg2oiRpcTL6dIwEfAAb+9jfoeIIUXgrhlMqH7NVPT5zTeQT3Og PhfA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=GWl0M8WqN/DYKYi1yFYqMTRfNNs+X1SMz3gpXCQuEks=; b=e5cRNz56h/eswD/bR1HVczfcJxI3QJ7/ahlDWf76S+XTbwG42qXYq2dfWmL5Ve2KU/ +2c3Cw0WMGAWomr+BGvntNxzS9uk8RucWKDX9xbtYpe/DJAfp6FhoxNCvlvR1EwHHby/ 9RLdbLxHXURJjFKU+yeTHbwDOyu+U/O3IUMG1DK+Gl98ZSgMsYfhmU4qhKEecJZ4o/VK FjxP/1O9OirCnlkIDrOa4cbx88x8yIbsJ+i5DUaO8bY/XuKLUrib6aRwUo9StpVJTR+D XW/YECBkOyEp2g6Fh5XfboKhTy4pYwkyzZu4AZWyTheoF12ftluihagw7fh4Fr1oCHl9 sXIA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b15si693993ots.99.2020.02.17.10.25.13; Mon, 17 Feb 2020 10:25:25 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729719AbgBQSA5 (ORCPT + 99 others); Mon, 17 Feb 2020 13:00:57 -0500 Received: from dispatch1-us1.ppe-hosted.com ([148.163.129.52]:54228 "EHLO dispatch1-us1.ppe-hosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729021AbgBQSA4 (ORCPT ); Mon, 17 Feb 2020 13:00:56 -0500 X-Virus-Scanned: Proofpoint Essentials engine Received: from webmail.solarflare.com (uk.solarflare.com [193.34.186.16]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by mx1-us2.ppe-hosted.com (PPE Hosted ESMTP Server) with ESMTPS id 46ED71C0064; Mon, 17 Feb 2020 18:00:55 +0000 (UTC) Received: from [10.17.20.62] (10.17.20.62) by ukex01.SolarFlarecom.com (10.17.10.4) with Microsoft SMTP Server (TLS) id 15.0.1395.4; Mon, 17 Feb 2020 18:00:51 +0000 Subject: Re: [PATCH 21/30] sfc: Add missing annotation for efx_ef10_try_update_nic_stats_vf() To: Jules Irenge , CC: , Solarflare linux maintainers , Edward Cree , "David S. Miller" , "open list:SFC NETWORK DRIVER" References: <0/30> <20200214204741.94112-1-jbi.octave@gmail.com> <20200214204741.94112-22-jbi.octave@gmail.com> From: Martin Habets Message-ID: <6971228b-4c53-8a1b-da79-2d4d09d74df5@solarflare.com> Date: Mon, 17 Feb 2020 18:00:51 +0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.4.1 MIME-Version: 1.0 In-Reply-To: <20200214204741.94112-22-jbi.octave@gmail.com> Content-Type: text/plain; charset="utf-8" Content-Language: en-US Content-Transfer-Encoding: 7bit X-Originating-IP: [10.17.20.62] X-ClientProxiedBy: ukex01.SolarFlarecom.com (10.17.10.4) To ukex01.SolarFlarecom.com (10.17.10.4) X-TM-AS-Product-Ver: SMEX-12.5.0.1300-8.5.1020-25236.003 X-TM-AS-Result: No-11.404500-8.000000-10 X-TMASE-MatchedRID: VPleTT1nwdSB3CLPGH9KvB3Pziq4eLUf69aS+7/zbj+qvcIF1TcLYGVE KJgtC5DLryC/oblCXPfrxBilORr2+Hl5ZPifj+hJboe6sMfg+k87IFMOvFEK2Ehcmj54ab4UyJN a6DYLgM2XUzspP39qoCexqzGrj/vqYlldA0POS1IaPMGCcVm9DvngX/aL8PCN7m+YaQMNZJYG1W 3alEv3RuLzNWBegCW2RYvisGWbbS+3sNbcHjySQd0H8LFZNFG7bkV4e2xSge74hGXV5kW37qNPs DcOLNvpnnZpAu91WemLrYoDLnc9AjZFEgw6u+Np X-TM-AS-User-Approved-Sender: Yes X-TM-AS-User-Blocked-Sender: No X-TMASE-Result: 10--11.404500-8.000000 X-TMASE-Version: SMEX-12.5.0.1300-8.5.1020-25236.003 X-MDID: 1581962456-9U7MNgMnzMsI Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 14/02/2020 20:47, Jules Irenge wrote: > Sparse reports a warning at efx_ef10_try_update_nic_stats_vf() > > warning: context imbalance in efx_ef10_try_update_nic_stats_vf() > - unexpected unlock > > The root cause is the missing annotation at > efx_ef10_try_update_nic_stats_vf() > Add the missing __must_hold(&efx->stats_lock) annotattion > > Signed-off-by: Jules Irenge Thanks Acked-by: Martin Habets > --- > drivers/net/ethernet/sfc/ef10.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/drivers/net/ethernet/sfc/ef10.c b/drivers/net/ethernet/sfc/ef10.c > index 52113b7529d6..b1102c7e814d 100644 > --- a/drivers/net/ethernet/sfc/ef10.c > +++ b/drivers/net/ethernet/sfc/ef10.c > @@ -1820,6 +1820,7 @@ static size_t efx_ef10_update_stats_pf(struct efx_nic *efx, u64 *full_stats, > } > > static int efx_ef10_try_update_nic_stats_vf(struct efx_nic *efx) > + __must_hold(&efx->stats_lock) > { > MCDI_DECLARE_BUF(inbuf, MC_CMD_MAC_STATS_IN_LEN); > struct efx_ef10_nic_data *nic_data = efx->nic_data; >