From: Daniel Vetter <daniel@ffwll.ch>
To: Anna-Maria Behnsen <anna-maria@linutronix.de>
Cc: linux-doc@vger.kernel.org, Matthew Wilcox <willy@infradead.org>,
Jonathan Corbet <corbet@lwn.net>,
Maarten Lankhorst <maarten.lankhorst@linux.intel.com>,
Maxime Ripard <mripard@kernel.org>,
Thomas Zimmermann <tzimmermann@suse.de>,
David Airlie <airlied@gmail.com>, Daniel Vetter <daniel@ffwll.ch>,
dri-devel@lists.freedesktop.org
Subject: Re: [PATCH 0/2] kernel-doc: Do not pre-process comments
Date: Thu, 25 Jan 2024 19:14:10 +0100 [thread overview]
Message-ID: <ZbKk8v7MHGoYFRuu@phenom.ffwll.local> (raw)
In-Reply-To: <20240122093152.22536-1-anna-maria@linutronix.de>
On Mon, Jan 22, 2024 at 10:31:50AM +0100, Anna-Maria Behnsen wrote:
> Hi,
>
> this is a repost of the RFC queue
> https://lkml.kernel.org/r/20240116151456.48238-1-anna-maria@linutronix.de
>
> Jonathan Corbet is fine with this change and mentioned in an answer the
> following:
>
> "The kernel-doc change should really go together with the DRM change.
> I'm happy to carry both with an ack from DRMland or have the kernel-doc
> patch go through the DRM tree, whichever is easiest."
Agree, that sounds like the simplest merge plan and I don't think we have
anything in-flight for vram helpers that would cause conflicts. For
merging the drm patch through Jon's -doc tree:
Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>
>
> But back to the patchset: Commit 654784284430 ("kernel-doc: bugfix -
> multi-line macros") introduces pre-processing of backslashes at the end of
> a line to not break multi-line macros. This pre-processing is done
> independently if it is inside code or inside a comment.
>
> This illustation of a hierarchy as a code block inside a kernel-doc comment
> has a backslash at the end of the line:
>
> ---8<---
> /**
> * DOC: hierarchy
> *
> * Top Level
> * / \
> * Child A Child B
> */
> ---8<---
>
> It will be displayed as:
>
> ---8<---
> Top Level
> / * Child A Child B
> ---8<---
>
>
> As I asked for a solution on the linux-doc mailing list, I got some
> suggestions with workarounds and also got the suggestion by Matthew Wilcox
> to adapt the backslash preprocessing in kernel-doc script. I tested it and
> fixed then the newly produced warnings which are covered in the first
> patch. The processing of the documentation seems to work - but please don't
> rely on my tests as I'm not a perl neither a kernel-doc expert.
>
> Thanks,
>
> Anna-Maria
>
>
>
> Anna-Maria Behnsen (2):
> drm/vram-helper: Fix 'multi-line' kernel-doc comments
> scripts/kernel-doc: Do not process backslash lines in comments
>
> drivers/gpu/drm/drm_gem_vram_helper.c | 44 ++++++++++++---------------
> include/drm/drm_gem_vram_helper.h | 16 +++++-----
> scripts/kernel-doc | 2 +-
> 3 files changed, 29 insertions(+), 33 deletions(-)
>
> --
> 2.39.2
>
--
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
WARNING: multiple messages have this Message-ID (diff)
From: Daniel Vetter <daniel@ffwll.ch>
To: Anna-Maria Behnsen <anna-maria@linutronix.de>
Cc: Daniel Vetter <daniel@ffwll.ch>, Jonathan Corbet <corbet@lwn.net>,
dri-devel@lists.freedesktop.org, linux-doc@vger.kernel.org,
Maxime Ripard <mripard@kernel.org>,
Matthew Wilcox <willy@infradead.org>,
Thomas Zimmermann <tzimmermann@suse.de>,
David Airlie <airlied@gmail.com>
Subject: Re: [PATCH 0/2] kernel-doc: Do not pre-process comments
Date: Thu, 25 Jan 2024 19:14:10 +0100 [thread overview]
Message-ID: <ZbKk8v7MHGoYFRuu@phenom.ffwll.local> (raw)
In-Reply-To: <20240122093152.22536-1-anna-maria@linutronix.de>
On Mon, Jan 22, 2024 at 10:31:50AM +0100, Anna-Maria Behnsen wrote:
> Hi,
>
> this is a repost of the RFC queue
> https://lkml.kernel.org/r/20240116151456.48238-1-anna-maria@linutronix.de
>
> Jonathan Corbet is fine with this change and mentioned in an answer the
> following:
>
> "The kernel-doc change should really go together with the DRM change.
> I'm happy to carry both with an ack from DRMland or have the kernel-doc
> patch go through the DRM tree, whichever is easiest."
Agree, that sounds like the simplest merge plan and I don't think we have
anything in-flight for vram helpers that would cause conflicts. For
merging the drm patch through Jon's -doc tree:
Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>
>
> But back to the patchset: Commit 654784284430 ("kernel-doc: bugfix -
> multi-line macros") introduces pre-processing of backslashes at the end of
> a line to not break multi-line macros. This pre-processing is done
> independently if it is inside code or inside a comment.
>
> This illustation of a hierarchy as a code block inside a kernel-doc comment
> has a backslash at the end of the line:
>
> ---8<---
> /**
> * DOC: hierarchy
> *
> * Top Level
> * / \
> * Child A Child B
> */
> ---8<---
>
> It will be displayed as:
>
> ---8<---
> Top Level
> / * Child A Child B
> ---8<---
>
>
> As I asked for a solution on the linux-doc mailing list, I got some
> suggestions with workarounds and also got the suggestion by Matthew Wilcox
> to adapt the backslash preprocessing in kernel-doc script. I tested it and
> fixed then the newly produced warnings which are covered in the first
> patch. The processing of the documentation seems to work - but please don't
> rely on my tests as I'm not a perl neither a kernel-doc expert.
>
> Thanks,
>
> Anna-Maria
>
>
>
> Anna-Maria Behnsen (2):
> drm/vram-helper: Fix 'multi-line' kernel-doc comments
> scripts/kernel-doc: Do not process backslash lines in comments
>
> drivers/gpu/drm/drm_gem_vram_helper.c | 44 ++++++++++++---------------
> include/drm/drm_gem_vram_helper.h | 16 +++++-----
> scripts/kernel-doc | 2 +-
> 3 files changed, 29 insertions(+), 33 deletions(-)
>
> --
> 2.39.2
>
--
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
next prev parent reply other threads:[~2024-01-25 18:14 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-01-22 9:31 [PATCH 0/2] kernel-doc: Do not pre-process comments Anna-Maria Behnsen
2024-01-22 9:31 ` Anna-Maria Behnsen
2024-01-22 9:31 ` [PATCH 1/2] drm/vram-helper: Fix 'multi-line' kernel-doc comments Anna-Maria Behnsen
2024-01-22 9:31 ` Anna-Maria Behnsen
2024-01-22 9:31 ` [PATCH 2/2] scripts/kernel-doc: Do not process backslash lines in comments Anna-Maria Behnsen
2024-01-22 9:31 ` Anna-Maria Behnsen
2024-01-23 7:00 ` Randy Dunlap
2024-01-23 7:00 ` Randy Dunlap
2024-01-25 18:14 ` Daniel Vetter [this message]
2024-01-25 18:14 ` [PATCH 0/2] kernel-doc: Do not pre-process comments Daniel Vetter
2024-01-30 20:13 ` Jonathan Corbet
2024-01-30 20:13 ` Jonathan Corbet
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=ZbKk8v7MHGoYFRuu@phenom.ffwll.local \
--to=daniel@ffwll.ch \
--cc=airlied@gmail.com \
--cc=anna-maria@linutronix.de \
--cc=corbet@lwn.net \
--cc=dri-devel@lists.freedesktop.org \
--cc=linux-doc@vger.kernel.org \
--cc=maarten.lankhorst@linux.intel.com \
--cc=mripard@kernel.org \
--cc=tzimmermann@suse.de \
--cc=willy@infradead.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.