Received: by 2002:a25:1506:0:0:0:0:0 with SMTP id 6csp1944447ybv; Fri, 14 Feb 2020 08:38:48 -0800 (PST) X-Google-Smtp-Source: APXvYqwiwgL8nJvdXaCb6bDvckRdlwT0u+ApMsildrW0HjL5zfkJ25A8ur7N5kgfK4vWu5OC7qhG X-Received: by 2002:aca:b244:: with SMTP id b65mr2560685oif.40.1581698327891; Fri, 14 Feb 2020 08:38:47 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1581698327; cv=none; d=google.com; s=arc-20160816; b=K+y3MS9/9PvZ2/Ic/rwDYTrlHQXFvQu9URHPhcyw0wxi2C3co7+DE6DroVMxHyWMH8 Sk3MEt/hKgSAsaA5f4j1v9c7tC+sysZY7E021qMQZSKb/ZrV3YF2Nd1aWue5abtUdcou 0Kpq5tAXXvFkp+1yDmUb5MPs6stWB+DMDmVQC878meLCrpdh0Z1j12DFKr5q8gqJi/u1 E07G26cV8px692Mz4oOJDKQDXeXg7ugbA43QQrjrZ/aHfjZunrp1qRYToGwoIPTzSlG5 4fFu20AVPEYCUSjhgrFgRhLoOPDwV+7yt41D7c8SMzhxH18EzWc89+ItYJshOzi2tg92 proA== 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:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=DT/RGynQ1OQZcCxF/spLVZ2x+wCNyEFUpbkukIzc0mo=; b=n4Bj5xWTxnJHwmg1OwxNyqS1UilIoKuCORiAaC3zZxv/L95gic5rbXVuWIqTIvz3a6 cZFqZVdAcaOFMWL0DQfHCcD/hEegk9UFzaP/WI7wTMzY7+1ILsNeeKo7Xx9JfZ+cdkCu VMVMsNKJtFBLzdx2/SR3PCO1+Y/QL1mpxdBPIbPAkOMPEpppfUb9pMxcpUlK3j/gz9CO ANw6DZYD7Tl+jldmvv5Sx56vASDswrB8elVHiWDbsu2g0K0sJCqyUobIF5ToYasXfUbZ XPJ5189AUILZ1BiwKHJHYjSs+tKNlEY0UCJIxDktLkPHpZnejSXbm1+Dy82lgqKgNchA QRJA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=zVzljjS6; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e7si3101866otr.183.2020.02.14.08.38.35; Fri, 14 Feb 2020 08:38:47 -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; dkim=pass header.i=@kernel.org header.s=default header.b=zVzljjS6; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2392997AbgBNQXn (ORCPT + 99 others); Fri, 14 Feb 2020 11:23:43 -0500 Received: from mail.kernel.org ([198.145.29.99]:57024 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2393166AbgBNQWB (ORCPT ); Fri, 14 Feb 2020 11:22:01 -0500 Received: from sasha-vm.mshome.net (c-73-47-72-35.hsd1.nh.comcast.net [73.47.72.35]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 2746A246D5; Fri, 14 Feb 2020 16:21:59 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1581697320; bh=6EtQis6mQeE6kHIL6mvjafifQGOLz1qYtzxe86M3JsQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=zVzljjS6l621RlGOj5acSev02W+KCfiyQo1a8jpYk0WiDcQllwUGrmevyxxPKXcQZ 9M2geL2zsoUJhjlFKc24JTWO4tWQoyYleQ9GlgPt25g4FRN0rMGEaQMrq5sZuzcjtz b6rUA5sGFvMMpdKEFOzQbApyp6eTf6Cl2nE651Yw= From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Masahiro Yamada , Vincenzo Frascino , Sasha Levin , linux-kbuild@vger.kernel.org Subject: [PATCH AUTOSEL 4.9 030/141] kconfig: fix broken dependency in randconfig-generated .config Date: Fri, 14 Feb 2020 11:19:30 -0500 Message-Id: <20200214162122.19794-30-sashal@kernel.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200214162122.19794-1-sashal@kernel.org> References: <20200214162122.19794-1-sashal@kernel.org> MIME-Version: 1.0 X-stable: review X-Patchwork-Hint: Ignore Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Masahiro Yamada [ Upstream commit c8fb7d7e48d11520ad24808cfce7afb7b9c9f798 ] Running randconfig on arm64 using KCONFIG_SEED=0x40C5E904 (e.g. on v5.5) produces the .config with CONFIG_EFI=y and CONFIG_CPU_BIG_ENDIAN=y, which does not meet the !CONFIG_CPU_BIG_ENDIAN dependency. This is because the user choice for CONFIG_CPU_LITTLE_ENDIAN vs CONFIG_CPU_BIG_ENDIAN is set by randomize_choice_values() after the value of CONFIG_EFI is calculated. When this happens, the has_changed flag should be set. Currently, it takes the result from the last iteration. It should accumulate all the results of the loop. Fixes: 3b9a19e08960 ("kconfig: loop as long as we changed some symbols in randconfig") Reported-by: Vincenzo Frascino Signed-off-by: Masahiro Yamada Signed-off-by: Sasha Levin --- scripts/kconfig/confdata.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/kconfig/confdata.c b/scripts/kconfig/confdata.c index 27aac273205ba..fa423fcd1a928 100644 --- a/scripts/kconfig/confdata.c +++ b/scripts/kconfig/confdata.c @@ -1238,7 +1238,7 @@ bool conf_set_all_new_symbols(enum conf_def_mode mode) sym_calc_value(csym); if (mode == def_random) - has_changed = randomize_choice_values(csym); + has_changed |= randomize_choice_values(csym); else { set_all_choice_values(csym); has_changed = true; -- 2.20.1