From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-wm2-f12.google.com (mail-wm2-f12.google.com [74.125.225.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 3542C486E62 for ; Fri, 25 Sep 2026 22:19:23 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=74.125.225.140 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1790374765; cv=none; b=kklhaQugA9OaZNTLQyxK02bhFgw588W3qMqs0kDpvu07eRJZzQA5Zifq2ogBD7hI3kE0XtTwUTxm/LMvb/Iw8tj+jegOhkOlyWODi8b6VvgKVafJKVEQPpKLRe3ZfaruH2FH8Vp0x2PMTxUdFVgoPA9cD66JhpgzLyKSqbwbAJI= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1790374765; c=relaxed/simple; bh=152hnQ82QfJ0LW+Dm6mPNkhaiXoMmZUG70QpGAGRnCo=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=pvDdIsRiwHB4nMCC6DFo7psZGXtCPxASOOsAXc8xun3pFmWEWmNqv2LjpFSMIfi2WKbrJZWRNK8oMHNeYHhdv1kHNDO9eJDg/PedRaZ5PpRz6XLWlGoNLjHnkPYY07/loz6YjQ9Lt2224RkotSv6jWsIQqCj3xKMYdzIerErBKM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=Xf4uHEk4; arc=none smtp.client-ip=74.125.225.140 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="Xf4uHEk4" Received: by mail-wm2-f12.google.com with SMTP id 5b1f17b1804b1-49ccff31419so12420825e9.3 for ; Fri, 25 Sep 2026 15:19:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1790374761; x=1790979561; darn=vger.kernel.org; h=content-transfer-encoding:content-type:in-reply-to:from :content-language:references:cc:to:subject:user-agent:mime-version :date:message-id:sender:from:to:cc:subject:date:message-id:reply-to :content-type; bh=wZ13srzmxe7uWv22g+0yXS08pgsXrImaRy4OqvYDzm0=; b=Xf4uHEk4NuRUeWii1BKdAA2xpt/Auoam8PYnvyllKTcG6OipsHyIZG2v60/IN+pLlo PorljFt2s1kvWCH/KaW/HSlgClT1rP/8QCuNBwZn52QGqYZ4Lmqd8zM3xT80x1Iypl+R iJkF/oMxE+4SGlF2twZn8Inm3p6HeJr3uL8y+bctYp3ZscOJMfUoT6Mzq+XoCT0RUim8 9FSjAgKHdErgVqi/FjOs1zY1AdFxXwaLN06VJuy8f025CapQ9BwZuLH8HanK51yEldvB Ut2TWs/NOKdsEoQXcTxUw8q9vdUjRRfi1gcD/BPPiX9AZTRXrXe83IFfZdRidv8Y+Hn6 jObQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1790374761; x=1790979561; h=content-transfer-encoding:content-type:in-reply-to:from :content-language:references:cc:to:subject:user-agent:mime-version :date:message-id:sender:x-gm-gg:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to:content-type; bh=wZ13srzmxe7uWv22g+0yXS08pgsXrImaRy4OqvYDzm0=; b=MzxUiv511d22VVw/SlQG41CTPFjFQcUnjuDyjLgQviemj551TNA8GrajPewhmG86iZ Itijar//spSXeFxVgfNfIps9rrfy2TkyPHVEVRbcObjx0IuP+9mNGcG2UJwCZWWEOXwn wn85R+2X4Lp6gkvxv26aZj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with SMTP id 5b1f17b1804b1-49fe7babaadmr113896275e9.20.1790374760917; Fri, 25 Sep 2026 15:19:20 -0700 (PDT) Received: from ?IPV6:2a02:2149:8bb5:f00:90c3:8a8a:2e7b:7fa0? ([2a02:2149:8bb5:f00:90c3:8a8a:2e7b:7fa0]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-4887a354c47sm10464218f8f.15.2026.09.25.15.19.19 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 25 Sep 2026 15:19:20 -0700 (PDT) Sender: Julian Braha Message-ID: <9f0af6b6-bf78-4f4f-96c1-7e08d574b905@gmail.com> Date: Fri, 25 Sep 2026 23:19:19 +0100 Precedence: bulk X-Mailing-List: linux-kbuild@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH 1/4] kconfig: tests: Reset KCONFIG_WARN_CHANGED_INPUT by default To: Nathan Chancellor , Nicolas Schier Cc: Pengpeng Hou , Ulf Magnusson , Masahiro Yamada , linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org References: <20260917-kconfig-tests-minor-updates-v1-0-286e5c985244@fritz.com> <20260917-kconfig-tests-minor-updates-v1-1-286e5c985244@fritz.com> <179036642082.3653489.376583884931759728.b4-reply@b4> Content-Language: en-US From: Julian Braha In-Reply-To: <179036642082.3653489.376583884931759728.b4-reply@b4> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit On 9/25/26 21:00, Nathan Chancellor wrote: > On 2026-09-24 09:35 +0200, Nicolas Schier wrote: >> On Sat, Sep 19, 2026 at 06:29:39PM +0100, Julian Braha wrote: >>> On 9/17/26 14:38, Nicolas Schier wrote: >>>> Reset KCONFIG_WARN_CHANGED_INPUT by default for all kconfig tests but >>>> those which set it explicitly. >>>> >>>> This fixes the 'warn_changed_input' test on systems with >>>> KCONFIG_WARN_CHANGED_INPUT=1 and ensures a cleaner test environment. >>>> >>>> Fixes: 645323a7f4e5 ("kconfig: add optional warnings for changed input values") >>>> Signed-off-by: Nicolas Schier >>>> --- >>>> scripts/kconfig/tests/conftest.py | 8 ++++++++ >>>> 1 file changed, 8 insertions(+) >>>> >>>> diff --git a/scripts/kconfig/tests/conftest.py b/scripts/kconfig/tests/conftest.py >>>> index 66f95e4ed58c..e92f0cf1421a 100644 >>>> --- a/scripts/kconfig/tests/conftest.py >>>> +++ b/scripts/kconfig/tests/conftest.py >>>> @@ -34,6 +34,9 @@ class Conf: >>>> """ >>>> # the directory of the test being run >>>> self._test_dir = os.path.dirname(str(request.fspath)) >>>> + self.default_env = { >>>> + "KCONFIG_WARN_CHANGED_INPUT": "", >>>> + } >>>> >>>> # runners >>>> def _run_conf(self, mode, dot_config=None, out_file='.config', >>>> @@ -57,6 +60,11 @@ class Conf: >>>> # Override 'srctree' environment to make the test as the top directory >>>> extra_env['srctree'] = self._test_dir >>>> >>>> + # Set default environment variables, if not set by caller >>>> + for var in self.default_env: >>>> + if not var in extra_env: >>>> + extra_env[var] = self.default_env[var] >>> Maybe it makes more sense to have the tests ignore users' env vars if >>> they would cause tests to fail? For example, this recent patch >>> explicitly unsets the KCONFIG_WERROR flag: >>> https://lore.kernel.org/linux-kbuild/4d1eee3a- >>> a5f9-467e-880e-4f2815851b09@gmail.com/T/ >>> #m25be9ad4d5e62956c5f98759398f91a555afb4df >> Good point, but I am not sure, if we really should ignore all of the >> user's environment. Maybe it's better for now, to just reset all >> environment variables that start with KCONFIG_ and KBUILD_ ? > Given these are Kconfig tests, we could probaby just ignore KCONFIG_, I > don't see any instances of KBUILD_ within scripts/kconfig outside of the > Makefile. We could do both anyways and just adapt based on reports > though, I don't really have a strong opinion on that though. Yeah I agree with this, since I would expect only KCONFIG_* to have an effect on the Kconfig tests. And after digging into this, it seems KBUILD_EXTRA_WARN does set KCONFIG_WERROR=1, but as long as we're clearing KCONFIG_WERROR, it won't matter. Kconfig also has the 'CONFIG_' flag, which (if set) would break several tests, but the makefile is already clearing it for the testconfig target anyway. - Julian Braha