From patchwork Mon Aug 12 11:49:45 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Masahiro Yamada X-Patchwork-Id: 13760446 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 3CCC0178372; Mon, 12 Aug 2024 11:50:28 +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=1723463429; cv=none; b=cFZlwWinV/TyxX5wvj3REJdbVylqwGqhlhP/N9+pvZvKnVeejPBLGfJDgiVut0Fger5Yh7BP8Eh9BQv3aD0qtK3Ce/lLJ071a0InKw4lPR4gcxjBwUTfwtrPlVcg/OtqRPfyampmU3HFvAWudXX9GbEpvWpGTJpRKOWw6Yoxvhc= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1723463429; c=relaxed/simple; bh=OQWIwP9PhXAySimWeo7mKueNK2l0AjWu9fXY62Xe7kE=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=DnsWN9zGPWU3pXBz6M2hYVuBJyXCIz3vtWKITZ+i36dtDH3reL1iuV3ltoZSPcu3L6EiViyXaRKQli/9UTH4Gob+afx3X5i8lI6YT6UcqApXYurEZx0BLjMN+zejwmW3XNz+toLbLT4/cNid1CXamivVFeDnfjufF+iGS6E17iI= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=rGnbADwP; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="rGnbADwP" Received: by smtp.kernel.org (Postfix) with ESMTPSA id C0E11C32782; Mon, 12 Aug 2024 11:50:27 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1723463428; bh=OQWIwP9PhXAySimWeo7mKueNK2l0AjWu9fXY62Xe7kE=; h=From:To:Cc:Subject:Date:From; b=rGnbADwPUkeV3UN3bFXFF3s8qVL/upNiwAH42lmSrKKoF1z1lP0DxYvUbYvfMaOM+ ik53hQtCgfOfNmLOVoZeL+QuaD19tr3WCYFghs8YUTi8hGSWNRBb2+8p6xMHU+RPfu xR15eUXU0MWVpR2ChaHBSl89sGfwDc9eRugnaZLysoCuO5fbn9b1FdDI14pR6Q7RFW MpoaCTn/7uIqM00n3bmTOD3Nvro0yrioj41iALes7difeIQbJWdf5Z23TPs0XQ9WQq KQEqJQQ0cFoAbblmgOQewMYTMLGWNykdROzuIbgxU2USwEPSI2wU1weu+cIWxHq2RA MqT5RSozOwwaw== From: Masahiro Yamada To: linux-kbuild@vger.kernel.org Cc: linux-kernel@vger.kernel.org, Masahiro Yamada Subject: [PATCH 1/3] kconfig: remove dummy assignments to cur_{filename,lineno} Date: Mon, 12 Aug 2024 20:49:45 +0900 Message-ID: <20240812115023.2101419-1-masahiroy@kernel.org> X-Mailer: git-send-email 2.43.0 Precedence: bulk X-Mailing-List: linux-kbuild@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Since commit ca4c74ba306e ("kconfig: remove P_CHOICE property"), menu_finalize() no longer calls menu_add_symbol(). No function references cur_filename or cur_lineno after yyparse(). Signed-off-by: Masahiro Yamada --- scripts/kconfig/parser.y | 8 -------- 1 file changed, 8 deletions(-) diff --git a/scripts/kconfig/parser.y b/scripts/kconfig/parser.y index 61900feb4254..e03731184840 100644 --- a/scripts/kconfig/parser.y +++ b/scripts/kconfig/parser.y @@ -530,14 +530,6 @@ void conf_parse(const char *name) yydebug = 1; yyparse(); - /* - * FIXME: - * cur_filename and cur_lineno are used even after yyparse(); - * menu_finalize() calls menu_add_symbol(). This should be fixed. - */ - cur_filename = ""; - cur_lineno = 0; - str_printf(&autoconf_cmd, "\n" "$(autoconfig): $(deps_config)\n" From patchwork Mon Aug 12 11:49:46 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Masahiro Yamada X-Patchwork-Id: 13760447 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 707B3178390; Mon, 12 Aug 2024 11:50:30 +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=1723463430; cv=none; b=Y+yMFmIdwRmUrXUGjiYc+3mca3wiYQuefTbfxttKHmNr+GeZGM7sdVSo4KI0v67N0Nslcr4RHMWje7MnIcZ027IP9gbynscaDx09ZezDU0iZBF7YQ0GBa65EO4CNYzd1jaULnRtAS1Feuijq4VegShQOHi+1SQpLj/eQ8z6onis= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1723463430; c=relaxed/simple; bh=RXcm9Tb/RcqZCEXXLBNnFJzdCQM/VqleiEoUH+5CbV0=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=IMa2IT+CW8oUER1krHl0dfEtzDfNpFUefdblocrYvjWgwDcbbgq2M2SaWysKi/0x69f4Vf8itvufxX83Ylz1fxhVLTlL9jHY5M28VTk6xfijUNHGBPt98PsWOEvcvuXaht91yJiLfTGj0FxOrwcyLut3dbYrvjAGYw/Iheqmzic= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=mkSZEe6d; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="mkSZEe6d" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 19BCAC4AF0E; Mon, 12 Aug 2024 11:50:28 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1723463429; bh=RXcm9Tb/RcqZCEXXLBNnFJzdCQM/VqleiEoUH+5CbV0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=mkSZEe6dG0WSZS93EGYV3xF/cobdcSLIqb5mkROFKbmLGYeDXxY/2xEnWFQcaTT+N tC6DHok6PQmU5+ohQxKCEHzXjcecfP0mDSlpvus6YarQJi++Mv86qBCkogxT6Dkpko DM4CcTfh0Bn/KEOQYFlhxpEucsyd0iKugjX849T0WGG/qAXZQhQutwmm/Jakm4bJo6 bD6bYjtPuIQHocr2Hed1qQITSi4Tdw2i86N+2KebrfZTZ1dqm+dMbIWE++IouN8gZ/ TrkMOxexOKvYNT00d5IIzcz50b9O0v+gbw4y6Q2qINuwwgf3ZKLaoQTuC7bHL4URyH HlaIzAgSlDV0Q== From: Masahiro Yamada To: linux-kbuild@vger.kernel.org Cc: linux-kernel@vger.kernel.org, Masahiro Yamada Subject: [PATCH 2/3] kconfig: stop adding P_SYMBOL property to symbols Date: Mon, 12 Aug 2024 20:49:46 +0900 Message-ID: <20240812115023.2101419-2-masahiroy@kernel.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240812115023.2101419-1-masahiroy@kernel.org> References: <20240812115023.2101419-1-masahiroy@kernel.org> Precedence: bulk X-Mailing-List: linux-kbuild@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 I believe its last usage was in the following code: if (prop == NULL) prop = stack->sym->prop; This code was previously used to print the file name and line number of associated symbols in sym_check_print_recursive(), which was removed by commit 9d0d26604657 ("kconfig: recursive checks drop file/lineno"). Signed-off-by: Masahiro Yamada --- scripts/kconfig/menu.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/scripts/kconfig/menu.c b/scripts/kconfig/menu.c index 323cc0b62be6..854edeb4d2db 100644 --- a/scripts/kconfig/menu.c +++ b/scripts/kconfig/menu.c @@ -78,10 +78,8 @@ void menu_add_entry(struct symbol *sym) *last_entry_ptr = menu; last_entry_ptr = &menu->next; current_entry = menu; - if (sym) { - menu_add_symbol(P_SYMBOL, sym, NULL); + if (sym) list_add_tail(&menu->link, &sym->menus); - } } struct menu *menu_add_menu(void) From patchwork Mon Aug 12 11:49:47 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Masahiro Yamada X-Patchwork-Id: 13760448 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 80C1B17997D; Mon, 12 Aug 2024 11:50:31 +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=1723463432; cv=none; b=U0pDEvJLmt0hbLcwqYofRLctMVkE5BLJVsT7XmjAZRoI9I671zsAkyvj9JDIGtT2qd4Z2MXlzpiljA/G+lij71rPTFvUI8Qu1pACQY2FES/EXIrywk3YErhu1KYOY4Z99N5jeVCLEjzEOr9ll8GSS52lbw8YQT3LrWFi8IKnBDI= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1723463432; c=relaxed/simple; bh=y4ibPbOlrqYtjnVi728m8zHasovW5Iqx52iFRyKrULk=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=aT58IW5D/ECgCrXZ7B25+ivPY2WTN0xWKpWK0ULdHFmFlXJesTDLMuSZj7hzmWNr3N8d9MKfynP08o5Gt57RWvscPagfBeGY1iBSMjDqQ2QL2f/bBFegDkX3dYVnimV8VXUPGjQyx7eIQVj7n9G+6u3FbOFSgtR8td+PliVeq4k= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=MzLml+b5; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="MzLml+b5" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 6DFCEC4AF15; Mon, 12 Aug 2024 11:50:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1723463431; bh=y4ibPbOlrqYtjnVi728m8zHasovW5Iqx52iFRyKrULk=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=MzLml+b5V9EqV6tYF43XPG6ZXHAiOvHJNcXyZqjwTBg2cAc5pygLlL682pmCbv7Iy b5itAE4cVTwEKlS6M6GQU1hREKTtxI2bHbwgmgWNW2o8IfHnTzWlpSkyXlJDq7zWfn XuY8LyDkdeaXwz+y3hLmP+acds5Yyr1gBEn9lgn7iF0Sn89MDSrjSg44ZFn3NjDdyK kL3+iHWlpyMPBtJMi4Hhow/vPKhHqH0obwMy0YqMjSIOejQFf0QPKalPQQ0XuR01uc +zbdlk3s9FBOLMxUhkyGskqz5NAhREdonsUg/PBMYDyuhEfIkIv+MWzDfkT/nD2h0e jidyV8kx2cg/A== From: Masahiro Yamada To: linux-kbuild@vger.kernel.org Cc: linux-kernel@vger.kernel.org, Masahiro Yamada Subject: [PATCH 3/3] kconfig: remove P_SYMBOL property Date: Mon, 12 Aug 2024 20:49:47 +0900 Message-ID: <20240812115023.2101419-3-masahiroy@kernel.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240812115023.2101419-1-masahiroy@kernel.org> References: <20240812115023.2101419-1-masahiroy@kernel.org> Precedence: bulk X-Mailing-List: linux-kbuild@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 P_SYMBOL is a pseudo property that was previously used for data linking purposes. It is no longer used except for debug prints. Remove it. Signed-off-by: Masahiro Yamada --- scripts/kconfig/expr.h | 1 - scripts/kconfig/parser.y | 4 ---- scripts/kconfig/qconf.cc | 1 - scripts/kconfig/symbol.c | 2 -- 4 files changed, 8 deletions(-) diff --git a/scripts/kconfig/expr.h b/scripts/kconfig/expr.h index 2bc96cd28253..c82d08bbd704 100644 --- a/scripts/kconfig/expr.h +++ b/scripts/kconfig/expr.h @@ -168,7 +168,6 @@ enum prop_type { P_SELECT, /* select BAR */ P_IMPLY, /* imply BAR */ P_RANGE, /* range 7..100 (for a symbol) */ - P_SYMBOL, /* where a symbol is defined */ }; struct property { diff --git a/scripts/kconfig/parser.y b/scripts/kconfig/parser.y index e03731184840..2d5e5ed56aba 100644 --- a/scripts/kconfig/parser.y +++ b/scripts/kconfig/parser.y @@ -707,10 +707,6 @@ static void print_symbol(FILE *out, const struct menu *menu) print_quoted_string(out, prop->text); fputc('\n', out); break; - case P_SYMBOL: - fputs( " symbol ", out); - fprintf(out, "%s\n", prop->menu->sym->name); - break; default: fprintf(out, " unknown prop %d!\n", prop->type); break; diff --git a/scripts/kconfig/qconf.cc b/scripts/kconfig/qconf.cc index 7d239c032b3d..88797d174261 100644 --- a/scripts/kconfig/qconf.cc +++ b/scripts/kconfig/qconf.cc @@ -1094,7 +1094,6 @@ QString ConfigInfoView::debug_info(struct symbol *sym) case P_RANGE: case P_COMMENT: case P_IMPLY: - case P_SYMBOL: stream << prop_get_type_name(prop->type); stream << ": "; expr_print(prop->expr, expr_print_help, diff --git a/scripts/kconfig/symbol.c b/scripts/kconfig/symbol.c index 71502abd3b12..d75665f3dfa2 100644 --- a/scripts/kconfig/symbol.c +++ b/scripts/kconfig/symbol.c @@ -1321,8 +1321,6 @@ const char *prop_get_type_name(enum prop_type type) return "imply"; case P_RANGE: return "range"; - case P_SYMBOL: - return "symbol"; case P_UNKNOWN: break; }