]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
tools: ynl: cli: print reply in combined format if possible
authorJakub Kicinski <kuba@kernel.org>
Sat, 10 Jan 2026 23:31:42 +0000 (15:31 -0800)
committerJakub Kicinski <kuba@kernel.org>
Mon, 12 Jan 2026 21:29:31 +0000 (13:29 -0800)
commit60411adedf70abec0ac221ec3d88f6453b031dd2
treeb7fdd4238ba58f70f260ecccc567fe0d5a400ff5
parent6ccc421b14613aac32b2647462ae4d40f5dd43b8
tools: ynl: cli: print reply in combined format if possible

As pointed out during review of the --list-attrs support the GET
ops very often return the same attrs from do and dump. Make the
output more readable by combining the reply information, from:

  Do request attributes:
    - ifindex: u32
      netdev ifindex

  Do reply attributes:
    - ifindex: u32
      netdev ifindex
    [ .. other attrs .. ]

  Dump reply attributes:
    - ifindex: u32
      netdev ifindex
    [ .. other attrs .. ]

To, after:

  Do request attributes:
    - ifindex: u32
      netdev ifindex

  Do and Dump reply attributes:
    - ifindex: u32
      netdev ifindex
    [ .. other attrs .. ]

Tested-by: Gal Pressman <gal@nvidia.com>
Acked-by: Stanislav Fomichev <sdf@fomichev.me>
Reviewed-by: Donald Hunter <donald.hunter@gmail.com>
Link: https://patch.msgid.link/20260110233142.3921386-8-kuba@kernel.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
tools/net/ynl/pyynl/cli.py