Received: by 2002:ab2:6f44:0:b0:1fd:c486:4f03 with SMTP id l4csp63878lqq; Wed, 12 Jun 2024 17:03:38 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCWmuf8gi9jgIfWnQqKPCoqi9cOR7G6Nx274pOVEKdjiUJwlRadG1ef+x+VTr0w0NJqk811ufn9oIy4jGUnihCrdlJOfSinyBXnLtnBjrg== X-Google-Smtp-Source: AGHT+IE6v/qi0K3TewAAriCS0u/yzcRzUVPocui5k0jYnxB4hGSjYeHgUqSuLkNMpfaCFtAmK2Fa X-Received: by 2002:a05:6102:4656:b0:48c:3c3f:3689 with SMTP id ada2fe7eead31-48d91e86866mr3575552137.26.1718237018030; Wed, 12 Jun 2024 17:03:38 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1718237018; cv=pass; d=google.com; s=arc-20160816; b=nZ5E+maoa0bnfxhQZF5VuaqPmM2Cj9FBTzu7A4slaMBuup802KGuVEMlWNCclliSQI kZJtb//MgmgY+UNUVgR22urAqBATdsBjt7vXXLkcyehfhmyYuWGD2AtCPwxmt40iYFPe zr1cfIMht3exZkZLLqFsJTscSPwEzAp6BArTql5FShJDdXPLEsNrKqIhYBegaVQI+RE5 T/08HySKeRkWPJagZ/zgUoYOGYBbTILrmXnjfpvlrJrVpUT7Xe/TtZuaBGwxHrrFiEcu SzogxLd7XfUI4PNYkf0ZoQXDzri54H6hKKzpLsAalyp+DTFm/ZcJy24/lRrB67qCG+WZ 8kUw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :references:message-id:subject:cc:to:from:date:dkim-signature; bh=Ds9aXa2m5Jf7kQQgQ1YvGzPN4tCP3bqE5jXUvgaVKHk=; fh=DAs3Kql+jNwzW5Uu41A36W8On8BBb7MUIkDiM+bDP0E=; b=YTH84/dCs5AJYjmC4P0oawgrEF3WMD+kggY0v0HxAxWLh+5HWIOYPqi7buoqKHPwZ/ z1P/j7+pestsOeFATg7KEHlXJb6RqPhh9FuvoLCsa1aG+QKGI589j2tF0n2egbCJBuxY IwS2unmjjm7N6LbnSawxBtAF22OMK3qDHR3BVKWhiq+6jnVUaUZlIAnfQ1QCl429d7Qz 5dSs2yC5ebqpNTxINi1obCbcYA/bViyEqwdAaK5RVwlnMzd/EbaKMTTEOLlYqf4UwUyX i9+jpUttFh1slwS3VP4nne1ViLeZmERX4jHbg2Y1NbzXCzfMLgOwdjnAFS7YtiY9Qzq/ N66w==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=G0r43pNO; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-212391-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-212391-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id ada2fe7eead31-48da449d2c9si46523137.471.2024.06.12.17.03.37 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 12 Jun 2024 17:03:38 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-212391-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=G0r43pNO; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-212391-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-212391-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org 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 ny.mirrors.kernel.org (Postfix) with ESMTPS id B8FEA1C2187F for ; Thu, 13 Jun 2024 00:03:37 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 35C427E2; Thu, 13 Jun 2024 00:03:31 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="G0r43pNO" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 5186F384; Thu, 13 Jun 2024 00:03:29 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718237010; cv=none; b=H/QN3dDgRF2OILy+7luAyDpxuigCFdUE36CKhiBKevDQp/fmwH+jgescmX1n1rInl/RM3vrgV6f0MY6OpslCVZ4cvfyy9citEaa5CnVHXY23JTVFZJH8tOxg85H/hKTAid0KtPLlBLksfptO3ZOKD5C4tFsmBch4lgys9EYhKUc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718237010; c=relaxed/simple; bh=HoGlSe0N5SWiepAaoNUfiwFL0UGEp7h7dXK2pz4uuM4=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=cuEzXHGKGURehq3+H8AIYbEJu4DRqTg96Eh4T+XMtx79Rq680uKc5L3/LzYrs6LpKmv78Gefw4wozxnFlQ++7X4U3MDDXftliJjJ09ygcQJrAOUpYpije0nEQqB015XCPZHRDxshbL3geQjLu+07JKZg/1XfGFvzxHRga0/7mq0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=G0r43pNO; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 1AB1AC116B1; Thu, 13 Jun 2024 00:03:29 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1718237009; bh=HoGlSe0N5SWiepAaoNUfiwFL0UGEp7h7dXK2pz4uuM4=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=G0r43pNO+/5I4sFv6eAE/XWds5XSaFKgPCcOlWFgPYaHsfHzcQbVZ5Ltlscd7/fZz 4gDObGv9vVerQziiK+vB0Rr/fuDcJCdCDquIsJky7CJpNAmzBvCOkyzWjTGkW1EnJm ebEw5UvEKTaY31aMWzqiLUAaJA/e8Jd1FXXrmCUwlDjeymiCOoHJ0mXIEXMqDKPEet jt+ewaEunHdVmVsI88upFJGkKAs3Yp340SPpgBWaroXxE3GUDinYkXpcS6oygoKENN tU96lXTUyCeI/n3nbUMuymgfaoZDkNCR/1ZOsGu4OzJxODOI9hZdcbOSKMcSMoZosr CSN4DRWoillww== Date: Wed, 12 Jun 2024 17:03:27 -0700 From: Nathan Chancellor To: Uwe =?iso-8859-1?Q?Kleine-K=F6nig?= Cc: Masahiro Yamada , Paul Walmsley , Palmer Dabbelt , Albert Ou , Nicolas Schier , linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, Greg Kroah-Hartman , Tom Lendacky , Dan Williams , Kuppuswamy Sathyanarayanan , "Borislav Petkov (AMD)" Subject: Re: [PATCH] modpost: Enable section warning from *driver to .exit.text Message-ID: <20240613000327.GB1596562@thelio-3990X> References: <20240611205900.2145880-2-u.kleine-koenig@baylibre.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=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20240611205900.2145880-2-u.kleine-koenig@baylibre.com> On Tue, Jun 11, 2024 at 10:59:00PM +0200, Uwe Kleine-K?nig wrote: > There used to be several offenders, but now that for all of them patches > were sent and most of them were applied, enable the warning also for > builds without W=1. > > Signed-off-by: Uwe Kleine-K?nig Seems reasonable to me, this is just a modpost warning, so it should not matter too much if there are a few instances lagging behind for a bit (but it would be good for that to get back on people's radar). Reviewed-by: Nathan Chancellor > --- > Hello, > > as of v6.10-rc2 there are two known offenders: > > - drivers/virt/coco/sev-guest/sev-guest.c > patch submitted in March, available at > https://lore.kernel.org/all/4a81b0e87728a58904283e2d1f18f73abc69c2a1.1711748999.git.u.kleine-koenig@pengutronix.de > > - drivers/parport/parport_amiga.c > fixed in next (commit 73fedc31fed3 ("parport: amiga: Mark driver > struct with __refdata to prevent section mismatch")) > > I tested this patch using allmodconfig builds for arm64, riscv, s390 and > x86_64 which didn't expose further drivers with this problem. > > In my eyes this is good enough to enable the warning for all builds (and > not only with W=1). > > Best regards > Uwe > > scripts/mod/modpost.c | 11 ----------- > 1 file changed, 11 deletions(-) > > diff --git a/scripts/mod/modpost.c b/scripts/mod/modpost.c > index 937294ff164f..30881d94f00e 100644 > --- a/scripts/mod/modpost.c > +++ b/scripts/mod/modpost.c > @@ -965,17 +965,6 @@ static int secref_whitelist(const char *fromsec, const char *fromsym, > match(fromsym, PATTERNS("*_ops", "*_probe", "*_console"))) > return 0; > > - /* > - * symbols in data sections must not refer to .exit.*, but there are > - * quite a few offenders, so hide these unless for W=1 builds until > - * these are fixed. > - */ > - if (!extra_warn && > - match(fromsec, PATTERNS(DATA_SECTIONS)) && > - match(tosec, PATTERNS(ALL_EXIT_SECTIONS)) && > - match(fromsym, PATTERNS("*driver"))) > - return 0; > - > /* Check for pattern 3 */ > if (strstarts(fromsec, ".head.text") && > match(tosec, PATTERNS(ALL_INIT_SECTIONS))) > > base-commit: c3f38fa61af77b49866b006939479069cd451173 > prerequisite-patch-id: 7300dede00db637042647e12d558fe1dd57c20cc > prerequisite-patch-id: 82cfe8597f709f05b9fbbd3e4eca8be35e077e2b > -- > 2.43.0 >