netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jakub Kicinski <kuba@kernel.org>
To: Oleksij Rempel <o.rempel@pengutronix.de>
Cc: Andrew Lunn <andrew@lunn.ch>,
	Vladimir Oltean <vladimir.oltean@nxp.com>,
	Alexei Starovoitov <ast@kernel.org>,
	Russell King <linux@armlinux.org.uk>,
	Eric Dumazet <edumazet@google.com>, Rob Herring <robh@kernel.org>,
	Florian Fainelli <f.fainelli@gmail.com>,
	Donald Hunter <donald.hunter@gmail.com>,
	Daniel Borkmann <daniel@iogearbox.net>,
	Jonathan Corbet <corbet@lwn.net>,
	John Fastabend <john.fastabend@gmail.com>,
	Lukasz Majewski <lukma@denx.de>,
	Maxime Chevallier <maxime.chevallier@bootlin.com>,
	Stanislav Fomichev <sdf@fomichev.me>,
	Paolo Abeni <pabeni@redhat.com>, Jiri Pirko <jiri@resnulli.us>,
	Jesper Dangaard Brouer <hawk@kernel.org>,
	Divya.Koppera@microchip.com,
	Kory Maincent <kory.maincent@bootlin.com>,
	Vadim Fedorenko <vadim.fedorenko@linux.dev>,
	netdev@vger.kernel.org, Sabrina Dubroca <sd@queasysnail.net>,
	linux-kernel@vger.kernel.org, kernel@pengutronix.de,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	"David S. Miller" <davem@davemloft.net>,
	Heiner Kallweit <hkallweit1@gmail.com>
Subject: Re: [PATCH net-next v4 0/3] Documentation and ynl: add flow control
Date: Wed, 17 Sep 2025 14:06:12 -0700	[thread overview]
Message-ID: <20250917140612.0cd98bac@kernel.org> (raw)
In-Reply-To: <aMqJhl2swbkiYx_p@pengutronix.de>

On Wed, 17 Sep 2025 12:12:22 +0200 Oleksij Rempel wrote:
> On Tue, Sep 09, 2025 at 02:32:56PM -0700, Jakub Kicinski wrote:
> > On Tue,  9 Sep 2025 09:22:09 +0200 Oleksij Rempel wrote:  
> > > This series improves kernel documentation around Ethernet flow control
> > > and enhances the ynl tooling to generate kernel-doc comments for
> > > attribute enums.
> > > 
> > > Patch 1 extends the ynl generator to emit kdoc for enums based on YAML
> > > attribute documentation.
> > > Patch 2 regenerates all affected UAPI headers (dpll, ethtool, team,
> > > net_shaper, netdev, ovpn) so that attribute enums now carry kernel-doc.
> > > Patch 3 adds a new flow_control.rst document and annotates the ethtool
> > > pause/pause-stat YAML definitions, relying on the kdoc generation
> > > support from the earlier patches.  
> > 
> > The reason we don't render the kdoc today is that I thought it's far
> > more useful to focus on the direct ReST generation. I think some of 
> > the docs are not rendered, and other may be garbled, but the main
> > structure of the documentation works quite well:
> > 
> >   https://docs.kernel.org/next/netlink/specs/dpll.html
> > 
> > Could you spell out the motivation for this change a little more?  
> 
> The reason I went down the kdoc-in-UAPI route is mostly historical.
> When I first started writing the flow control documentation, reviewers
> pointed out that the UAPI parts should be documented in the header
> files.  Since these headers are generated from YAML, the natural way was
> to move  the docstrings into the YAML and let the generator emit them.
> One step led  to another, and we ended up with this change.
> 
> I don’t have a strong preference for where the documentation lives, my
> primary goal was to avoid duplicating text and make sure the UAPI enums
> for pause / pause-stat are self-describing. If the consensus is that we
> should concentrate on ReST output only, I’m happy to reduce the scope of
> this series and drop the kernel-doc emission. The actual motivation of
> my  series is to add flow_control.rst and document the ethtool API
> there.
> 
> So if you prefer, I can respin with just the flow_control.rst and YAML  
> annotations, and skip the generator changes.

We can adapt our approach to the needs as we go. But yes, my
recollection of the series was that there wasn't actually many
touchpoints here between the generated kdoc and your newly written
docs at this stage. So let's defer rendering into the uAPI headers.

      reply	other threads:[~2025-09-17 21:06 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-09-09  7:22 [PATCH net-next v4 0/3] Documentation and ynl: add flow control Oleksij Rempel
2025-09-09  7:22 ` [PATCH net-next v4 1/3] tools: ynl-gen: generate kdoc for attribute enums Oleksij Rempel
2025-09-09 14:05   ` Donald Hunter
2025-09-09  7:22 ` [PATCH net-next v4 2/3] net: ynl: add generated kdoc to UAPI headers Oleksij Rempel
2025-09-09 14:20   ` Donald Hunter
2025-09-09  7:22 ` [PATCH net-next v4 3/3] Documentation: net: add flow control guide and document ethtool API Oleksij Rempel
2025-09-09 14:29   ` Donald Hunter
2025-09-09 21:32 ` [PATCH net-next v4 0/3] Documentation and ynl: add flow control Jakub Kicinski
2025-09-17 10:12   ` Oleksij Rempel
2025-09-17 21:06     ` Jakub Kicinski [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=20250917140612.0cd98bac@kernel.org \
    --to=kuba@kernel.org \
    --cc=Divya.Koppera@microchip.com \
    --cc=andrew@lunn.ch \
    --cc=ast@kernel.org \
    --cc=corbet@lwn.net \
    --cc=daniel@iogearbox.net \
    --cc=davem@davemloft.net \
    --cc=donald.hunter@gmail.com \
    --cc=edumazet@google.com \
    --cc=f.fainelli@gmail.com \
    --cc=hawk@kernel.org \
    --cc=hkallweit1@gmail.com \
    --cc=jiri@resnulli.us \
    --cc=john.fastabend@gmail.com \
    --cc=kernel@pengutronix.de \
    --cc=kory.maincent@bootlin.com \
    --cc=krzk+dt@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@armlinux.org.uk \
    --cc=lukma@denx.de \
    --cc=maxime.chevallier@bootlin.com \
    --cc=netdev@vger.kernel.org \
    --cc=o.rempel@pengutronix.de \
    --cc=pabeni@redhat.com \
    --cc=robh@kernel.org \
    --cc=sd@queasysnail.net \
    --cc=sdf@fomichev.me \
    --cc=vadim.fedorenko@linux.dev \
    --cc=vladimir.oltean@nxp.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;
as well as URLs for NNTP newsgroup(s).