Skip to content

ynl: avoid leaks in attr override and spec fixes for C

Jakub Kicinski netdev 1 version Applied

Status from this message: This series was applied to netdev/net.git (main)

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest8 patches 11 repliesApplied 8/8

Patches in v1 All 8 applied

#Subject and filesSizeRepliesApplied
1/8tools: ynl-gen: don't declare loop iterator in placetools/net/ynl/pyynl/ynl_gen_c.py+21 -43 repliesApplied
2/8tools: ynl-gen: move local vars after the opening brackettools/net/ynl/pyynl/ynl_gen_c.py+1 -11 replyApplied
3/8tools: ynl-gen: individually free previous values on double settools/net/ynl/pyynl/ynl_gen_c.py+45 -171 replyApplied
4/8tools: ynl-gen: make sure we validate subtype of array-nesttools/net/ynl/pyynl/ynl_gen_c.py+5 -21 replyApplied
5/8netlink: specs: rt-link: add an attr layer around alt-ifnameDocumentation/netlink/specs/rt_link.yaml+8 -31 replyApplied
6/8netlink: specs: rtnetlink: attribute naming correctionsDocumentation/netlink/specs/rt_link.yaml Documentation/netlink/specs/rt_neigh.yaml+4 -41 replyApplied
7/8netlink: specs: rt-link: adjust mctp attribute namingDocumentation/netlink/specs/rt_link.yaml+2 -11 replyApplied
8/8netlink: specs: rt-neigh: prefix struct nfmsg members with ndmDocumentation/netlink/specs/rt_neigh.yaml+6 -61 replyApplied

Reviews trailers per patch

All 8 patches have a Reviewed-by or Acked-by of their own; the series has one for all of them.

PatchJacob KellerDonald Hunter
SeriesR-b
1/8R-b
2/8R-b
3/8R-b
4/8R-b
5/8R-b
6/8R-b
7/8R-b
8/8R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH net 0/8] ynl: avoid leaks in attr override and spec fixes for C

The C rt-link work revealed more problems in existing codegen and classic netlink specs.

Patches 1 - 4 fix issues with the codegen. Patches 1 and 2 are pre-requisites for patch 3. Patch 3 fixes leaking memory if user tries to override already set attr. Patch 4 validates attrs in case kernel sends something we don't expect.

Remaining patches fix and align the specs. Patch 5 changes nesting, the rest are naming adjustments.

Jakub Kicinski (8):
tools: ynl-gen: don't declare loop iterator in place
tools: ynl-gen: move local vars after the opening bracket
tools: ynl-gen: individually free previous values on double set
tools: ynl-gen: make sure we validate subtype of array-nest
netlink: specs: rt-link: add an attr layer around alt-ifname
netlink: specs: rtnetlink: attribute naming corrections
netlink: specs: rt-link: adjust mctp attribute naming
netlink: specs: rt-neigh: prefix struct nfmsg members with ndm

 Documentation/netlink/specs/rt_link.yaml  | 20 +++--
 Documentation/netlink/specs/rt_neigh.yaml | 14 ++--
 tools/net/ynl/pyynl/ynl_gen_c.py          | 96 +++++++++++++++++------
 3 files changed, 92 insertions(+), 38 deletions(-)
Signature · 1 line
2.49.0