mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Nicolas Schier <nicolas@fjasle.eu>
To: Paulo Miguel Almeida <paulo.miguel.almeida.rodenas@gmail.com>
Cc: masahiroy@kernel.org, nathan@kernel.org, ndesaulniers@google.com,
	corbet@lwn.net, cristian.ciocaltea@collabora.com,
	gregkh@linuxfoundation.org, vipinsh@google.com,
	linux-kbuild@vger.kernel.org, linux-doc@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH v3 RESEND] scripts/tags.sh: choose which directories to exclude from being indexed
Date: Tue, 10 Jan 2023 06:07:11 +0100	[thread overview]
Message-ID: <Y7zyf+d6JSPUsIDt@bergen.fjasle.eu> (raw)
In-Reply-To: <Y7SKBqxULPofEry7@mail.google.com>

[-- Attachment #1: Type: text/plain, Size: 2502 bytes --]

On Wed 04 Jan 2023 09:03:18 GMT, Paulo Miguel Almeida wrote:
> It's common for drivers that share same physical components to also
> duplicate source code (or at least portions of it). A good example is
> both drivers/gpu/drm/amdgpu/* and drivers/gpu/drm/radeon/* have a header
> file called atombios.h.
> 
> While their contents aren't the same, a lot of their structs have
> the exact same names which makes navigating through the code base a bit
> messy as cscope will show up 'references' across drivers which aren't
> exactly correct.
> 
> Add IGNORE_DIRS variable, which specifies which directories
> to be ignored from indexing.
> 
> Example:
>         make ARCH=x86 IGNORE_DIRS="drivers/gpu/drm/radeon tools" cscope
> 
> Signed-off-by: Paulo Miguel Almeida <paulo.miguel.almeida.rodenas@gmail.com>
> ---
> Changelog:
> 
> - v3: change commit message wording and rst syntax (Req Bagas Sanjaya)
>       change makefile variable scope to global, use blank space
>       separator and change variable name to IGNORE_DIRS.
>       (Req: Vipin Sharma)
> - v2: change approach to include everything unless specified by the 
>   IGNOREDIRS variable: (Req: Vipin Sharma)
> - v1: https://lore.kernel.org/lkml/Y5OKDvbGk4Kro6MK@mail.google.com/
> 
> Additional notes (if relevant):
> - Patch v3 was reviewed-by Vipin Sharma here:
>   https://lore.kernel.org/lkml/CAHVum0eNp5Dup_KyrS2N0zu5TfrtcCxphRnLuBFZa5PxahVg7A@mail.gmail.com/
> ---
>  Documentation/kbuild/kbuild.rst | 7 +++++++
>  scripts/tags.sh                 | 7 +++++++
>  2 files changed, 14 insertions(+)
> 
> diff --git a/Documentation/kbuild/kbuild.rst b/Documentation/kbuild/kbuild.rst
> index 08f575e6236c..5202186728b4 100644
> --- a/Documentation/kbuild/kbuild.rst
> +++ b/Documentation/kbuild/kbuild.rst
> @@ -278,6 +278,13 @@ To get all available archs you can also specify all. E.g.::
>  
>      $ make ALLSOURCE_ARCHS=all tags
>  
> +IGNORE_DIRS
> +-----------
> +For tags/TAGS/cscope targets, you can choose which directories won't
> +be included in the databases, separated by blank space. E.g.::
> +
> +    $ make IGNORE_DIRS="drivers/gpu/drm/radeon tools" cscope
> +

Thanks for the patch!

I think it might be good to add a note about that this is not ignoring 
arch sources (here and in the commit message).  For kbuild.rst perhaps 
something like: "For filtering-out sources below arch, see 
ALLSOURCE_ARCHS above."

Reviewed-by: Nicolas Schier <nicolas@fjasle.eu>

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

      reply	other threads:[~2023-01-10  5:08 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-01-03 20:03 Paulo Miguel Almeida
2023-01-10  5:07 ` Nicolas Schier [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=Y7zyf+d6JSPUsIDt@bergen.fjasle.eu \
    --to=nicolas@fjasle.eu \
    --cc=corbet@lwn.net \
    --cc=cristian.ciocaltea@collabora.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kbuild@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=masahiroy@kernel.org \
    --cc=nathan@kernel.org \
    --cc=ndesaulniers@google.com \
    --cc=paulo.miguel.almeida.rodenas@gmail.com \
    --cc=vipinsh@google.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®