From patchwork Sun Jul 12 08:11:43 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Cheng Renquan X-Patchwork-Id: 35237 Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n6C8DM4h009372 for ; Sun, 12 Jul 2009 08:13:22 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751315AbZGLIM0 (ORCPT ); Sun, 12 Jul 2009 04:12:26 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1751339AbZGLIM0 (ORCPT ); Sun, 12 Jul 2009 04:12:26 -0400 Received: from hera.kernel.org ([140.211.167.34]:53907 "EHLO hera.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751315AbZGLIMY (ORCPT ); Sun, 12 Jul 2009 04:12:24 -0400 Received: from hera.kernel.org (IDENT:U2FsdGVkX1+s/jLLQ5uL0KBo2UJyP0TmPfi2nkoKScM@localhost [127.0.0.1]) by hera.kernel.org (8.14.2/8.14.2) with ESMTP id n6C8BnPe019667 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Sun, 12 Jul 2009 08:11:49 GMT Received: (from crq@localhost) by hera.kernel.org (8.14.2/8.13.1/Submit) id n6C8BnPh019666; Sun, 12 Jul 2009 16:11:49 +0800 From: Cheng Renquan To: linux-kbuild@vger.kernel.org, Sam Ravnborg Cc: Andrew Morton , linux-kernel@vger.kernel.org, crquan@gmail.com Subject: [PATCH 1/6] add symbol value to help find the real depend Date: Sun, 12 Jul 2009 16:11:43 +0800 Message-Id: <1247386308-19628-2-git-send-email-crq@kernel.org> X-Mailer: git-send-email 1.6.3.3 In-Reply-To: <1247386308-19628-1-git-send-email-crq@kernel.org> References: <1247386308-19628-1-git-send-email-crq@kernel.org> X-Virus-Scanned: ClamAV 0.93.3/9555/Sat Jul 11 08:31:19 2009 on hera.kernel.org X-Virus-Status: Clean X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00, UNPARSEABLE_RELAY autolearn=ham version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on hera.kernel.org X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.0 (hera.kernel.org [127.0.0.1]); Sun, 12 Jul 2009 08:11:49 +0000 (UTC) Sender: linux-kbuild-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kbuild@vger.kernel.org From: Cheng Renquan kbuild-menuconfig-display-depend-value.patch Sometimes when configuring need to disable some unused item, but the item is selected by many other items, it's hard to find the real dependency which selected it, This patch add every symbol's value accompanied to make it possible to find the real dependency easily. An example is CONFIG_RFKILL, ---------------------- RF switch subsystem support ---------------------- | CONFIG_RFKILL: | | | | Say Y here if you want to have control over RF switches | | found on many WiFi and Bluetooth cards. | | | | To compile this driver as a module, choose M here: the | | module will be called rfkill. | | | | Symbol: RFKILL [=m] | | Prompt: RF switch subsystem support | | Defined at net/rfkill/Kconfig:4 | | Depends on: NET [=y] | | Location: | | -> Networking support (NET [=y]) | | Selected by: IWLCORE [=n] && NETDEVICES [=y] && !S390 [=S390] && PC | | | ----------------------------------------------------------------( 99%)--- Signed-off-by: Cheng Renquan --- scripts/kconfig/expr.c | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/scripts/kconfig/expr.c b/scripts/kconfig/expr.c index 579ece4..cd8a2f0 100644 --- a/scripts/kconfig/expr.c +++ b/scripts/kconfig/expr.c @@ -1098,6 +1098,8 @@ void expr_fprint(struct expr *e, FILE *out) static void expr_print_gstr_helper(void *data, struct symbol *sym, const char *str) { str_append((struct gstr*)data, str); + if (sym) + str_printf((struct gstr*)data, " [=%s]", sym_get_string_value(sym)); } void expr_gstr_print(struct expr *e, struct gstr *gs)