Received: by 2002:ab2:7855:0:b0:1f9:5764:f03e with SMTP id m21csp59162lqp; Tue, 21 May 2024 18:29:05 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCUw8emsQi5WNmD9255vEulS2t07JRgQsuNP/bklFD5gHSlb+f1qkTCtSKU35nHVCSOa9rwdNWfyZ54Xfc3zyHgxsIYkgH+7NcxT+sgBfQ== X-Google-Smtp-Source: AGHT+IE6FchpgaOyVRSqlzHCrYshxDt7C1gjySrg+/LBayTDU2ybFSQTDolH9UD0O7Tv6HEVzCI5 X-Received: by 2002:a05:6214:4884:b0:6aa:330c:cd75 with SMTP id 6a1803df08f44-6ab7f35ec5fmr6400956d6.22.1716341345329; Tue, 21 May 2024 18:29:05 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1716341345; cv=pass; d=google.com; s=arc-20160816; b=uL4HfEMJ6iZYNufahfB/k1cITyhXuQLn+W2Gx7MQQL8jM51RaovevLXr6sXqeRBwy/ BhnLdYw2M0+qTMRjbnqSlSh6CxPo6KarAdsPxjVfZK3kuKBk/hc/Q3RQvDLgPfiCEfmW orAMJD6SjQRrJtJ1nJr9XOhrxQa027T/0AfrA4CVAydrpLNnGZjdTgmwUWGUaD47R7/4 nMYFHNQWuz2uePenXWE54mEFYG/5cSh+ZQAyz/rh6pe7FsuYzzqALpRwfMuEDDswbYlT MDQjZnOHsJgXiknIrc1s9Z8I5SE5i7xDQ5RLYoDXVM+wbeAI9/2ftptyyqCRKXtFUi42 AK1Q== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date; bh=ra7NTk68rZeD/ZS1/3goZ++QWAhK/jyE9/5sV7Oft64=; fh=ZebQr2oKt5sTSUbotXxLirnSYaveqUmyybxsL+8aqZo=; b=w3kfZDim2U6F3vBeHOvkFA4rvTEc28RjTurGdp++Zh+OvBUvWet2yfRxR7CGmGc+u+ ohWD7GVz0G7fWXli2W8DkVvBeOYq1Ip7MlAjg4HdWBUv3jTVqb3Z1ycCrpMqIy6JvgAb hkf8h/cICzRrVZ0SfVztF2wI6tKx1xlwLcbJXa/lwvcm+B9J/92SNTDpNPCf2XsvcEdW +EQuuOxk5H/xCmApUHu2fTK+ZoPATezine6AHtQ1I5E8YIkkywM+ny/AlrU/5CUMHRy8 pB6XtUFIWSk9xRM7gHc1h3uyknSgwSTD8AZGR2/3tVMIMTKVjUYlecty7EDppjxAGIp0 mpdA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=altlinux.org); spf=pass (google.com: domain of linux-kernel+bounces-185651-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-185651-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id 6a1803df08f44-6aa14cc7d9csi70571836d6.381.2024.05.21.18.29.05 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 21 May 2024 18:29:05 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-185651-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=altlinux.org); spf=pass (google.com: domain of linux-kernel+bounces-185651-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-185651-linux.lists.archive=gmail.com@vger.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 001E31C20C39 for ; Wed, 22 May 2024 01:29:05 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id AFCA92942F; Wed, 22 May 2024 01:19:10 +0000 (UTC) Received: from vmicros1.altlinux.org (vmicros1.altlinux.org [194.107.17.57]) by smtp.subspace.kernel.org (Postfix) with ESMTP id A7565224CF; Wed, 22 May 2024 01:19:07 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=194.107.17.57 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716340750; cv=none; b=KVzrFcZZWsmM+YeH/p0xBs6R2oa/EhRp/K3C4pgXiFcOLpmzvgVUnGnaUCnq88U93lp3xbH6eOHOrgSm6g0lKuV2DzsZBbgN0LAaLpkGMSEc4djaeaLFIF0LTxHz6xsv1Unzq4bTQ/wEcOe16UdZOUDpdl/COql3srwWuyzyzg0= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716340750; c=relaxed/simple; bh=weadA3+mmgcWotP/FdF0QwQETssaX/ZYIE9jI5omFJQ=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=F2HDFXgoeXSeKoaWKoO9PYY3W4Xrkmw2vhYGC3s9fQEVXgpQWeFgbPJ6zZWsAkYoQ8JbyZbN57ul3QEUtI78x1EODSP+Imz0Urw6N66eUYUwOfCYgEVW7MrYK/7m6/EM5nxDc1sZfthiTiZ7Cknd/MF6duzd3v0y6TGg4bxBxnI= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=altlinux.org; spf=pass smtp.mailfrom=altlinux.org; arc=none smtp.client-ip=194.107.17.57 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=altlinux.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=altlinux.org Received: from imap.altlinux.org (imap.altlinux.org [194.107.17.38]) by vmicros1.altlinux.org (Postfix) with ESMTP id 3D4EC72C8F5; Wed, 22 May 2024 04:10:31 +0300 (MSK) Received: from altlinux.org (sole.flsd.net [185.75.180.6]) by imap.altlinux.org (Postfix) with ESMTPSA id 2249B36D0168; Wed, 22 May 2024 04:10:31 +0300 (MSK) Date: Wed, 22 May 2024 04:10:31 +0300 From: Vitaly Chikunov To: Edward Liaw , Mark Brown Cc: shuah@kernel.org, =?utf-8?Q?Micka=C3=ABl_Sala=C3=BCn?= , =?utf-8?Q?G=C3=BCnther?= Noack , Christian Brauner , Richard Cochran , Paul Walmsley , Palmer Dabbelt , Albert Ou , Alexei Starovoitov , Daniel Borkmann , "David S. Miller" , Jakub Kicinski , Jesper Dangaard Brouer , John Fastabend , Kees Cook , Andy Lutomirski , Will Drewry , linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org, kernel-team@android.com, linux-security-module@vger.kernel.org, netdev@vger.kernel.org, linux-riscv@lists.infradead.org, bpf@vger.kernel.org Subject: Re: [PATCH v5 02/68] kselftest: Desecalate reporting of missing _GNU_SOURCE Message-ID: <20240522011031.nps5dejrgk5b442y@altlinux.org> References: <20240522005913.3540131-1-edliaw@google.com> <20240522005913.3540131-3-edliaw@google.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=koi8-r Content-Disposition: inline In-Reply-To: <20240522005913.3540131-3-edliaw@google.com> On Wed, May 22, 2024 at 12:56:48AM +0000, Edward Liaw wrote: > From: Mark Brown > > Commit daef47b89efd0b7 ("selftests: Compile kselftest headers with > -D_GNU_SOURCE") adds a static_assert() which means that things which > would be warnings about undeclared functions get escalated into build > failures. While we do actually want _GNU_SOURCE to be defined for users > of kselftest_harness we haven't actually done that yet and this is > causing widespread build breaks which were previously warnings about > uses of asprintf() without prototypes, including causing other test > programs in the same directory to fail to build. > > Since the build failures that are introduced cause additional issues due > to make stopping builds early replace the static_assert() with a > missing without making the error more severe than it already was. This > will be moot once the issue is fixed properly but reduces the disruption > while that happens. > > Signed-off-by: Mark Brown > Reviewed-by: Kees Cook > --- > tools/testing/selftests/kselftest_harness.h | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/tools/testing/selftests/kselftest_harness.h b/tools/testing/selftests/kselftest_harness.h > index b634969cbb6f..8e53686b71cb 100644 > --- a/tools/testing/selftests/kselftest_harness.h > +++ b/tools/testing/selftests/kselftest_harness.h > @@ -51,7 +51,7 @@ > #define __KSELFTEST_HARNESS_H > > #ifndef _GNU_SOURCE > -#define _GNU_SOURCE > +#warning kselftest harness requires _GNU_SOURCE to be defined Maybe this should be `#error` if it really requires? Thanks, > #endif > #include > #include > -- > 2.45.1.288.g0e0cd299f1-goog >