public inbox for linux-kbuild@vger.kernel.org
 help / color / mirror / Atom feed
From: "Vincenzo Palazzo" <vincenzopalazzodev@gmail.com>
To: "Masahiro Yamada" <masahiroy@kernel.org>
Cc: <linux-kbuild@vger.kernel.org>, "Roland Kletzing" <devzero@web.de>
Subject: Re: [PATCH v2] script: modpost: emit a warning when the description is missing
Date: Wed, 07 Jun 2023 22:06:07 +0200	[thread overview]
Message-ID: <CT6OSU5FVKQH.2JBA7PNTYRA23@vincent-arch> (raw)
In-Reply-To: <CAK7LNAR0uMvf+k7LPXtMjigKFPeNu5m5EhAkvk2RVRHkdjdbdg@mail.gmail.com>

> On Thu, Mar 9, 2023 at 9:01 PM Vincenzo Palazzo
> <vincenzopalazzodev@gmail.com> wrote:
> >
> > Emit a warning when the mod description is missed and only
> > when the W=1 is enabled.
> >
> > Reported-by: Roland Kletzing <devzero@web.de>
> > Link: https://bugzilla.kernel.org/show_bug.cgi?id=10770
> > Signed-off-by: Vincenzo Palazzo <vincenzopalazzodev@gmail.com>
> > ---
> >  scripts/mod/modpost.c | 4 ++++
> >  1 file changed, 4 insertions(+)
> >
> > diff --git a/scripts/mod/modpost.c b/scripts/mod/modpost.c
> > index efff8078e395..433518dfc472 100644
> > --- a/scripts/mod/modpost.c
> > +++ b/scripts/mod/modpost.c
> > @@ -1824,6 +1824,10 @@ static void read_symbols(const char *modname)
> >                 }
> >         }
> >
> > +#ifdef WARN
> > +       if (!get_modinfo(&info, "description"))
> > +               warn("missing MODULE_DESCRIPTION() in %s\n", modname);
> > +#endif
> >         for (sym = info.symtab_start; sym < info.symtab_stop; sym++) {
> >                 symname = remove_dot(info.strtab + sym->st_name);
>
>
> Sorry for the delay.
>
> Users need to do "make HOSTCFLAGS=-DWARN" to make it work,
> but nobody would do it.
>
>
> I did a ground work:
> https://patchwork.kernel.org/project/linux-kbuild/patch/20230606094159.1910369-1-masahiroy@kernel.org/
>

Uh, thanks for doing this!

>
>
> Then, you can do like this:
>
>   if (extra_warn && !get_modinfo(&info, "description"))
>            warn("missing MODULE_DESCRIPTION() in %s\n", modname);
>

Do you preferer that I rebase on top of your patch? or just waiting that 
your patch will be in next?

  reply	other threads:[~2023-06-07 20:06 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-03-09 12:01 [PATCH v2] script: modpost: emit a warning when the description is missing Vincenzo Palazzo
2023-06-06 10:58 ` Masahiro Yamada
2023-06-07 20:06   ` Vincenzo Palazzo [this message]
2023-06-08  0:42     ` Masahiro Yamada
2023-06-15 23:28   ` Vincenzo Palazzo

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=CT6OSU5FVKQH.2JBA7PNTYRA23@vincent-arch \
    --to=vincenzopalazzodev@gmail.com \
    --cc=devzero@web.de \
    --cc=linux-kbuild@vger.kernel.org \
    --cc=masahiroy@kernel.org \
    /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