[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <9bb45dcae38b0f9322c0ce033c041ede02f8d7ec.camel@perches.com>
Date: Wed, 24 Jul 2019 04:41:07 -0700
From: Joe Perches <joe@...ches.com>
To: Jonathan Corbet <corbet@....net>
Cc: Stephen Kitt <steve@....org>, Kees Cook <keescook@...omium.org>,
Nitin Gote <nitin.r.gote@...el.com>, jannh@...gle.com,
kernel-hardening@...ts.openwall.com, linux-kernel@...r.kernel.org,
Rasmus Villemoes <rasmus.villemoes@...vas.dk>
Subject: Re: [PATCH] checkpatch: Added warnings in favor of strscpy().
On Mon, 2019-07-22 at 16:28 -0600, Jonathan Corbet wrote:
> On Mon, 22 Jul 2019 15:24:33 -0700
> Joe Perches <joe@...ches.com> wrote:
>
> > > If the functions themselves are fully defined in the .h file, I'd just add
> > > the kerneldoc there as well. That's how it's usually done, and you want
> > > to keep the documentation and the prototypes together.
> >
> > In this case, it's a macro and yes, the kernel-doc could
> > easily be set around the macro in the .h, but my desire
> > is to keep all the string function kernel-doc output
> > together so it should be added to lib/string.c
> >
> > Are you suggesting I move all the lib/string.c kernel-doc
> > to include/linux/string.h ?
>
> If you want the *output* together, just put the kernel-doc directives
> together in the RST file that pulls it all in. Or am I missing something
> here?
The negative of the kernel-doc separation of prototypes by .h
and .c files is that the ordering of the functions in the .rst
outout files doesn't make much logical sense.
stracpy is pretty far away from strscpy in the list of functions.
Powered by blists - more mailing lists