From mboxrd@z Thu Jan 1 00:00:00 1970 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 1D8422236F3; Mon, 2 Jun 2025 14:04:46 +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=1748873086; cv=none; b=LsExMy0dWkauM1eVmGBgI5MiJ0q5jZT2CE7O1EuHjQEpsZHa8Jlqz8BXTgqbkL+1uUyBvl59Q+1eyaXbCxHrUfdVM0DQ+iABXW0tUm9JZBq3AM3DpsD8EC+aCmiOKHGnCeTUQpsK7JEEpxS+Z+X5nyZFx/0BkCNTJvDLGSN0kZM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1748873086; c=relaxed/simple; bh=gyIIUbwfr2MpV9AC1aPnD4Ba3esYa2J6SyBhuVxpqFo=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=Kdk0tOsGjquMlst+A6YjlJ351rWaxtFXb6oJsvI1B3PRMz8MFEMSRSpXecmNThkYr5pxMKeotT7x8r/lZhosG3P6ODbEmJ/cFhf1sIPVVYhXOwWpbR3iTlb9V43wQmPH6ryqe8QDF9Et7L3UiyX9A5gDndxpcBV8bQ13worrXX8= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=GuG51j/1; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="GuG51j/1" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 80D1AC4CEEB; Mon, 2 Jun 2025 14:04:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1748873086; bh=gyIIUbwfr2MpV9AC1aPnD4Ba3esYa2J6SyBhuVxpqFo=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=GuG51j/1D2sEdmGtCbWKlwUBf1i+d2k8o4ZRW+1uKD678wiKrh4U2j2rfTnzlDsxU Iww6JdaH7dtAdcZPd7/k6skgT77D+toXoreqLPE1O3kKHglMSnmqaUNAfHdmTfLZPY xSLqh8VeYJgixDhiV6BPy/re1pauBcVhtVKvqjVQ= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Daniel Gomez , Masahiro Yamada , Sasha Levin Subject: [PATCH 6.6 033/444] kconfig: merge_config: use an empty file as initfile Date: Mon, 2 Jun 2025 15:41:37 +0200 Message-ID: <20250602134342.257154692@linuxfoundation.org> X-Mailer: git-send-email 2.49.0 In-Reply-To: <20250602134340.906731340@linuxfoundation.org> References: <20250602134340.906731340@linuxfoundation.org> User-Agent: quilt/0.68 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: stable@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 6.6-stable review patch. If anyone has any objections, please let me know. ------------------ From: Daniel Gomez [ Upstream commit a26fe287eed112b4e21e854f173c8918a6a8596d ] The scripts/kconfig/merge_config.sh script requires an existing $INITFILE (or the $1 argument) as a base file for merging Kconfig fragments. However, an empty $INITFILE can serve as an initial starting point, later referenced by the KCONFIG_ALLCONFIG Makefile variable if -m is not used. This variable can point to any configuration file containing preset config symbols (the merged output) as stated in Documentation/kbuild/kconfig.rst. When -m is used $INITFILE will contain just the merge output requiring the user to run make (i.e. KCONFIG_ALLCONFIG=<$INITFILE> make or make olddefconfig). Instead of failing when `$INITFILE` is missing, create an empty file and use it as the starting point for merges. Signed-off-by: Daniel Gomez Signed-off-by: Masahiro Yamada Signed-off-by: Sasha Levin --- scripts/kconfig/merge_config.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/kconfig/merge_config.sh b/scripts/kconfig/merge_config.sh index 0b7952471c18f..79c09b378be81 100755 --- a/scripts/kconfig/merge_config.sh +++ b/scripts/kconfig/merge_config.sh @@ -112,8 +112,8 @@ INITFILE=$1 shift; if [ ! -r "$INITFILE" ]; then - echo "The base file '$INITFILE' does not exist. Exit." >&2 - exit 1 + echo "The base file '$INITFILE' does not exist. Creating one..." >&2 + touch "$INITFILE" fi MERGE_LIST=$* -- 2.39.5