Received: by 2002:a6b:fb09:0:0:0:0:0 with SMTP id h9csp3908920iog; Tue, 28 Jun 2022 05:24:31 -0700 (PDT) X-Google-Smtp-Source: AGRyM1u2K2WchwxHd8iWBX+xMAVneV0knAkbKV9AlTFpi9/o0mxXCXPOg4LeRnxjSlEtkkKdNjmo X-Received: by 2002:a17:907:2d8b:b0:711:f167:c818 with SMTP id gt11-20020a1709072d8b00b00711f167c818mr17201550ejc.318.1656419070724; Tue, 28 Jun 2022 05:24:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1656419070; cv=none; d=google.com; s=arc-20160816; b=vR5xfcxXseY5swFFNn7y6Ugor0k9AUJQ87PXVpgqJiRWElkmZdhq9uVrlhL+jnWRux jKsPTuzpV2CwB8FB+6w3SxZZBgRocnRMs07TY3TC6ZKleNz1bak3C3BbEpbzmJQtQ/vP 9Dl3sW9mIiAHV4EbaXeWpODCfWJwCanhi9Y/BFZe4e4GZpBVjQ6nVbdZyqzOXNDeeiG2 aEl/yTmaBEjcL626JB84w2SpbTvApE8l28TsZZm+TcNH8RBvT1r7vf9jwvh3b+Mno20/ FVF6Ojhk1XpcqZmK06uoyx5Azq21Zh1h3x382oy7Ggstj9+6TSgGTIOTDqayavgo+Wep Uvbg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature:dkim-filter; bh=JffHlLZUherizBJLBM6/lGEJp5Xw5S7lrKLMg+knO2w=; b=qrD5q1hvYjss7rSxARsrbGyYUqyupNdeLIJ648KGoCJxpf9JaDJw0UvsKxVSWT0jiD nBsGdgiacgRGVJVPsfguwTi77wgoorlT/umgO9xGztL+h6OE35smnrsuemv/+3UyG6Ci fuZUcOEMyI6yLfXiB88RO+E22FscHdG3QltTr7PdP0KkW/G/z8PigaXi/qXf7x3sepgO vuXHEkwsxKL73ZopZtaxRKZZYf8oFASWTAr74eadn4A5PcDHLSrelz9+mmD1d1iisNfd s77/VakKo01qy25InPPhRcvIZ1DKnBWJX8H7Dt0PaX/auc0OGzWkubTTJrc1F1S5mqKb ACow== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=BeUghGFX; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id a20-20020a50c314000000b004355a6f9844si16496366edb.206.2022.06.28.05.24.04; Tue, 28 Jun 2022 05:24:30 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=BeUghGFX; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 S1345186AbiF1MKU (ORCPT + 99 others); Tue, 28 Jun 2022 08:10:20 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40346 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1345177AbiF1MKT (ORCPT ); Tue, 28 Jun 2022 08:10:19 -0400 Received: from conssluserg-06.nifty.com (conssluserg-06.nifty.com [210.131.2.91]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 21C89340E1 for ; Tue, 28 Jun 2022 05:10:17 -0700 (PDT) Received: from mail-wr1-f42.google.com (mail-wr1-f42.google.com [209.85.221.42]) (authenticated) by conssluserg-06.nifty.com with ESMTP id 25SCA1Fj015030 for ; Tue, 28 Jun 2022 21:10:01 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conssluserg-06.nifty.com 25SCA1Fj015030 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1656418202; bh=JffHlLZUherizBJLBM6/lGEJp5Xw5S7lrKLMg+knO2w=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=BeUghGFX90w9S5IO0k+SelnLeP+l3MRYfC5E0ae08BxwWRIn3M4wDSO4PjtNk1mZh 1Z2Ar7YltBJQIXdPrpIGcCwlQFyqFjAhL7Gh6cCxl7CGhOjpzsTuRi3IiOIt0tnEOj EVD7zGvg47oprs/TIZ6syY+ojGgI8suZvcHfLuK9aE1cja1xY466dOjQ+OQsO4hUo+ T42W6ktWrc+txo6xMCZz10DMXRZiWWND0AP3VtzysE1gROO5DXp1hbEy4XcXEpaD7z ylaezMY3F0Gsc67hOJ1D4JV0LQsq0/GhAk7R63U4D2ccdLw2SiQpkXy4iteTky/8Ke 4ogscDZiMxErg== X-Nifty-SrcIP: [209.85.221.42] Received: by mail-wr1-f42.google.com with SMTP id r20so17415809wra.1 for ; Tue, 28 Jun 2022 05:10:01 -0700 (PDT) X-Gm-Message-State: AJIora+jIrh/4jQGwSERBoQmXA9XXsxpRJN5rjvEYFJsvyRL7DBNNIkR qAhNGjrhf7T0x+DR/YBKdVRq62hmUbCpNT6eQk8= X-Received: by 2002:adf:f5ce:0:b0:21b:832c:80dd with SMTP id k14-20020adff5ce000000b0021b832c80ddmr17211750wrp.235.1656418200142; Tue, 28 Jun 2022 05:10:00 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Masahiro Yamada Date: Tue, 28 Jun 2022 21:09:15 +0900 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [RFC][PATCH] kconfig: Add implicit CONFIG_ prefix to IS_ENABLED() and co To: Peter Zijlstra Cc: Arnd Bergmann , Michal Marek , Paul Gortmaker , Mike Rapoport , Borislav Petkov , Linux Kernel Mailing List Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-1.2 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_SOFTFAIL, T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jun 28, 2022 at 9:02 PM Peter Zijlstra wrote: > > On Tue, Jun 28, 2022 at 01:19:17PM +0200, Arnd Bergmann wrote: > > On Tue, Jun 28, 2022 at 11:56 AM Peter Zijlstra wrote: > > > > > > Since IS_ENABLED() (and friends) are clearly meant to be used on > > > CONFIG_foo symbols and IS_ENABLED(CONFIG_ is so long and almost an > > > tautology, allow the more compact usage of: IS_ENABLED(foo). > > > > > > Signed-off-by: Peter Zijlstra (Intel) > > > > I'd prefer to keep the more verbose usage, mainly because it makes it easier > > to grep for a symbol. If today you do 'git grep CONFIG_PM_SLEEP', you find > > all instances in Makefile, in #ifdef and in IS_ENABLED(), though not the > > references in Kconfig language, which leave out the prefix. > > Which is why I never grep for the CONFIG_ thing to begin with, it misses > the Kconfig site. > > > If we remove the prefix for IS_ENABLED(), the same grep fails to get > > all the results, while searching for the substring without the CONFIG_ > > prefix can end up finding false-positives by finding longer strings (e.g. > > CONFIG_DEBUG_STACKOVERFLOW vs > > CONFIG_HAVE_DEBUG_STACKOVERFLOW). > > Me being used to that doesn't consider that a real issue :-) I'd much > rather have the somewhat shorter IS_ENABLED() things. One more thing worth mentioning, this patch does not even work correctly. scripts/basic/fixdep.c searches for CONFIG_ prefix. This works nicely, and there is no reason to lose this simplicity. NACK. -- Best Regards Masahiro Yamada