Received: by 2002:ab2:6991:0:b0:1f7:f6c3:9cb1 with SMTP id v17csp344959lqo; Wed, 8 May 2024 01:12:29 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVE1giz1y8HedrAtOCKtVLSjhToEAQ7nhb80BmyYCdXX87Zsa7MnQ8k5YLEkx1g8fCPmg7McxHBcyUOLIwC8bUlygQ47elwr2Jpq8pnag== X-Google-Smtp-Source: AGHT+IFqTF0mU6VKDDSDDOrSFg0ShdDFyrM4r5nKh2+xFJxpu19BQX8iIpQkyCVhtZi1Yb6xLiSm X-Received: by 2002:a17:906:190c:b0:a59:f2d2:49b1 with SMTP id a640c23a62f3a-a59fa885b9fmr162577366b.9.1715155949090; Wed, 08 May 2024 01:12:29 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1715155949; cv=pass; d=google.com; s=arc-20160816; b=t/91jI9qTS/0p7gCwIa4W8El8MHctltbGhEJNVTKK43hlaqYSHVbOc0qIXf7E/vKYH Lh5s6/gW7q3ldmcy1y9XFnyCiq8nf3nu9L7jHSn6t77NrbjL2SzGWDALrrkUJ5gMVj/j Pn4QOWzo9a9mCFV9egksSh6t6/b/9KMy+Cj6+PEe8O18YDvzNACktAyfx67aLyNiluKs B0ok2C1YcKXDfjUZ95VDzX6JjsZgmIKxGhSZGmxShki+kR0D7iKCfuBjPWpw3zCzyDFY /+VnsTwagARQHP3C8Wu11sikMoPeZSyc1cVYuFYCnzEQIuAPHHkeqebV4Rld85EK8vIx u9oQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:in-reply-to:content-disposition:mime-version :list-unsubscribe:list-subscribe:list-id:precedence:references :message-id:subject:cc:to:from:date:dkim-signature; bh=uRqGn1bN/Grcd+F1z4WjSaR1kcVdDX8dLEQa2ZSJ9Jc=; fh=hNlJNLBW4RQQJ1XYGaeCyv5xa6VoPqYa9NI8X3jNhLg=; b=Z3HEf+xpbLQvkYivfEruzrn5bEGNswYjKowtO2NYa/3FM8O4/6B9lTXgbjyxkYe7E6 spxg0ldqqETL6rdCE3NVh7GxwiPAK0XE6Q9LcK9fT4f9pojg/3MkuTgn/tyoTCVwe33r m0PrBwG9h1RaT2kNKTxyTtMv25/g6iq/J3IKRITbrW73x+k3mlVL5gB+vb0kIMvNEO7v YbTP/ew1GmnV0dCfg+d/njqIZLQEd378QpT+6imcsTMC79z5dkYZl/BUsg8pxZ5nbCJs +ddmtSOGujqIkqkfgaSW2z8fo+GbN5nAj9lxRMGwvn89UzFLe8C/ckuV0YbL+AKoxC7c EYuA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=fail (test mode) header.i=@armlinux.org.uk header.s=pandora-2019 header.b=ZjFtKFxa; arc=pass (i=1 dkim=pass dkdomain=armlinux.org.uk dmarc=pass fromdomain=armlinux.org.uk); spf=pass (google.com: domain of linux-kernel+bounces-172890-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-172890-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=armlinux.org.uk Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [2604:1380:4601:e00::3]) by mx.google.com with ESMTPS id ga39-20020a1709070c2700b00a59d66cca06si2823165ejc.326.2024.05.08.01.12.29 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 08 May 2024 01:12:29 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-172890-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) client-ip=2604:1380:4601:e00::3; Authentication-Results: mx.google.com; dkim=fail (test mode) header.i=@armlinux.org.uk header.s=pandora-2019 header.b=ZjFtKFxa; arc=pass (i=1 dkim=pass dkdomain=armlinux.org.uk dmarc=pass fromdomain=armlinux.org.uk); spf=pass (google.com: domain of linux-kernel+bounces-172890-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-172890-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=armlinux.org.uk Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id BB5031F23717 for ; Wed, 8 May 2024 08:12:15 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 43D8541748; Wed, 8 May 2024 08:12:06 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=armlinux.org.uk header.i=@armlinux.org.uk header.b="ZjFtKFxa" Received: from pandora.armlinux.org.uk (pandora.armlinux.org.uk [78.32.30.218]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 68ED13DB97; Wed, 8 May 2024 08:12:03 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=78.32.30.218 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715155925; cv=none; b=bMy5fFz8K7vAM8HAp/dBeSEXN9XV8GvjhF03uW0pJnthrNZ8CxF7As3q/UfzXcde38jFM/YRZINTRg33A+uNEXQ3YOt1ZcPtwJgu7VTYpo/HHOzVxoOBHDlY3GLJK/+rH+0q4OkNv8azq+xYeRfcqtxFRxWcXP5hqph7RpvzoCc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715155925; c=relaxed/simple; bh=edbSgAp6x5wdS7hhDjQhYQQt1mmbXqGyMLbuEgoFHL8=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=TfVaKkFWw2OQV3jyJz+bzgWmxsBTU3GxNBuTgg9cH2q18Nld6uzezIaf3q0cxswBPmWRxiSOHbIykFl2uvzy8xjisLKu74/MkAru6ijK5oJdzZ84z4RH/L5vxbkxywX82CNIgcRioxe7gngA/MHX27OGgrp1wcBSt1efzux3xO4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=armlinux.org.uk; spf=none smtp.mailfrom=armlinux.org.uk; dkim=pass (2048-bit key) header.d=armlinux.org.uk header.i=@armlinux.org.uk header.b=ZjFtKFxa; arc=none smtp.client-ip=78.32.30.218 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=armlinux.org.uk Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=armlinux.org.uk DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=armlinux.org.uk; s=pandora-2019; h=Sender:In-Reply-To:Content-Type: MIME-Version:References:Message-ID:Subject:Cc:To:From:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=uRqGn1bN/Grcd+F1z4WjSaR1kcVdDX8dLEQa2ZSJ9Jc=; b=ZjFtKFxa9wt8DrsHiQAJ0YTvlM CB3WxxTkZNQCVro9WRZ3AEWSOU1tKi8PhFSERTQ73pDPXW/I9XhUaicOOayOCFoSYgK/QCe/tuv9w PRp/MygDqsMqZkkY3fVuuCy/rVGGs+WjzUNF43KT5omOMrRmU3RHjBoXWMDHrWGPxhdoad6LaLjla GQ+4yXoKFwjgTrhmgL4KlZqsoh5p7V63p/58qP3TMKYzBkeQJvRwQI1BlItx67TqMv9dMWYRMVSuT uLvFXof9NpGd/2X1bxvRVRFMhXKDHRaB4bhZnn1/I7lwanff5BGu7QOSiAV6ymZkMDv3N1+PCt3Ui 09/I+DDg==; Received: from shell.armlinux.org.uk ([fd8f:7570:feb6:1:5054:ff:fe00:4ec]:55036) by pandora.armlinux.org.uk with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1s4cOr-0004so-17; Wed, 08 May 2024 09:11:41 +0100 Received: from linux by shell.armlinux.org.uk with local (Exim 4.94.2) (envelope-from ) id 1s4cOn-0001EY-HV; Wed, 08 May 2024 09:11:37 +0100 Date: Wed, 8 May 2024 09:11:37 +0100 From: "Russell King (Oracle)" To: Xiaolei Wang Cc: alexandre.torgue@foss.st.com, joabreu@synopsys.com, davem@davemloft.net, edumazet@google.com, kuba@kernel.org, pabeni@redhat.com, mcoquelin.stm32@gmail.com, richardcochran@gmail.com, bartosz.golaszewski@linaro.org, horms@kernel.org, ahalaney@redhat.com, rohan.g.thomas@intel.com, j.zink@pengutronix.de, leong.ching.swee@intel.com, netdev@vger.kernel.org, linux-stm32@st-md-mailman.stormreply.com, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v3] net: stmmac: move the lock to struct plat_stmmacenet_data Message-ID: References: <20240508045257.2470698-1-xiaolei.wang@windriver.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20240508045257.2470698-1-xiaolei.wang@windriver.com> Sender: Russell King (Oracle) On Wed, May 08, 2024 at 12:52:57PM +0800, Xiaolei Wang wrote: > Reinitialize the whole est structure would also reset the mutex lock > which is embedded in the est structure, and then trigger the following > warning. To address this, move the lock to struct plat_stmmacenet_data. > We also need to require the mutex lock when doing this initialization. What is plat->lock protecting exactly? "lock" is opaque and doesn't hint at its purpose. Does it serialise accesses to plat->est? If so, consider naming it plat->est_lock to make its purpose and what it's doing clear. Please also follow netdev best practice; allow at least 24 hours to pass _and_ for discussion to finish before posting a new version of a patch or patch series. Also see the "How do I indicate which tree" question at: https://www.kernel.org/doc/html/v5.3/networking/netdev-FAQ.html Thanks. -- RMK's Patch system: https://www.armlinux.org.uk/developer/patches/ FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last!