mbox series

[net-next,v1,0/6] tools/net/ynl: Add 'sub-message' support to ynl

Message ID 20231130214959.27377-1-donald.hunter@gmail.com (mailing list archive)
Headers show
Series tools/net/ynl: Add 'sub-message' support to ynl | expand

Message

Donald Hunter Nov. 30, 2023, 9:49 p.m. UTC
This patchset adds a 'sub-message' attribute type to the netlink-raw
schema and implements it in ynl. This provides support for kind-specific
options attributes as used in rt_link and tc raw netlink families.

A description of the new 'sub-message' attribute type and the
corresponding sub-message definitions is provided in patch 2.

The patchset includes updates to the rt_link spec and a new tc spec that
make use of the new 'sub-message' attribute type.

Patch 1 adds missing scalar types to the netlink-raw schema
Patch 2 and 3 add sub-message support to the schema and ynl
Patch 4 adds binary and pad support to structs in netlink-raw
Patches 5 and 6 contain specs that use the sub-message attribute type

Donald Hunter (6):
  doc/netlink: Add bitfield32, s8, s16 to the netlink-raw schema
  doc/netlink: Add sub-message support to netlink-raw
  tools/net/ynl: Add 'sub-message' attribute decoding to ynl
  tools/net/ynl: Add binary and pad support to structs for tc
  doc/netlink/specs: add sub-message type to rt_link family
  doc/netlink/specs: Add a spec for tc

 Documentation/netlink/netlink-raw.yaml   |   56 +-
 Documentation/netlink/specs/rt_link.yaml |  273 ++-
 Documentation/netlink/specs/tc.yaml      | 2008 ++++++++++++++++++++++
 tools/net/ynl/lib/nlspec.py              |   57 +-
 tools/net/ynl/lib/ynl.py                 |   84 +-
 5 files changed, 2452 insertions(+), 26 deletions(-)
 create mode 100644 Documentation/netlink/specs/tc.yaml

Comments

patchwork-bot+netdevbpf@kernel.org Dec. 2, 2023, 1:50 a.m. UTC | #1
Hello:

This series was applied to netdev/net-next.git (main)
by Jakub Kicinski <kuba@kernel.org>:

On Thu, 30 Nov 2023 21:49:52 +0000 you wrote:
> This patchset adds a 'sub-message' attribute type to the netlink-raw
> schema and implements it in ynl. This provides support for kind-specific
> options attributes as used in rt_link and tc raw netlink families.
> 
> A description of the new 'sub-message' attribute type and the
> corresponding sub-message definitions is provided in patch 2.
> 
> [...]

Here is the summary with links:
  - [net-next,v1,1/6] doc/netlink: Add bitfield32, s8, s16 to the netlink-raw schema
    https://git.kernel.org/netdev/net-next/c/527d2cd8b852
  - [net-next,v1,2/6] doc/netlink: Add sub-message support to netlink-raw
    (no matching commit)
  - [net-next,v1,3/6] tools/net/ynl: Add 'sub-message' attribute decoding to ynl
    (no matching commit)
  - [net-next,v1,4/6] tools/net/ynl: Add binary and pad support to structs for tc
    (no matching commit)
  - [net-next,v1,5/6] doc/netlink/specs: add sub-message type to rt_link family
    (no matching commit)
  - [net-next,v1,6/6] doc/netlink/specs: Add a spec for tc
    (no matching commit)

You are awesome, thank you!
Jakub Kicinski Dec. 2, 2023, 2:15 a.m. UTC | #2
On Thu, 30 Nov 2023 21:49:52 +0000 Donald Hunter wrote:
>  Documentation/netlink/specs/rt_link.yaml |  273 ++-
>  Documentation/netlink/specs/tc.yaml      | 2008 ++++++++++++++++++++++

Should we add sub-messages to tools/net/ynl/ynl-gen-rst.py ?
Does the output look sane with the new attributes?
Donald Hunter Dec. 4, 2023, 3:54 p.m. UTC | #3
Jakub Kicinski <kuba@kernel.org> writes:

> On Thu, 30 Nov 2023 21:49:52 +0000 Donald Hunter wrote:
>>  Documentation/netlink/specs/rt_link.yaml |  273 ++-
>>  Documentation/netlink/specs/tc.yaml      | 2008 ++++++++++++++++++++++
>
> Should we add sub-messages to tools/net/ynl/ynl-gen-rst.py ?
> Does the output look sane with the new attributes?

Ah, yes we should. Okay if I look at this as a followup patch?
Jakub Kicinski Dec. 4, 2023, 6:33 p.m. UTC | #4
On Mon, 04 Dec 2023 15:54:13 +0000 Donald Hunter wrote:
> > Should we add sub-messages to tools/net/ynl/ynl-gen-rst.py ?
> > Does the output look sane with the new attributes?  
> 
> Ah, yes we should. Okay if I look at this as a followup patch?

Improving looks is 100% fine as a follow up.
But do check we don't break rendering completely for stuff we should
already support when sub-messages appear.