Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp1169969pxb; Wed, 10 Feb 2021 01:39:13 -0800 (PST) X-Google-Smtp-Source: ABdhPJxjZpPgtIjAslRV2V978qMsR+/deC1MR026WPkFAMk80Y8y3qwYLFAWTGoNu0eyzl9uca6S X-Received: by 2002:a17:906:3801:: with SMTP id v1mr2109723ejc.353.1612949953493; Wed, 10 Feb 2021 01:39:13 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1612949953; cv=none; d=google.com; s=arc-20160816; b=DfaBt4LuB1MhNxjutZQkWh4AoTziDyHBsLr6UKCcAdPVLzNv3SsF4WhTUb/hzOAvTU kl4+J0rPhHrYtrwLYdNldTYSz+ANC8D3EpLZcN15V0Jkp/1fzlM+vyaCEKYsyf6P77Ax vqawWW5Vb8gPoArzEOACZc28AMTuIlOda8x9Wa5X8JPxXKpejhYBb4GneP435bDeCnOZ absAqG3oDTBgjx4VA4cs7KRwbZaVox6jtdERnTaxnVOGmn/NgczcCqB52yS78PVB1rMp 3Gvo0r4o/nEAeyqxNsZhEZG97C8eon6yZsH8eIXVIGd1uwpivGb1kciggy59ByptOlAn m7xw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to :mime-version:user-agent:date:message-id:from:references:cc:to :subject; bh=96HSg4emXifw52deU3LMKE2Hm+AlqyfO2OVSZyoWvR8=; b=yMQPjrnL1YgKNDQU5cksPD8MOX5Kl5Ia/Ko9QHF3dai7bJUVl5wNo/g6aVXIEpK9vo eWshsXDtVoIWCP2A0Z9UOEzg4dFE0wbkYCJtEeJyBGyYQHf0o7CX9c8qc+CNiDgWsghs 8+fzU8pqtXiQu/3W9LLsaQtDx4I6qsH1829VNpfUE8MsfYVTX87dIHfFe2WLiVRo3bTQ IKnQSHzCeR6TvyHzMCgcvOGw+h6zEP8MM6qO+gGYz6liGQlpVJFCSx0cREIYySPqDfOS pKTFZMxxUcyggLbBBtzUxI37NpMhNjpV6MRhlLFIAh5F+SZBlOibMwuxfv1Urti7Au1e X2tQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id mp39si873528ejc.596.2021.02.10.01.38.46; Wed, 10 Feb 2021 01:39:13 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229820AbhBJJhA (ORCPT + 99 others); Wed, 10 Feb 2021 04:37:00 -0500 Received: from szxga07-in.huawei.com ([45.249.212.35]:13340 "EHLO szxga07-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229761AbhBJJeq (ORCPT ); Wed, 10 Feb 2021 04:34:46 -0500 Received: from DGGEMS411-HUB.china.huawei.com (unknown [172.30.72.60]) by szxga07-in.huawei.com (SkyGuard) with ESMTP id 4DbF021LFbz7jXq; Wed, 10 Feb 2021 17:32:02 +0800 (CST) Received: from [127.0.0.1] (10.69.38.196) by DGGEMS411-HUB.china.huawei.com (10.3.19.211) with Microsoft SMTP Server id 14.3.498.0; Wed, 10 Feb 2021 17:33:18 +0800 Subject: Re: [PATCH] PCI: Use subdir-ccflags-* to inherit debug flag To: Bjorn Helgaas CC: , , , Masahiro Yamada , "Michal Marek" , , References: <20210209212510.GA513360@bjorn-Precision-5520> From: Yicong Yang Message-ID: Date: Wed, 10 Feb 2021 17:33:18 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.5.1 MIME-Version: 1.0 In-Reply-To: <20210209212510.GA513360@bjorn-Precision-5520> Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit X-Originating-IP: [10.69.38.196] X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2021/2/10 5:25, Bjorn Helgaas wrote: > [+cc Masahiro, Michal, linux-kbuild, linux-kernel] > > On Thu, Feb 04, 2021 at 07:30:15PM +0800, Yicong Yang wrote: >> From: Junhao He >> >> Use subdir-ccflags-* instead of ccflags-* to inherit the debug >> settings from Kconfig when traversing subdirectories. >> >> Signed-off-by: Junhao He >> Signed-off-by: Yicong Yang > > I applied this with Krzysztof's reviewed-by and the commit log below > to pci/misc for v5.12, thanks! > > Feel free to copy or improve the commit log for use elsewhere. > thanks for improving the commit. i admit that i didn't make the it clear enough. it's much better now. Thanks, Yicong >> --- >> drivers/pci/Makefile | 2 +- >> 1 file changed, 1 insertion(+), 1 deletion(-) >> >> diff --git a/drivers/pci/Makefile b/drivers/pci/Makefile >> index 11cc794..d62c4ac 100644 >> --- a/drivers/pci/Makefile >> +++ b/drivers/pci/Makefile >> @@ -36,4 +36,4 @@ obj-$(CONFIG_PCI_ENDPOINT) += endpoint/ >> obj-y += controller/ >> obj-y += switch/ >> >> -ccflags-$(CONFIG_PCI_DEBUG) := -DDEBUG >> +subdir-ccflags-$(CONFIG_PCI_DEBUG) := -DDEBUG > > commit e8e9aababe60 ("PCI: Apply CONFIG_PCI_DEBUG to entire drivers/pci hierarchy") > Author: Junhao He > Date: Thu Feb 4 19:30:15 2021 +0800 > > PCI: Apply CONFIG_PCI_DEBUG to entire drivers/pci hierarchy > > CONFIG_PCI_DEBUG=y adds -DDEBUG to CFLAGS, which enables things like > pr_debug() and dev_dbg() (and hence pci_dbg()). Previously we added > -DDEBUG for files in drivers/pci/, but not files in subdirectories of > drivers/pci/. > > Add -DDEBUG to CFLAGS for all files below drivers/pci/ so CONFIG_PCI_DEBUG > applies to the entire hierarchy. > > [bhelgaas: commit log] > Link: https://lore.kernel.org/r/1612438215-33105-1-git-send-email-yangyicong@hisilicon.com > Signed-off-by: Junhao He > Signed-off-by: Yicong Yang > Signed-off-by: Bjorn Helgaas > Reviewed-by: Krzysztof WilczyƄski > > diff --git a/drivers/pci/Makefile b/drivers/pci/Makefile > index 11cc79411e2d..d62c4ac4ae1b 100644 > --- a/drivers/pci/Makefile > +++ b/drivers/pci/Makefile > @@ -36,4 +36,4 @@ obj-$(CONFIG_PCI_ENDPOINT) += endpoint/ > obj-y += controller/ > obj-y += switch/ > > -ccflags-$(CONFIG_PCI_DEBUG) := -DDEBUG > +subdir-ccflags-$(CONFIG_PCI_DEBUG) := -DDEBUG > > . >