[PATCH] Documentation: checkpatch: Add SPLIT_STRING message

Lukas Bulwahn lukas.bulwahn at gmail.com
Tue Aug 3 18:20:23 UTC 2021


On Tue, Aug 3, 2021 at 8:14 PM Utkarsh Verma <utkarshverma294 at gmail.com> wrote:
>
> On Tue, Aug 03, 2021 at 08:22:39PM +0530, Dwaipayan Ray wrote:
> > On Tue, Aug 3, 2021 at 7:49 PM Utkarsh Verma <utkarshverma294 at gmail.com> wrote:
> > >
> > > Add a new message type SPLIT_STRING under the 'Indentation and Line
> > > Breaks' subsection. Checkpatch documentation for the splitting of
> > > quoted strings that appear in userspace, across multiple lines.
> > >
> > > Signed-off-by: Utkarsh Verma <utkarshverma294 at gmail.com>
> > > Suggested-by: Lukas Bulwahn <lukas.bulwahn at gmail.com>
> > > ---
> > >  Documentation/dev-tools/checkpatch.rst | 4 ++++
> > >  1 file changed, 4 insertions(+)
> > >
> > > diff --git a/Documentation/dev-tools/checkpatch.rst b/Documentation/dev-tools/checkpatch.rst
> > > index f0956e9ea..32a26a800 100644
> > > --- a/Documentation/dev-tools/checkpatch.rst
> > > +++ b/Documentation/dev-tools/checkpatch.rst
> > > @@ -710,6 +710,10 @@ Indentation and Line Breaks
> > >
> > >      See: https://www.kernel.org/doc/html/latest/process/coding-style.html#breaking-long-lines-and-strings
> > >
> > > +  **SPLIT_STRING**
> > > +    Quoted strings that appear as messages in userspace and can be
> > > +    grepped, should not be split across multiple lines.
> > > +
> >
> > Is there any reference you can point to for this?
> > Usually LKML links are okay. So you can try adding some discussion
> > link which helps know more about why this message is important.
> >
>
> Is this reference fine:
> https://linux-kernel.vger.kernel.narkive.com/vc8OoIUF/patch-checkpatch-check-for-quoted-strings-broken-across-lines
>

Use Links to lore.kernel.org.

> Should I include these references in the commit description or the
> documentation file?
>

Add them in the documentation file. Then readers can follow those
links if interested.

Also, if there is some general conclusion within the referenced email
thread, it is good to summarize that in the documentation.


Lukas


More information about the Linux-kernel-mentees mailing list