]> git.ipfire.org Git - thirdparty/iproute2.git/log
thirdparty/iproute2.git
13 days agoman: fix troff warnings and whitespace main
Stephen Hemminger [Sun, 28 Jun 2026 21:52:07 +0000 (14:52 -0700)] 
man: fix troff warnings and whitespace

Fix troff warnings about line breaks around URL's.
Remove unnecessary whitespace at end of line.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
13 days agobridge: whitespace cleanup
Stephen Hemminger [Sun, 28 Jun 2026 20:46:50 +0000 (13:46 -0700)] 
bridge: whitespace cleanup

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
13 days agoCREDITS: remove trailing whitespace
Stephen Hemminger [Sun, 28 Jun 2026 20:46:07 +0000 (13:46 -0700)] 
CREDITS: remove trailing whitespace

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
13 days ago.mailmap: remove trailing whitespace
Stephen Hemminger [Sun, 28 Jun 2026 20:45:44 +0000 (13:45 -0700)] 
.mailmap: remove trailing whitespace

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
13 days agouapi: update headers from 7.2-pre-rc1
Stephen Hemminger [Sun, 28 Jun 2026 20:42:43 +0000 (13:42 -0700)] 
uapi: update headers from 7.2-pre-rc1

Update kernel headers including some of the changes for ATM cleanups.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
13 days agoMerge remote-tracking branch 'main' into next
David Ahern [Sun, 28 Jun 2026 17:31:59 +0000 (11:31 -0600)] 
Merge remote-tracking branch 'main' into next

Signed-off-by: David Ahern <dsahern@kernel.org>
13 days agoMerge branch 'devlink-per-port-res' into next
David Ahern [Sun, 28 Jun 2026 17:13:03 +0000 (11:13 -0600)] 
Merge branch 'devlink-per-port-res' into next

Tariq Toukan  says:

====================

Currently, devlink resource show only supports querying a specific
device and displays device-level resources. However, some resources
are per-port, such as the maximum number of SFs that can be created
on a specific PF port.

This series extends devlink resource show with full support for
port-level resources, including a dump mode, per-port querying syntax,
and scope filtering. In preparation for these features, the first two
patches refactor how dpipe tables are handled to unblock dump support
and ensure errors in secondary queries are non-fatal.

The series is organized as follows:

Patch 1 splits the dpipe tables display into a separate function.

Patch 2 moves the dpipe tables query into the per-device resource show
callback, ensuring it behaves correctly during a multi-device dump.

Patch 3 fixes a pre-existing memory leak in resource_ctx_fini.

Patch 4 adds dump support to resource show (no device required).

Patch 5 shows port-level resources returned in a dump reply.

Patch 6 adds DEV/PORT_INDEX syntax to resource show.

Patch 7 adds scope filter to resource show.

With this series, users can query resources at all levels:

$ devlink resource show
pci/0000:03:00.0:
  name local_max_SFs size 508 unit entry
  name external_max_SFs size 508 unit entry
pci/0000:03:00.0/196608:
  name max_SFs size 20 unit entry

$ devlink resource show scope dev
pci/0000:03:00.0:
  name local_max_SFs size 508 unit entry
  name external_max_SFs size 508 unit entry

$ devlink resource show scope port
pci/0000:03:00.0/196608:
  name max_SFs size 20 unit entry

$ devlink resource show pci/0000:03:00.0/196608
pci/0000:03:00.0/196608:
  name max_SFs size 20 unit entry

This series is the userspace counterpart to the kernel series:
https://lore.kernel.org/all/20260407194107.148063-1-tariqt@nvidia.com/

====================

Signed-off-by: David Ahern <dsahern@kernel.org>
13 days agodevlink: add scope filter to resource show
Or Har-Toov [Tue, 9 Jun 2026 05:39:53 +0000 (08:39 +0300)] 
devlink: add scope filter to resource show

Add optional 'scope { dev | port }' argument to 'devlink resource show'
without a device handle to filter the full dump to device-level or
port-level resources only.

Example - dump only device-level resources:

  $ devlink resource show scope dev
  pci/0000:03:00.0:
    name max_local_SFs size 128 unit entry dpipe_tables none
    name max_external_SFs size 128 unit entry dpipe_tables none
  pci/0000:03:00.1:
    name max_local_SFs size 128 unit entry dpipe_tables none
    name max_external_SFs size 128 unit entry dpipe_tables none

Example - dump only port-level resources:

  $ devlink resource show scope port
  pci/0000:03:00.0/196608:
    name max_SFs size 128 unit entry dpipe_tables none
  pci/0000:03:00.0/196609:
    name max_SFs size 128 unit entry dpipe_tables none
  pci/0000:03:00.1/196708:
    name max_SFs size 128 unit entry dpipe_tables none
  pci/0000:03:00.1/196709:
    name max_SFs size 128 unit entry dpipe_tables none

Signed-off-by: Or Har-Toov <ohartoov@nvidia.com>
Signed-off-by: Tariq Toukan <tariqt@nvidia.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
13 days agodevlink: add per-port resource show support
Or Har-Toov [Tue, 9 Jun 2026 05:39:52 +0000 (08:39 +0300)] 
devlink: add per-port resource show support

Extend 'devlink resource show' to accept DEV/PORT_INDEX, sending
DEVLINK_ATTR_PORT_INDEX to the kernel so it returns only that port's
resources directly.

For example:

$ devlink resource show pci/0000:03:00.0/196608
pci/0000:03:00.0/196608:
  name max_SFs size 128 unit entry dpipe_tables none

Signed-off-by: Or Har-Toov <ohartoov@nvidia.com>
Signed-off-by: Tariq Toukan <tariqt@nvidia.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
13 days agodevlink: show port resources in resource dump
Or Har-Toov [Tue, 9 Jun 2026 05:39:51 +0000 (08:39 +0300)] 
devlink: show port resources in resource dump

When the kernel returns port-level resource messages during a
DEVLINK_CMD_RESOURCE_DUMP, display them alongside device-level
resources.

For example:

$ devlink resource show
pci/0000:03:00.0:
  name max_local_SFs size 32 unit entry dpipe_tables none
  name max_external_SFs size 32 unit entry dpipe_tables none
pci/0000:03:00.0/196608:
  name max_SFs size 32 unit entry dpipe_tables none
pci/0000:03:00.1:
  name max_local_SFs size 32 unit entry dpipe_tables none
  name max_external_SFs size 32 unit entry dpipe_tables none
pci/0000:03:00.1/262144:
  name max_SFs size 32 unit entry dpipe_tables none

Signed-off-by: Or Har-Toov <ohartoov@nvidia.com>
Signed-off-by: Tariq Toukan <tariqt@nvidia.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
13 days agodevlink: add dump support for resource show
Or Har-Toov [Tue, 9 Jun 2026 05:39:50 +0000 (08:39 +0300)] 
devlink: add dump support for resource show

Allow 'devlink resource show' without specifying a device to dump
resources from all devlink devices.

Signed-off-by: Or Har-Toov <ohartoov@nvidia.com>
Signed-off-by: Tariq Toukan <tariqt@nvidia.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
13 days agodevlink: fix memory leak in resource_ctx_fini
Or Har-Toov [Tue, 9 Jun 2026 05:39:49 +0000 (08:39 +0300)] 
devlink: fix memory leak in resource_ctx_fini

resource_ctx_init() allocates ctx->resources via resources_alloc()
which calls calloc(). resource_ctx_fini() calls resources_free() to
free the list items inside the struct, but never frees the struct
itself.

Signed-off-by: Or Har-Toov <ohartoov@nvidia.com>
Signed-off-by: Tariq Toukan <tariqt@nvidia.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
13 days agodevlink: Move dpipe tables query to resources show callback
Ido Schimmel [Tue, 9 Jun 2026 05:39:48 +0000 (08:39 +0300)] 
devlink: Move dpipe tables query to resources show callback

As previously explained, as part of showing device resources, devlink
queries the device's dpipe tables so that it will be able to show the
association between resources and dpipe tables.

Currently, the dpipe tables are queried before the device resources.
This will become a problem when devlink is extended to support dumping
the resources of all available devices.

Therefore, in preparation for resource dump support, move the querying
of the device's dpipe tables to the resources show callback which is
invoked per-device.

There is no difference in the output of the resource show command, but
one functional difference is that errors in dpipe tables query are not
considered fatal. This seems reasonable given that errors are unlikely
and that displaying the dpipe tables is secondary to showing the device
resources.

Reviewed-by: Petr Machata <petrm@nvidia.com>
Reviewed-by: Jiri Pirko <jiri@nvidia.com>
Signed-off-by: Ido Schimmel <idosch@nvidia.com>
Signed-off-by: Tariq Toukan <tariqt@nvidia.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
13 days agodevlink: Split dpipe tables output to a separate function
Ido Schimmel [Tue, 9 Jun 2026 05:39:47 +0000 (08:39 +0300)] 
devlink: Split dpipe tables output to a separate function

As part of showing device resources, devlink also iterates over
available dpipe tables and shows the associated tables, if any.

A subsequent patch will show the device resources even if we failed to
retrieve the dpipe tables. In preparation for this change, split the
functionality of showing the associated dpipe tables into a separate
function.

No functional changes intended.

Reviewed-by: Petr Machata <petrm@nvidia.com>
Reviewed-by: Jiri Pirko <jiri@nvidia.com>
Signed-off-by: Ido Schimmel <idosch@nvidia.com>
Signed-off-by: Tariq Toukan <tariqt@nvidia.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
3 weeks agov7.1.0 v7.1.0
Stephen Hemminger [Mon, 15 Jun 2026 22:50:05 +0000 (15:50 -0700)] 
v7.1.0

4 weeks agoiplink_geneve: Support IFLA_GENEVE_LOCAL and IFLA_GENEVE_LOCAL6.
Kuniyuki Iwashima [Mon, 8 Jun 2026 03:16:58 +0000 (03:16 +0000)] 
iplink_geneve: Support IFLA_GENEVE_LOCAL and IFLA_GENEVE_LOCAL6.

IFLA_GENEVE_LOCAL and IFLA_GENEVE_LOCAL6 allow specifying a local
IPv4/IPv6 address for the backend UDP socket of a GENEVE devcie.

Let's support the attributes with the "local" keyword.

  # for i in $(seq 1 2);
  do
          ip link add geneve4_${i} type geneve local 192.168.0.${i} external
          ip addr add 192.168.0.${i}/24 dev geneve4_${i}
          ip link set geneve4_${i} up

          ip link add geneve6_${i} type geneve local 2001:9292::${i} external
          ip addr add 2001:9292::${i}/64 dev geneve6_${i} nodad
          ip link set geneve6_${i} up
  done

  # ip -d l | grep geneve
  9: geneve4_1: <BROADCAST,MULTICAST,UP,LOWER_UP> ...
      geneve external id 0 local 192.168.0.1 ...
  10: geneve6_1: <BROADCAST,MULTICAST,UP,LOWER_UP> ...
      geneve external id 0 local 2001:9292::1 ...
  11: geneve4_2: <BROADCAST,MULTICAST,UP,LOWER_UP> ...
      geneve external id 0 local 192.168.0.2 ...
  12: geneve6_2: <BROADCAST,MULTICAST,UP,LOWER_UP> ...
      geneve external id 0 local 2001:9292::2 ...

  # ss -ua | grep geneve
  UNCONN 0      0         192.168.0.2:geneve      0.0.0.0:*
  UNCONN 0      0         192.168.0.1:geneve      0.0.0.0:*
  UNCONN 0      0      [2001:9292::2]:geneve            *:*
  UNCONN 0      0      [2001:9292::1]:geneve            *:*

Note that kernel dumps the wildcard address if the device created
with IFLA_GENEVE_COLLECT_METADATA is not dualstack.

Signed-off-by: Kuniyuki Iwashima <kuniyu@google.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
4 weeks agoiplink: set NLA_F_NESTED for IPv4 devconf attributes
Fernando Fernandez Mancera [Sun, 7 Jun 2026 06:57:15 +0000 (08:57 +0200)] 
iplink: set NLA_F_NESTED for IPv4 devconf attributes

In order to use set multiple IPv4 devconf parameters at once,
NLA_F_NESTED flag is required.

ip link set dev enp8s0 inet forwarding on proxy_arp off

Fixes: fdb064bf64e5 ("iplink: add support for setting IPv4 devconf parameters")
Signed-off-by: Fernando Fernandez Mancera <fmancera@suse.de>
Signed-off-by: David Ahern <dsahern@kernel.org>
4 weeks agoman: iplink: fix indentation level after inet parameter
Fernando Fernandez Mancera [Sun, 7 Jun 2026 06:57:14 +0000 (08:57 +0200)] 
man: iplink: fix indentation level after inet parameter

The indentation for inet block opens with +8 but closes with -10. Fix
the imbalance.

Fixes: fdb064bf64e5 ("iplink: add support for setting IPv4 devconf parameters")
Signed-off-by: Fernando Fernandez Mancera <fmancera@suse.de>
Signed-off-by: David Ahern <dsahern@kernel.org>
4 weeks agoUpdate kernel headers
David Ahern [Sun, 7 Jun 2026 13:44:44 +0000 (07:44 -0600)] 
Update kernel headers

Update kernel headers to commit:
903db046d557: ("net: stmmac: xgmac: report L3/L4 filter match count in ethtool stats")

Signed-off-by: David Ahern <dsahern@kernel.org>
5 weeks agoiplink: bridge: add stp_mode support
Andy Roulin [Wed, 3 Jun 2026 17:33:04 +0000 (10:33 -0700)] 
iplink: bridge: add stp_mode support

Add support for the IFLA_BR_STP_MODE bridge attribute that allows
userspace to explicitly select the STP mode:

  - auto (0): default, try /sbin/bridge-stp helper in init_net
  - user (1): directly enable userspace STP without the helper,
    works in any network namespace
  - kernel (2): directly enable kernel STP without the helper

A shared file-scope stp_modes[] table indexed by BR_STP_MODE_* drives
both directions: parsing uses parse_one_of(), printing goes through a
stp_mode_to_str() helper that returns "(unknown)" for modes not yet
known to iproute2, keeping the JSON type of stp_mode consistently a
string.

Example usage:
  ip link set br0 type bridge stp_mode user
  ip link set br0 type bridge stp_state 1

Link: https://lore.kernel.org/netdev/20260405205224.3163000-1-aroulin@nvidia.com/
Assisted-by: Claude:claude-opus-4-7
Reviewed-by: Ido Schimmel <idosch@nvidia.com>
Reviewed-by: Nikolay Aleksandrov <nikolay@nvidia.com>
Signed-off-by: Andy Roulin <aroulin@nvidia.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
5 weeks agoiplink: add support for setting IPv4 devconf parameters
Fernando Fernandez Mancera [Mon, 1 Jun 2026 14:32:42 +0000 (16:32 +0200)] 
iplink: add support for setting IPv4 devconf parameters

Currently, modifying IPv4 interface configuration parameters requires
interacting with sysctl (/proc/sys/net/ipv4/conf/*). While
ip-netconf exists for monitoring these values, there has been no native
way to set them directly through iproute2.

This patch introduces the support for that via 'inet' at the 'ip link
set'. It uses IFLA_INET_CONF netlink attribute to set the parameter.

Example to enable forwarding on an interface:

ip link set dev enp8s0 inet forwarding on

Signed-off-by: Fernando Fernandez Mancera <fmancera@suse.de>
Signed-off-by: David Ahern <dsahern@kernel.org>
(Code length fixups and s/matches/strcmp/ when applying)

6 weeks agodpll: monitor: add -t/--timestamp and --tshort options
Petr Oros [Tue, 26 May 2026 11:52:45 +0000 (13:52 +0200)] 
dpll: monitor: add -t/--timestamp and --tshort options

Bring dpll monitor in line with the rest of iproute2 by allowing each
received notification to be prefixed with a wall-clock timestamp.

  -t / --timestamp  emit a separate "Timestamp:" line before each event,
                    using the default text form of print_timestamp()
                    (matches ip / bridge / tc -t monitor)
  --tshort          emit a compact ISO 8601 prefix
                    "[YYYY-MM-DDTHH:MM:SS.uuuuuu]" inline instead
                    (matches ip -ts monitor)

When combined with -j, the timestamp shows up as a "timestamp" /
"timestamp_short" field on each notification object, the same way
ip -j -t mptcp monitor integrates the helper.

The flag is parsed globally but only consulted from the monitor
callback, so passing -t to non-monitor commands is a no-op.

--tshort has no short alias, so its long_options entry uses an
identifier above the ASCII range (OPT_TSHORT = 256) following the
iproute2 convention used in misc/ss.c, instead of consuming an
ASCII letter that could later collide with a real short option.

Reviewed-by: Ivan Vecera <ivecera@redhat.com>
Signed-off-by: Petr Oros <poros@redhat.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
6 weeks agodpll: man: restore Frequency monitor status in device show output
Petr Oros [Tue, 26 May 2026 11:53:09 +0000 (13:53 +0200)] 
dpll: man: restore Frequency monitor status in device show output

The dpll(8) merge of main into next (commit 62d1e70fa85a37 ("Merge
remote-tracking branch 'main/main' into next")) resolved the conflict
in the "dpll device show" output bullet list by keeping main's three
new entries (Supported modes, Phase offset monitor status, Phase
offset averaging factor) but inadvertently dropped the
"Frequency monitor status (enable/disable)" entry that was
introduced on next by commit 12954bc7d2c3 ("dpll: add frequency
monitoring support").

The frequency-monitor feature itself is still present (parser,
device-set documentation and pin "Measured frequency in Hz" line
are intact), only the corresponding bullet in the device-get output
list was lost.  Add it back so the listed attributes match what
"dpll device show" actually prints.

Signed-off-by: Petr Oros <poros@redhat.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
7 weeks agoll_map: add RTEXT_FILTER_NAME_ONLY to ll_link_get() and ll_init_map()
Eric Dumazet [Wed, 20 May 2026 10:30:43 +0000 (10:30 +0000)] 
ll_map: add RTEXT_FILTER_NAME_ONLY to ll_link_get() and ll_init_map()

iproute2 can spend considerable amount of time in ll_init_map()
or ll_link_get() to dump verbose netdev attributes, contributing
to RTNL pressure.

Add RTEXT_FILTER_NAME_ONLY new flag so that rtnl_fill_ifinfo()
limits its output to:

    - struct nlmsghdr
    - IFLA_IFNAME
    - IFLA_PROP_LIST (alternate names)

This is supported in linux 7.2+ (and ignored in old kernels).

RTNL avoidance should be automatically provided in upcoming
kernel patches.

Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
7 weeks agoUpdate kernel headers
David Ahern [Fri, 22 May 2026 22:14:39 +0000 (16:14 -0600)] 
Update kernel headers

Update kernel headers to commit:
95fab46aea57: ("Merge branch 'net-convert-atm-xdp-af_iucv-l2tp_ppp-rxrpc-tipc-to-getsockopt_iter'")

Signed-off-by: David Ahern <dsahern@kernel.org>
7 weeks agotc/netem: display per-impairment xstats counters
Stephen Hemminger [Wed, 20 May 2026 17:34:46 +0000 (10:34 -0700)] 
tc/netem: display per-impairment xstats counters

The kernel now reports struct tc_netem_xstats via TCA_STATS_APP with
per-impairment counters: delayed, loss, corrupted, duplicated,
reordered, and ecn_marked.

Add netem_print_xstats() following the same pattern as
fq_print_xstats()

Example output of `tc -s qdisc show dev eth0`:
  qdisc netem 8001: root refcnt 2 limit 1000 delay 100ms loss 5%
   Sent 1234567 bytes 15483 pkt (dropped 774, overlimits 0 requeues 0)
   delayed 14709 dropped 774 corrupted 154 duplicated 309 reordered 61 ecn_marked 0

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Signed-off-by: David Ahern <dsahern@kernel.org>
7 weeks agonetshaper: Fix man page accuracy and formatting issues
Mohsin Bashir [Fri, 22 May 2026 03:07:02 +0000 (20:07 -0700)] 
netshaper: Fix man page accuracy and formatting issues

This is a follow up to a previous patch that was merged before the
feedback was provided. See link below for previous patch series.
https://lore.kernel.org/netdev/20260518202353.390827-1-mohsin.bashr@gmail.com

Address the following concerns:

- Document that parent scope must be node or netdev; queue is
  rejected by parse_scope_id() but the man page did not state this.

- Document that parent scope node requires an id, while parent scope
  netdev may omit the id.

- Document that leaf scope must be queue; parse_leaves() enforces
  this but the man page only implied it by example.

- Replace "scheduling groups" with "intermediate scheduling nodes"
  for the node scope to avoid confusion with the group command name.

- Show group handle scope choices explicitly in the synopsis as
  { node | netdev } instead of an unrestricted HANDLE_SCOPE token.

- Replace unusual { } repeat-group notation for leaves with a
  separate LEAF_SPEC definition using standard [ SPEC ... ] syntax.

- Use .B/.RB for literal keywords (bw-min, bw-max, weight, id,
  parent, leaves) and .I for metavariables, matching iproute2
  man page conventions.

- Clarify example 4 so the 10 Gbit/s cap clearly applies to the
  node, not the netdev parent.

- Update .TH date.

Assisted-by: Claude:claude-opus-4.7
Signed-off-by: Mohsin Bashir <hmohsin@meta.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
7 weeks agoMerge branch 'netshaper-updates' into next
David Ahern [Wed, 20 May 2026 01:06:02 +0000 (19:06 -0600)] 
Merge branch 'netshaper-updates' into next

Mohsin Bashir  says:

====================

From: Mohsin Bashir <hmohsin@meta.com>

This series extends the netshaper CLI with missing parameter support
and adds the group command for building scheduling hierarchies.

The existing netshaper tool only supports setting bw-max on individual
shapers. This series adds the remaining shaper attributes (bw-min,
weight) needed for TX scheduling, and introduces the group command
which ties leaf shapers to a parent node in a single operation.

====================

Signed-off-by: David Ahern <dsahern@kernel.org>
7 weeks agonetshaper: Update man page for new parameters and group command
Mohsin Bashir [Mon, 18 May 2026 20:23:53 +0000 (13:23 -0700)] 
netshaper: Update man page for new parameters and group command

Document bw-min, weight, and the group command in the netshaper
man page. Node id is required for set/show/delete but optional
for the group command. Leaves support optional per-queue weight
and priority parameters for scheduling within the group.

Assisted-by: Claude:claude-opus-4.7
Signed-off-by: Mohsin Bashir <hmohsin@meta.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
7 weeks agonetshaper: Add group command for creating scheduling hierarchies
Mohsin Bashir [Mon, 18 May 2026 20:23:52 +0000 (13:23 -0700)] 
netshaper: Add group command for creating scheduling hierarchies

Add the group command to create and update scheduling groups via the
NET_SHAPER_CMD_GROUP netlink operation. This enables building shaper
hierarchies by specifying a node handle, parent scope, rate parameters,
and a set of leaf shapers to attach.

The group command allows the node handle id to be omitted, letting
the kernel auto-assign one for new nodes. Group handle and parent
scopes are validated to accept only node or netdev. Parent node scope
requires an explicit id since it must reference an existing node.

Leaf parsing is extracted into parse_leaves() which dynamically
allocates the leaves array via realloc, avoiding arbitrary limits.
Each leaf accepts optional weight and priority parameters for
per-queue scheduling control within the group. Handle and parent
parsing share parse_scope_id() to avoid code duplication. Common
argument parsing (dev, bw-min, bw-max, weight) reuses the
parse_shaper_arg() helper introduced in the previous patch.

Example usage:
  netshaper group dev foo handle scope node parent scope netdev \
      bw-max 1gbit leaves scope queue id 0 weight 3 \
      scope queue id 1 weight 2

Assisted-by: Claude:claude-opus-4.7
Signed-off-by: Mohsin Bashir <hmohsin@meta.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
7 weeks agonetshaper: Extract struct shaper_args and parse_shaper_arg() helper
Mohsin Bashir [Mon, 18 May 2026 20:23:51 +0000 (13:23 -0700)] 
netshaper: Extract struct shaper_args and parse_shaper_arg() helper

Extract common shaper parameters (dev, bw-min, bw-max, weight) into
struct shaper_args and add parse_shaper_arg() to parse them. This
avoids duplicating argument parsing when the group command is added
in the next patch.

Assisted-by: Claude:claude-opus-4.7
Signed-off-by: Mohsin Bashir <hmohsin@meta.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
7 weeks agonetshaper: Extend show output with parent, bw-min and weight
Mohsin Bashir [Mon, 18 May 2026 20:23:50 +0000 (13:23 -0700)] 
netshaper: Extend show output with parent, bw-min and weight

Extend print_netshaper_attrs() to display parent scope/id, bw-min,
and weight fields in the show output. Replace the switch-based
iteration with direct attribute checks for cleaner output formatting.
Use print_rate() for bandwidth display so that sub-Mbps rates
like 100kbit render correctly instead of truncating to 0 mbps.

Assisted-by: Claude:claude-opus-4.7
Signed-off-by: Mohsin Bashir <hmohsin@meta.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
7 weeks agonetshaper: Add bw-min and weight parameter support
Mohsin Bashir [Mon, 18 May 2026 20:23:49 +0000 (13:23 -0700)] 
netshaper: Add bw-min and weight parameter support

Add bw-min and weight parameters to the set command. Previously
only bw-max was supported. Use boolean flags (has_bw_min,
has_bw_max, has_weight) to track which parameters were provided,
so that zero-valued attrs like bw-max 0 are correctly sent.
Only emit rate and weight attrs for the set command. Add device
name validation and only send handle id when explicitly provided.
Update usage text to reflect the new parameters.

Assisted-by: Claude:claude-opus-4.7
Signed-off-by: Mohsin Bashir <hmohsin@meta.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
7 weeks agonetshaper: Extract parse_scope() and parse_rate() helpers
Mohsin Bashir [Mon, 18 May 2026 20:23:48 +0000 (13:23 -0700)] 
netshaper: Extract parse_scope() and parse_rate() helpers

Add parse_scope() and parse_rate() helpers in preparation for
adding the group command which will need scope and rate parsing
at various places in the code. This patch will help to avoid
code duplication.

Verify that the tool works as before:
./netshaper set dev eth2 handle scope queue id 0 bw-max 100kbit
./netshaper delete dev eth2 handle scope queue id 0 bw-max 100kbit

Assisted-by: Claude:claude-opus-4.7
Signed-off-by: Mohsin Bashir <hmohsin@meta.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
7 weeks agoMerge branch 'neigh-fwd-grat' into next
David Ahern [Wed, 20 May 2026 00:44:24 +0000 (18:44 -0600)] 
Merge branch 'neigh-fwd-grat' into next

Danielle Ratson  says:

====================

The existing neighbor suppression unconditionally suppresses gratuitous
ARP and unsolicited Neighbor Advertisements, which breaks legitimate use
cases like Multi-Homing and EVPN where these announcements need to
propagate across the VXLAN fabric.

This series adds a new neigh_forward_grat option that provides
independent control of gratuitous ARP and unsolicited NA forwarding.
When neigh_suppress is enabled and neigh_forward_grat is also enabled,
regular neighbor discovery is suppressed while gratuitous announcements
are forwarded.

Both port-level control (via IFLA_BRPORT_NEIGH_FORWARD_GRAT) and
per-VLAN control (via BRIDGE_VLANDB_ENTRY_NEIGH_FORWARD_GRAT) are
provided. The default value of OFF preserves existing behavior.

The new attributes use NLA_U8, although the kernel netlink guideline
recommends NLA_U32 as the minimum integer type on the grounds that
alignment makes smaller types equivalent on the wire. For a simple
on/off attribute there is no technical advantage to u32 over u8, and
keeping u8 preserves consistency with all surrounding bridge port
attributes and avoids introducing new helpers alongside the existing
infrastructure.

====================

Signed-off-by: David Ahern <dsahern@kernel.org>
7 weeks agobridge: vlan: Add support for neigh_forward_grat
Danielle Ratson [Sun, 17 May 2026 08:25:01 +0000 (11:25 +0300)] 
bridge: vlan: Add support for neigh_forward_grat

Add support for controlling gratuitous ARP and unsolicited NA
forwarding at the per-VLAN level via the neigh_forward_grat option.

This allows configuring the option via:
$ bridge vlan set dev <port> vid <vlan> neigh_forward_grat {on|off}

Reviewed-by: Ido Schimmel <idosch@nvidia.com>
Reviewed-by: Petr Machata <petrm@nvidia.com>
Signed-off-by: Danielle Ratson <danieller@nvidia.com>
Acked-by: Nikolay Aleksandrov <razor@blackwall.org>
Signed-off-by: David Ahern <dsahern@kernel.org>
7 weeks agoiplink: bridge_slave: Add support for neigh_forward_grat
Danielle Ratson [Sun, 17 May 2026 08:25:00 +0000 (11:25 +0300)] 
iplink: bridge_slave: Add support for neigh_forward_grat

Add support for controlling gratuitous ARP and unsolicited NA
forwarding at the port level via the neigh_forward_grat option.

This allows configuring the option via:
$ ip link set dev <port> type bridge_slave neigh_forward_grat {on|off}

Or via the bridge command:
$ bridge link set dev <port> neigh_forward_grat {on|off}

Reviewed-by: Ido Schimmel <idosch@nvidia.com>
Reviewed-by: Petr Machata <petrm@nvidia.com>
Signed-off-by: Danielle Ratson <danieller@nvidia.com>
Acked-by: Nikolay Aleksandrov <razor@blackwall.org>
Signed-off-by: David Ahern <dsahern@kernel.org>
7 weeks agoMerge remote-tracking branch 'main/main' into next
David Ahern [Wed, 20 May 2026 00:38:59 +0000 (18:38 -0600)] 
Merge remote-tracking branch 'main/main' into next

Conflicts:
man/man8/dpll.8

Signed-off-by: David Ahern <dsahern@kernel.org>
7 weeks agodpll: align help and man notation with actual option parsing
Petr Oros [Tue, 12 May 2026 13:52:24 +0000 (15:52 +0200)] 
dpll: align help and man notation with actual option parsing

dpll uses getopt_long(), which only accepts long options with the
"--" prefix.  The iproute2-wide "-X[name]" shorthand used in the
help text and man page implies a single-dash long form
(e.g. -Version, -json, -pretty) that getopt_long does not parse;
only -V/--Version, -j/--json and -p/--pretty actually work.

Replace the misleading shorthand with explicit "-V | --Version"
style so the documented forms match what the parser accepts, and
drop the redundant second usage line in help() that listed only a
subset of the options and implied dpll could be invoked without an
OBJECT.  No functional change.

Signed-off-by: Petr Oros <poros@redhat.com>
Reviewed-by: Ivan Vecera <ivecera@redhat.com>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
8 weeks agodevlink: Drop now duplicate pid fallback for netns
David Ahern [Tue, 12 May 2026 19:29:33 +0000 (13:29 -0600)] 
devlink: Drop now duplicate pid fallback for netns

Now that netns_get_fd handles by name and pid, the special
handling in devlink to fallback to PID can be removed with
both cases handled by the FD attribute.

Signed-off-by: David Ahern <dahern@nvidia.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
8 weeks agordma: Allow netns to be specified by pid
David Ahern [Tue, 12 May 2026 19:27:41 +0000 (13:27 -0600)] 
rdma: Allow netns to be specified by pid

Update rdma dev to work like ip link where the netns can be a
name or a pid by using netns_get_fd. Update man page and help
accordingly.

Signed-off-by: David Ahern <dahern@nvidia.com>
Reviewed-by: Leon Romanovsky <leonro@nvidia.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
8 weeks agoiplink: Drop pid fallback code for netns
David Ahern [Tue, 12 May 2026 19:26:19 +0000 (13:26 -0600)] 
iplink: Drop pid fallback code for netns

Prior commit handles the fallback to pid, so remove
the now duplicate code from iplink_parse.

Signed-off-by: David Ahern <dahern@nvidia.com>
Reviewed-by: Leon Romanovsky <leonro@nvidia.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
8 weeks agonamespace: Add fallback to netns by pid
David Ahern [Tue, 12 May 2026 19:26:03 +0000 (13:26 -0600)] 
namespace: Add fallback to netns by pid

Update netns_get_fd to try the passed in string as a name first. If the
netns filesystem entry does not exist, try converting the string to an
integer and if successful return an fd to /proc/<pid>/ns/net.

This allows netns_get_fd to uniformly handle the 2 common use cases of
specifying network namespace by name and pid.

Signed-off-by: David Ahern <dahern@nvidia.com>
Reviewed-by: Leon Romanovsky <leonro@nvidia.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
8 weeks agodpll: add fractional-frequency-offset to parent-device
Ivan Vecera [Wed, 13 May 2026 14:51:15 +0000 (16:51 +0200)] 
dpll: add fractional-frequency-offset to parent-device

Kernel commit 9c11fcb2e9a54 ("dpll: add fractional frequency offset
to pin-parent-device") added fractional-frequency-offset (PPM) and
fractional-frequency-offset-ppt (PPT) attributes to the
pin-parent-device nested attribute set, alongside the existing
top-level pin attributes. Add their display into
dpll_pin_print_parent_devices() and add ppm and ppt units to the
respective outputs.

Extract dpll_pr_ffo() helper to consolidate the duplicated PPM/PPT
fallback logic used in both top-level and parent-device contexts.

Signed-off-by: Ivan Vecera <ivecera@redhat.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
8 weeks agodpll: add pin operstate attribute support
Ivan Vecera [Wed, 13 May 2026 14:51:14 +0000 (16:51 +0200)] 
dpll: add pin operstate attribute support

Kernel commit 781c8893a5da8 ("dpll: add pin operational state")
added the DPLL_A_PIN_OPERSTATE attribute which reports the operational
state of a pin with respect to its parent DPLL device. The attribute
is nested inside parent-device and can have values: active, standby,
no-signal, qual-failed.

Add operstate filtering for pin show command, allowing to filter pins
by their operational state on parent device. Update bash-completion
and man page accordingly.

Signed-off-by: Ivan Vecera <ivecera@redhat.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
8 weeks agoUpdate kernel headers
David Ahern [Fri, 15 May 2026 19:20:51 +0000 (13:20 -0600)] 
Update kernel headers

Update kernel headers to commit:
822d4a8e390a: ("net: usb: usbnet: use proper ep number macros")

Signed-off-by: David Ahern <dsahern@kernel.org>
2 months agordma: Align FRMR pool UAPI names with merged kernel UAPI
Michael Guralnik [Thu, 7 May 2026 18:46:09 +0000 (21:46 +0300)] 
rdma: Align FRMR pool UAPI names with merged kernel UAPI

The FRMR pools UAPI merged in kernel v7.0-rc1 commit dbd0472fd7a5
("RDMA/nldev: Expose kernel-internal FRMR pools in netlink")
uses different identifier names than what the iproute2 FRMR pools
series was developed against.

Update the vendored copy of RDMA UAPI and all references in the rdma
tool to match the names that actually shipped in the kernel.

Fixes: 93368ee34528 ("rdma: Update headers")
Signed-off-by: Michael Guralnik <michaelgur@nvidia.com>
Signed-off-by: Chiara Meiohas <cmeiohas@nvidia.com>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2 months agoMerge branch 'dpll-phase-unit-freq-monitor' into next
David Ahern [Thu, 7 May 2026 15:24:02 +0000 (09:24 -0600)] 
Merge branch 'dpll-phase-unit-freq-monitor' into next

Ivan Vecera  says:

====================

This series improves dpll pin output formatting and adds support for
the frequency monitoring feature.

Patch 1 adds picosecond unit to phase-adjust-min, phase-adjust-max
and phase-adjust attributes. It also introduces dpll_pr_phase_offset()
helper that properly formats phase-offset as fractional picoseconds by
dividing the raw kernel value by DPLL_PHASE_OFFSET_DIVIDER.

Patch 2 adds support for the new frequency monitoring feature including
the DPLL_A_FREQUENCY_MONITOR device attribute and
DPLL_A_PIN_MEASURED_FREQUENCY pin attribute. The measured frequency is
displayed as fractional Hz using dpll_pr_measured_frequency() helper
since the kernel reports the value in millihertz. It also refactors
phase-offset-monitor parsing into a shared helper.

Tested on EDS2 development board with zl3073x DPLL:

  # dpll pin show package-label REF0P
  pin id 196:
    module-name: zl3073x
    clock-id: 13709406750444215013
    board-label: SyncE IN M1 CLK1
    package-label: REF0P
    type: synce-eth-port
    frequency: 125000000 Hz
    measured-frequency: 124999326.000 Hz
    frequency-supported:
      2500000 Hz
      25000000 Hz
      125000000 Hz
    capabilities: 0x6 state-can-change priority-can-change
    phase-adjust-min: -2147483648 ps
    phase-adjust-max: 2147483647 ps
    phase-adjust: 0 ps
    parent-device:
      id 14 direction input prio 10 state selectable phase-offset 0.000 ps
      id 15 direction input prio 0 state connected phase-offset 323.000 ps

====================

Signed-off-by: David Ahern <dsahern@kernel.org>
2 months agodpll: add frequency monitoring support
Ivan Vecera [Mon, 4 May 2026 16:30:14 +0000 (18:30 +0200)] 
dpll: add frequency monitoring support

Add support for the new frequency monitoring feature from the kernel
patch series "dpll: add actual frequency monitoring feature". This
includes:

- DPLL_A_FREQUENCY_MONITOR device attribute (enable/disable)
- DPLL_A_PIN_MEASURED_FREQUENCY pin attribute displayed as fractional Hz
  using DPLL_PR_MEASURED_FREQUENCY macro (kernel reports in mHz)
- device set: frequency-monitor { enable | disable }
- Refactor phase-offset-monitor to use new dpll_parse_attr_feature_state
  helper shared with frequency-monitor
- Update man page and bash-completion

Reviewed-by: Petr Oros <poros@redhat.com>
Signed-off-by: Ivan Vecera <ivecera@redhat.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
2 months agodpll: add ps unit to phase-related pin attributes
Ivan Vecera [Mon, 4 May 2026 16:30:13 +0000 (18:30 +0200)] 
dpll: add ps unit to phase-related pin attributes

Display phase-adjust-min, phase-adjust-max and phase-adjust values
with ps unit. Add DPLL_PR_PHASE_OFFSET macro that properly formats
phase-offset as fractional picoseconds by dividing the raw kernel
value by DPLL_PHASE_OFFSET_DIVIDER.

Reviewed-by: Petr Oros <poros@redhat.com>
Signed-off-by: Ivan Vecera <ivecera@redhat.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
2 months agotc/class: use rtnl_dump_request_n() in tc_class_list()
Eric Dumazet [Wed, 6 May 2026 16:06:56 +0000 (16:06 +0000)] 
tc/class: use rtnl_dump_request_n() in tc_class_list()

strace tc -s class sh dev eth1 parent 2:

strace is fooled with rtnl_dump_request() way:

sendmsg(3, {msg_name={sa_family=AF_NETLINK, nl_pid=0, nl_groups=00000000},
        msg_namelen=12,
msg_iov=[{iov_base={nlmsg_len=36,
nlmsg_type=RTM_GETTCLASS,
nlmsg_flags=NLM_F_REQUEST|NLM_F_DUMP,
nlmsg_seq=1778082626, nlmsg_pid=0},
iov_len=16},
{iov_base={nlmsg_len=0, nlmsg_type=NLMSG_NOOP, nlmsg_flags=0, nlmsg_seq=0, nlmsg_pid=131072},
        iov_len=20}],
msg_iovlen=2, msg_controllen=0, msg_flags=0}, 0) = 36

With rtnl_dump_request_n() we get instead:

sendmsg(3, {msg_name={sa_family=AF_NETLINK, nl_pid=0, nl_groups=00000000},
msg_namelen=12,
msg_iov=[{iov_base=[{nlmsg_len=36,
nlmsg_type=RTM_GETTCLASS,
nlmsg_flags=NLM_F_REQUEST|NLM_F_DUMP,
nlmsg_seq=1778082790, nlmsg_pid=0},
{tcm_family=AF_UNSPEC,
 tcm_ifindex=if_nametoindex("eth1"), tcm_handle=0, tcm_parent=131072, tcm_info=0}],
iov_len=36}], msg_iovlen=1, msg_controllen=0, msg_flags=0}, 0) = 36

This will also permit future attribute additions, like skip stats.

Signed-off-by: Eric Dumazet <edumazet@google.com>
Acked-by: Jamal Hadi Salim <jhs@mojatatu.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
2 months agodpll: fix man page correctness issues
Ivan Vecera [Sun, 3 May 2026 16:42:00 +0000 (18:42 +0200)] 
dpll: fix man page correctness issues

Fix several inaccuracies in dpll.8 man page:
- Remove bogus "holdover" and "freerun" from operating modes list,
  only "manual" and "automatic" modes exist in the DPLL API
- Fix typo "locked-ho-ack" -> "locked-ho-acq" in lock status list
- Add missing device show output fields: lock-status-error,
  clock-quality-level, mode-supported, phase-offset-monitor and
  phase-offset-avg-factor
- Add missing pin show output fields: panel-label, package-label,
  fractional-frequency-offset and esync-pulse
- Remove non-existent exit codes 2 and 255, the tool only returns
  0 (success) or 1 (failure)
- Use canonical enable/disable for phase-offset-monitor to match
  the tool's help text

Fixes: 656cfc3ce05b ("dpll: Add dpll command")
Signed-off-by: Ivan Vecera <ivecera@redhat.com>
Reviewed-by: Vadim Fedorenko <vadim.fedorenko@linux.dev>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2 months agotc: qdisc: provide tcm_handle and tcm_parent to kernel dump requests
Eric Dumazet [Sun, 3 May 2026 11:51:37 +0000 (11:51 +0000)] 
tc: qdisc: provide tcm_handle and tcm_parent to kernel dump requests

linux-7.2 can filter "tc qdisc show ..." on tcm_handle / tcm_parent and
reduce dump costs.

Old kernels ignore these values.

Signed-off-by: Eric Dumazet <edumazet@google.com>
Acked-by: Jamal Hadi Salim <jhs@mojatatu.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
2 months agotc: use ll_init_map() only when needed
Eric Dumazet [Tue, 28 Apr 2026 08:28:51 +0000 (08:28 +0000)] 
tc: use ll_init_map() only when needed

Some setups can have thousands of devices.

ll_init_map() is rather expensive for them.

Only call ll_init_map() in the following cases:

1) tc runs in batch mode.
2) tc runs in monitor mode.
3) tc dumps qdiscs/classes/filters for all netdev.

This greatly reduces RTNL pressure on common operations.

Signed-off-by: Eric Dumazet <edumazet@google.com>
Acked-by: Jamal Hadi Salim <jhs@mojatatu.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
2 months agolib: add input validation for time, rate, and size parsing functions
Stephen Hemminger [Tue, 21 Apr 2026 20:23:59 +0000 (13:23 -0700)] 
lib: add input validation for time, rate, and size parsing functions

The parsing functions get_time(), get_time64(), get_rate(), get_rate64(),
and get_size64() use strtod() to convert user input but don't validate
the parsed values. This allows negative numbers and overflow values to
be passed through, which can cause unexpected behavior or security issues
when these values reach the kernel as unsigned integers.

Add validation to reject:
- Negative values (which make no sense for time, rate, or size)
- Overflow conditions (when strtod() returns HUGE_VAL with ERANGE)
- Empty strings (already checked, but now with explicit comments)

This prevents potential issues and provides clearer error reporting.
Fixing it in iproute2 does not mean that the kernel is off the hook
for handling negative values. Checks are still needed.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Signed-off-by: David Ahern <dsahern@kernel.org>
2 months agoman: remove libnetlink man page
Stephen Hemminger [Mon, 27 Apr 2026 17:28:27 +0000 (10:28 -0700)] 
man: remove libnetlink man page

The iproute2 libnetlink is not a public and stable API.
Having a man page encourages users to think it is available.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Signed-off-by: David Ahern <dsahern@kernel.org>
2 months agobash-completion: devlink: Fix dev completion trailing colon
Danielle Ratson [Sun, 26 Apr 2026 11:51:39 +0000 (14:51 +0300)] 
bash-completion: devlink: Fix dev completion trailing colon

Cited commit extended 'devlink dev show' to print the instance index when
the kernel provides DEVLINK_ATTR_INDEX, printing the device handle followed
by a colon and the index. The completion code was using the raw text output
as a word list, causing the device handle to be offered with a trailing
colon, e.g. "pci/0000:01:00.0:" instead of "pci/0000:01:00.0".

Switch to JSON output and extract device names using jq, consistent
with how port completion already works, to reliably get only the device
handle names regardless of what additional attributes are printed.

Fixes: 36252727bfc6 ("devlink: show devlink instance index in dev output")
Signed-off-by: Danielle Ratson <danieller@nvidia.com>
Reviewed-by: Ido Schimmel <idosch@nvidia.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
2 months agoll_map: add RTEXT_FILTER_SKIP_STATS to ll_init_map()
Eric Dumazet [Tue, 28 Apr 2026 07:56:47 +0000 (07:56 +0000)] 
ll_map: add RTEXT_FILTER_SKIP_STATS to ll_init_map()

ll_init_map() only cares about names and ifindex.

We can save ~300 bytes per device if we ask the kernel to skip stats,
not counting many cpu cycles if per-cpu stats are involved.

Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
2 months agoMerge remote-tracking branch 'main/main' into next
David Ahern [Thu, 30 Apr 2026 15:32:18 +0000 (09:32 -0600)] 
Merge remote-tracking branch 'main/main' into next

Signed-off-by: David Ahern <dsahern@kernel.org>
2 months agolibnetlink: flush stdout only in monitor mode
Stephen Hemminger [Mon, 27 Apr 2026 16:26:58 +0000 (09:26 -0700)] 
libnetlink: flush stdout only in monitor mode

As Eric pointed out, fflush() only makes sense in monitor mode.
In other modes buffering the output helps with large outputs
like route dumps.

Move the fflush() into rtnl_listen() which is the common code
used by all monitoring subcommands. This also ensures any future
monitor subcommand gets correct flushing behavior automatically.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2 months agoremove hamradio protocols
Stephen Hemminger [Fri, 24 Apr 2026 23:22:57 +0000 (16:22 -0700)] 
remove hamradio protocols

The ax25, rose, and netrom have been removed upstream.
Drop support for those protocols from iproute2.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2 months agouapi: update to 7.1-rc1
Stephen Hemminger [Mon, 27 Apr 2026 17:49:17 +0000 (10:49 -0700)] 
uapi: update to 7.1-rc1

Update headers from rc1

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2 months agoMerge remote-tracking branch 'main/main' into next
David Ahern [Thu, 16 Apr 2026 01:13:12 +0000 (19:13 -0600)] 
Merge remote-tracking branch 'main/main' into next

Signed-off-by: David Ahern <dsahern@kernel.org>
2 months agoss: force a flush in monitor mode
Eric Dumazet [Wed, 15 Apr 2026 13:03:07 +0000 (13:03 +0000)] 
ss: force a flush in monitor mode

Call fflush() from generic_show_sock() in order to work
with pipes and redirects.

After this patch, "ss -E &>log_file" works as expected.

Signed-off-by: Eric Dumazet <edumazet@google.com>
2 months agov7.0.0 v7.0.0
Stephen Hemminger [Mon, 13 Apr 2026 19:02:03 +0000 (12:02 -0700)] 
v7.0.0

3 months agojson_writer: fix builtin test code
Stephen Hemminger [Fri, 10 Apr 2026 22:46:27 +0000 (15:46 -0700)] 
json_writer: fix builtin test code

The code under #ifdef was not generating valid JSON
and it is missing test for control characters.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
3 months agojson_writer: support control character escaping
Stephen Hemminger [Fri, 10 Apr 2026 22:38:36 +0000 (15:38 -0700)] 
json_writer: support control character escaping

Iproute2 never handled control characters in strings correctly.
There are some cases like where string is under user control
like paths in ss command. Make iproute2 json output conform
to RFC 8259.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
3 months agoman8: update seg6 encap documentation
Justin Iurman [Fri, 20 Mar 2026 14:08:47 +0000 (15:08 +0100)] 
man8: update seg6 encap documentation

Include "tunsrc" in the man page.

Signed-off-by: Justin Iurman <justin.iurman@6wind.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
3 months agoseg6: add tunsrc support in iproute_lwtunnel
Justin Iurman [Fri, 20 Mar 2026 14:08:46 +0000 (15:08 +0100)] 
seg6: add tunsrc support in iproute_lwtunnel

Add support for the new optional "tunsrc" parameter. Now, a tunnel
source address can be configured per route and has priority over the
configured per-netns source address (if any).

Example:
ip -6 r a 2001:db8:1::/64 encap seg6 mode encap tunsrc 2001:db8:ab::
    segs 2001:db8:42::1,2001:db8:ffff::2 dev eth0

Signed-off-by: Justin Iurman <justin.iurman@6wind.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
3 months agodpll: Send object per event in JSON monitor mode
Vitaly Grinberg [Sun, 29 Mar 2026 07:51:01 +0000 (10:51 +0300)] 
dpll: Send object per event in JSON monitor mode

Previously, monitor mode wrapped all events in a single JSON array
inside a top-level object, which made piping the output to external
tools (such as `jq`) impossible.
Send a separate JSON object for each event in monitor mode,
making the output suitable for line-by-line consumers. Skip the
global JSON wrapper for monitor mode.

Signed-off-by: Vitaly Grinberg <vgrinber@redhat.com>
Reviewed-by: Petr Oros <poros@redhat.com>
Reviewed-by: Ivan Vecera <ivecera@redhat.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
3 months agoMerge branch 'frmr-pools' into next
David Ahern [Sun, 5 Apr 2026 17:07:21 +0000 (11:07 -0600)] 
Merge branch 'frmr-pools' into next

Chiara Meiohas  says:

====================

This series adds support for managing Fast Registration Memory Region
(FRMR) pools in rdma tool, enabling users to monitor and configure FRMR
pool behavior.

FRMR pools are used to cache and reuse Fast Registration Memory Region
handles to improve performance by avoiding the overhead of repeated
memory region creation and destruction. This series introduces commands
to view FRMR pool statistics and configure pool parameters such as
aging time and pinned handle count.

The 'show' command allows users to display FRMR pools created on
devices, their properties, and usage statistics. Each pool is identified
by a unique key (hex-encoded properties) for easy reference in
subsequent operations.

The aging 'set' command allows users to modify the aging time parameter,
which controls how long unused FRMR handles remain in the pool before
being released.

The pinned 'set' command allows users to configure the number of pinned
handles in a pool. Pinned handles are exempt from aging and remain
permanently available for reuse, which is useful for workloads with
predictable memory region usage patterns.

Command usage and examples are included in the commits and man pages.

These patches are complimentary to the kernel patches:
https://lore.kernel.org/linux-rdma/20260226-frmr_pools-v4-0-95360b54f15e@nvidia.com/

====================

Signed-off-by: David Ahern <dsahern@kernel.org>
3 months agordma: Add FRMR pools set pinned command
Michael Guralnik [Mon, 30 Mar 2026 17:31:18 +0000 (20:31 +0300)] 
rdma: Add FRMR pools set pinned command

Add an option to set the amount of pinned handles to FRMR pool.
Pinned handles are not affected by aging and stay available for reuse in
the FRMR pool.

The pool is identified by a colon-separated key of hexadecimal fields
(vendor_key:num_dma_blocks:access_flags:ats) as shown in the 'show'
command output.

Usage:
  Set 250 pinned handles to FRMR pool with key 0:800:0:0 on
  device rocep8s0f0
  $rdma resource set frmr_pools dev rocep8s0f0 pinned 0:800:0:0 250

Signed-off-by: Michael Guralnik <michaelgur@nvidia.com>
Reviewed-by: Patrisious Haddad <phaddad@nvidia.com>
Reviewed-by: Chiara Meiohas <cmeiohas@nvidia.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
3 months agordma: Add FRMR pools set aging command
Michael Guralnik [Mon, 30 Mar 2026 17:31:17 +0000 (20:31 +0300)] 
rdma: Add FRMR pools set aging command

Add support for configuring the aging period of FRMR pools.
The aging mechanism frees unused FRMR handles that have not been
in use for the specified period.

Usage:
  rdma resource set frmr_pools dev DEV aging AGING_PERIOD

Signed-off-by: Michael Guralnik <michaelgur@nvidia.com>
Reviewed-by: Patrisious Haddad <phaddad@nvidia.com>
Reviewed-by: Chiara Meiohas <cmeiohas@nvidia.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
3 months agordma: Add resource FRMR pools show command
Michael Guralnik [Mon, 30 Mar 2026 17:31:16 +0000 (20:31 +0300)] 
rdma: Add resource FRMR pools show command

Allow users to see the FRMR pools that were created on the devices,
their properties and their usage statistics.
The set of properties of each pool are encoded as a colon-separated
list of hexadecimal fields (vendor_key:num_dma_blocks:access_flags:ats)
to simplify referencing a specific pool in 'set' commands.

Sample output:

$rdma resource show frmr_pools
dev rocep8s0f0 key 0:1000:0:0 queue 0 in_use 0 max_in_use 200
dev rocep8s0f0 key 0:800:0:0 queue 0 in_use 0 max_in_use 200
dev rocep8s0f0 key 0:400:0:0 queue 0 in_use 0 max_in_use 200

$rdma resource show frmr_pools -d
dev rocep8s0f0 key 0:1000:0:0 ats 0 access_flags 0 vendor_key 0 num_dma_blocks 4096 queue 0 in_use 0 max_in_use 200
dev rocep8s0f0 key 0:800:0:0 ats 0 access_flags 0 vendor_key 0 num_dma_blocks 2048 queue 0 in_use 0 max_in_use 200
dev rocep8s0f0 key 0:400:0:0 ats 0 access_flags 0 vendor_key 0 num_dma_blocks 1024 queue 0 in_use 0 max_in_use 200

$rdma resource show frmr_pools num_dma_blocks 2048
dev rocep8s0f0 key 0:800:0:0 queue 0 in_use 0 max_in_use 200

Signed-off-by: Michael Guralnik <michaelgur@nvidia.com>
Reviewed-by: Patrisious Haddad <phaddad@nvidia.com>
Reviewed-by: Chiara Meiohas <cmeiohas@nvidia.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
3 months agordma: Update headers
Michael Guralnik [Mon, 30 Mar 2026 17:31:15 +0000 (20:31 +0300)] 
rdma: Update headers

Update rdma_netlink.h file up to kernel commit dbd0472fd7a5
("RDMA/nldev: Expose kernel-internal FRMR pools in netlink")

Signed-off-by: Michael Guralnik <michaelgur@nvidia.com>
Reviewed-by: Patrisious Haddad <phaddad@nvidia.com>
Reviewed-by: Chiara Meiohas <cmeiohas@nvidia.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
3 months agoUpdate kernel headers
David Ahern [Sun, 5 Apr 2026 16:34:21 +0000 (10:34 -0600)] 
Update kernel headers

Update kernel headers to commit:
3741f8fa004b: ("Merge branch 'dpll-add-frequency-monitoring-feature'")

Signed-off-by: David Ahern <dsahern@kernel.org>
3 months agoMerge branch 'tc-64b-burst' into next
David Ahern [Sun, 5 Apr 2026 16:32:35 +0000 (10:32 -0600)] 
Merge branch 'tc-64b-burst' into next

Ioana Lazea  says:

====================

        This patchset updates the TBF and HTB queuing discipline
configurations to support burst sizes beyond the legacy 32-bit limits.
As network interface speeds increase, the kernel’s internal
representation of burst (calculated as time at a specific rate) can
easily exceed the 4 GB threshold. These changes enable userspace to
accommodate these larger values where the kernel API allows.

        Additionally, if the burst exceeds the upper limit supported by
the kernel API, it is now reported as an error in userspace before
attempting the Netlink transition. Previously, such values would
silently overflow, causing corrupted values to be passed to the kernel.

        The implementation follows the approach used for tc police burst
handling introduced in commit 3b26e8abf404 ("tc/police: enable use of 64
bit burst parameter"). The reasoning behind the patches proposed here is
largely based on the rationale described in the aforementioned change.

        Similarly to the case of the tc police burst option, as
implemented now the TBF and HTB burst option limit the sizes of the
burst up to 4 GB (UINT_MAX for a 32 bit unsigned int) due to the
constraints in the user space tooling. Historically, TBF and HTB burst
options were capped at 32 bits, which was a sufficient limit for the
lower line rates common when they were initially developed. However,
since the underlying kernel logic treats the burst as a time-based
value, it is already capable of handling larger sizes at high rates
without requiring internal modifications. This patchset bridges that gap
in the user space tools.

        The detailed technical explanation for this change was
previously detailed by Jay Vosburgh:

Link: https://lore.kernel.org/netdev/20250916215731.3431465-1-jay.vosburgh@canonical.com/
        To summarize the details at the link, the burst size is limited
by the kernel to approximately 274 seconds at the specified rate, and
has no inherent 4 GB limit.

        Below is a short description of the main changes made to the TBF
and HTB queuing disciplines.

        In both TBF and HTB, the primary modification replaces the
unsigned integer burst variable with an unsigned 64 bit integer variable
(buffer64) so that burst sizes larger than 4 GB can be represented and
passed correctly through the kernel API.

        For the TBF qdisc specifically, the following logic was added:

if (buffer64 < (1ULL << 32)) {
        __u32 buffer32 = (__u32)buffer64;

        addattr_l(n, 2124, TCA_TBF_BURST, &buffer32, sizeof(buffer32));
}

        Increasing the burst size representation to 64 bits introduces
an issue with TCA_TBF_BURST. The kernel expects this attribute as
NLA_U32 (a 32-bit unsigned value), while the updated implementation may
produce burst values exceeding this range. Passing such values would
cause the tbf_policy validation in the kernel to fail. To avoid this,
TCA_TBF_BURST is only included when the value fits within 32 bits. When
the attribute is omitted (for example, when buffer64 exceeds the 32-bit
limit), the kernel falls back to using the value stored in qopt->buffer,
which already supports larger burst sizes.
        As seen in commit 2e04ad424b03 ("sch_tbf: add
TBF_BURST/TBF_PBURST attribute"), TCA_TBF_BURST was originally
introduced to handle issues with very small burst values. Omitting the
attribute for large bursts therefore preserves the intended behavior
while avoiding incompatibilities with the kernel attribute policy.
Additionally, the burst value is explicitly cast to 32 bits where
required, ensuring that 64-bit values are not passed to kernel
interfaces expecting 32-bit fields.

        These modifications bring the user space tools in line with the
kernel's internal 64-bit handling. The logic effectively avoids Netlink
attribute validation failures while preserving the original intent of
the burst mechanism for small values.

====================

Signed-off-by: David Ahern <dsahern@kernel.org>
3 months agotc/htb: enable use of 64 bit burst
Ioana Lazea [Mon, 23 Mar 2026 09:29:13 +0000 (09:29 +0000)] 
tc/htb: enable use of 64 bit burst

Modify the HTB queueing discipline to allow burst sizes up to the
limits supported by the kernel API, which may exceed 4 GB at higher rates.

In the current implementation, the burst option is effectively limited
to 4 GB due to the use of a 32-bit field while parsing the burst size.
However, the kernel internally represents the burst in terms of time
derived from the configured rate. As a result, at sufficiently high
rates this time-based representation can correspond to burst sizes
larger than 4 GB, making such bursts feasible without requiring changes
to the kernel.

This change removes the artificial 4 GB limit and allows larger burst
sizes where supported by the kernel API.

Signed-off-by: Ioana Lazea <ioana.lazea@canonical.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
3 months agotc/tbf: enable use of 64 bit burst
Ioana Lazea [Mon, 23 Mar 2026 09:29:12 +0000 (09:29 +0000)] 
tc/tbf: enable use of 64 bit burst

Modify the TBF queueing discipline configuration to allow burst sizes up
to the limits supported by the kernel API, which may exceed 4 GB at
higher rates.

In the current implementation, the burst option is effectively limited
to 4 GB because it is stored in a 32-bit field. However, the kernel
internally represents the burst in psched ticks (64 nsec each). At
sufficiently high rates, this representation can correspond to burst
sizes larger than 4 GB without requiring kernel changes.

Overflows (burst values that exceed UINT_MAX psched ticks) are now
correctly detected, and flagged as an error, rather than passing
arbitrary psched tick values to the kernel.

The change to increase the burst size to 64-bit introduced an issue with
TCA_TBF_BURST. The kernel expects this attribute as NLA_U32 (a 32-bit
unsigned value), but the updated implementation may produce a 64-bit
value, causing the tbf_policy check in the kernel to fail. However, when
TCA_TBF_BURST is omitted (which occurs when buffer64 >= UINT_MAX), the
kernel falls back to using the value assigned to qopt->buffer, which
correctly supports large burst sizes. Omitting TCA_TBF_BURST for large
bursts preserves backward compatibility and aligns with existing kernel
behavior. This change therefore ensures correct handling of large burst
sizes while remaining compatible with kernel and iproute2 expectations.

Signed-off-by: Ioana Lazea <ioana.lazea@canonical.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
3 months agoss: add support for TCP delack timers
Eric Dumazet [Fri, 3 Apr 2026 10:23:09 +0000 (10:23 +0000)] 
ss: add support for TCP delack timers

Kernel commit c698f5cc940d ("inet_diag: report delayed ack timer information")
added a new enum for idiag_timer values and support for delayed ack timers.

Change tcp_timer_print() to use the new enum and display "delack"
instead of "unknown":

tt -to
...
   ESTAB 10     0   [2002:a05:6830:1f86::]:12875 [2002:a05:6830:1f85::]:50438

        timer:(delack,003ms,0) ino:152178 sk:3004 cgroup:unreachable:189 <->

        skmem:(r1344,rb12780520,t0,tb262144,f2752,w0,o250,bl0,d0) ts usec_ts
        ...

Signed-off-by: Eric Dumazet <edumazet@google.com>
Reviewed-by: Neal Cardwell <ncardwell@google.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
3 months agodpll: add direction and state filtering for pin show
Petr Oros [Tue, 31 Mar 2026 13:59:18 +0000 (15:59 +0200)] 
dpll: add direction and state filtering for pin show

Allow filtering pins by direction (input/output) and state
(connected/disconnected/selectable) in the pin show command.
These filters match against parent-device nested attributes and
can be combined with the parent-device filter to check a specific
parent-device relationship.

Example: dpll pin show parent-device 0 direction input state connected
Signed-off-by: Petr Oros <poros@redhat.com>
Tested-by: Ivan Vecera <ivecera@redhat.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
3 months agoss: escape characters in command name
Stephen Hemminger [Wed, 25 Mar 2026 23:03:02 +0000 (00:03 +0100)] 
ss: escape characters in command name

Since the process name is under user control with prctl(PR_SET_NAME)
it may contain escape characters to try and mess with screen output.

Reuse the existing string logic from procps (used by ps command).

Reported-by: Josiah Stearns <B00TK1D@proton.me>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Reviewed-by: Michal Kubecek <mkubecek@suse.cz>
Tested-by: Michal Kubecek <mkubecek@suse.cz>
3 months agodpll: Fix missing notifications in monitor mode
Andrea Claudi [Thu, 12 Mar 2026 18:35:47 +0000 (19:35 +0100)] 
dpll: Fix missing notifications in monitor mode

When running dpll monitor with output redirected to a file, notifications
could be lost because stdout is fully buffered for file redirection instead
of line-buffered like in interactive mode. If the program is killed or
crashes, buffered data is lost before reaching the file.

Fix by calling fflush(stdout) after each notification to ensure immediate
writes to the log file.

Fixes: 656cfc3ce05b ("dpll: Add dpll command")
Signed-off-by: Andrea Claudi <aclaudi@redhat.com>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
3 months agodevlink: show devlink instance index in dev output
Jiri Pirko [Mon, 16 Mar 2026 15:44:18 +0000 (16:44 +0100)] 
devlink: show devlink instance index in dev output

Print devlink instance index in dev show output when
the kernel provides it.

Signed-off-by: Jiri Pirko <jiri@nvidia.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
3 months agomnl: add fallback implementation for mnl_attr_get_uint()
Jiri Pirko [Mon, 16 Mar 2026 15:44:17 +0000 (16:44 +0100)] 
mnl: add fallback implementation for mnl_attr_get_uint()

libmnl introduced mnl_attr_get_uint() to handle NLA_UINT
variable-width attributes. Add a configure check to detect it
and provide a fallback implementation for older libmnl versions.

Signed-off-by: Jiri Pirko <jiri@nvidia.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
3 months agoUpdate kernel headers
David Ahern [Mon, 23 Mar 2026 00:07:36 +0000 (18:07 -0600)] 
Update kernel headers

Update kernel headers to commit:
fb78a629b4f0: ("Merge branch 'netdevsim-support-ets-offload'")

Signed-off-by: David Ahern <dsahern@kernel.org>
4 months agotc: Add JSON output support to multiq
Victor Nogueira [Tue, 3 Mar 2026 13:07:33 +0000 (10:07 -0300)] 
tc: Add JSON output support to multiq

Since qdisc core already assumes all qdiscs are able to output JSON,
add JSON output support to multiq.

Fixes: c91d262f414d ("tc: jsonify qdisc core")
Signed-off-by: Victor Nogueira <victor@mojatatu.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
4 months agotc: Add JSON output support to QFQ
Victor Nogueira [Tue, 3 Mar 2026 13:07:32 +0000 (10:07 -0300)] 
tc: Add JSON output support to QFQ

Since qdisc core already assumes all qdiscs are able to output JSON,
add JSON output support to QFQ.

Fixes: c91d262f414d ("tc: jsonify qdisc core")
Signed-off-by: Victor Nogueira <victor@mojatatu.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
4 months agotc: Add JSON output support to HFSC
Victor Nogueira [Tue, 3 Mar 2026 13:07:31 +0000 (10:07 -0300)] 
tc: Add JSON output support to HFSC

Since qdisc core already assumes all qdiscs are able to output JSON,
add JSON output support to HFSC.

Fixes: c91d262f414d ("tc: jsonify qdisc core")
Reported-by: Deren Teo <deren.teo@outlook.com>
Closes: https://lore.kernel.org/netdev/SI2PPF4F82E9256898C9826AF17C3AE8AD9F467A@SI2PPF4F82E9256.apcprd04.prod.outlook.com/
Signed-off-by: Victor Nogueira <victor@mojatatu.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
4 months agodpll: fix pin id-get type filter parsing
Petr Oros [Tue, 24 Feb 2026 09:12:40 +0000 (10:12 +0100)] 
dpll: fix pin id-get type filter parsing

dpll_parse_attr_enum() expects the keyword to be already consumed,
but cmd_pin_id_get() used dpll_argv_match() which does not advance
the argument pointer. This caused the parser to read the keyword
"type" as the enum value instead of the actual type (e.g. "gnss").

Use dpll_argv_match_inc() to properly consume the keyword before
parsing the value.

Fixes: 656cfc3ce05b ("dpll: Add dpll command")
Signed-off-by: Petr Oros <poros@redhat.com>
4 months agoremove leftover references to /usr/lib/route2
Stephen Hemminger [Mon, 2 Mar 2026 16:37:53 +0000 (08:37 -0800)] 
remove leftover references to /usr/lib/route2

Since commit 962692356a1c ("Makefile: use /usr/share/iproute2 for config
files") the path was moved to /usr/share in Makefile; but there
were leftover references.

Reported-by: Yedaya Katsman <yedaya.ka@gmail.com>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
4 months agoMerge branch 'dpll-filter' into next
David Ahern [Mon, 2 Mar 2026 16:14:46 +0000 (09:14 -0700)] 
Merge branch 'dpll-filter' into next

Signed-off-by: David Ahern <dsahern@kernel.org>
4 months agodpll: add pin filtering by parent-device and parent-pin
Petr Oros [Tue, 24 Feb 2026 09:12:43 +0000 (10:12 +0100)] 
dpll: add pin filtering by parent-device and parent-pin

The existing "device" argument in "dpll pin show" sent DPLL_A_ID
in the pin dump request, but the kernel does not use this attribute
for pin dump filtering. Replace it with client-side parent-device
filtering that checks DPLL_A_PIN_PARENT_ID inside nested
DPLL_A_PIN_PARENT_DEVICE attributes.

Also add parent-pin filtering for mux pin hierarchies using the
same approach with DPLL_A_PIN_PARENT_PIN nested attributes.

Rename the "device" argument to "parent-device" to better reflect
the actual semantics.

Signed-off-by: Petr Oros <poros@redhat.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
4 months agodpll: add client-side filtering for pin show
Petr Oros [Tue, 24 Feb 2026 09:12:42 +0000 (10:12 +0100)] 
dpll: add client-side filtering for pin show

Add client-side filtering support for dpll pin show command.
Users can filter pins by module-name, clock-id, board-label,
panel-label, package-label, and type. Multiple filters use AND
semantics. Filters work with both dump and single GET operations.

Signed-off-by: Petr Oros <poros@redhat.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
4 months agodpll: add client-side filtering for device show
Petr Oros [Tue, 24 Feb 2026 09:12:41 +0000 (10:12 +0100)] 
dpll: add client-side filtering for device show

Add client-side filtering support for dpll device show command.
Users can filter devices by module-name, clock-id, type, mode,
and lock-status. Multiple filters use AND semantics. Filters
work with both dump (all devices) and single GET (by id) operations.

Signed-off-by: Petr Oros <poros@redhat.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
4 months agoiplink: bond_slave: print actor and partner churn state
Hangbin Liu [Thu, 26 Feb 2026 03:38:44 +0000 (03:38 +0000)] 
iplink: bond_slave: print actor and partner churn state

Add ability to print both actor and partner port churn states
(MONITOR/CHURN/NO_CHURN) via netlink attributes. This provides
visibility into the LACP churn detection state for bond slaves.

Signed-off-by: Hangbin Liu <liuhangbin@gmail.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
4 months agoUpdate kernel headers
David Ahern [Mon, 2 Mar 2026 15:32:55 +0000 (08:32 -0700)] 
Update kernel headers

Update kernel headers to commit:
01857fc712f6: ("Merge branch 'net-sched-refactor-qdisc-drop-reasons-into-dedicated-tracepoint'")

Signed-off-by: David Ahern <dsahern@kernel.org>
4 months agoss: Remove trailing whitespace when output is not a TTY
Daniel Schulte [Wed, 25 Feb 2026 19:39:03 +0000 (20:39 +0100)] 
ss: Remove trailing whitespace when output is not a TTY

Sometimes a value in the last column might be very long.
When grepping ss output the matched lines are also padded to the longest value.
In some cases this can result in multiple lines of the terminal getting filled
with spaces.

Don't print right padding in last visible column when ss can't determine the
screen width.

Signed-off-by: Daniel Schulte <trilader@schroedingers-bit.net>
4 months agoinclude/json_print.h: add includes for `__u32` and `timeval` declarations
Sergei Trofimovich [Mon, 23 Feb 2026 22:34:35 +0000 (22:34 +0000)] 
include/json_print.h: add includes for `__u32` and `timeval` declarations

Without the change the build fails on `musl` as:

```
../include/json_print.h:100:44: error: unknown type name ‘__u32’
  100 | unsigned int print_range(const char *name, __u32 start, __u32 end);
      |                                            ^~~~~
...
../include/json_print.h:82:30: warning: ‘struct timeval’ declared inside parameter list will not be visible outside of this definition or declaration
   82 | _PRINT_FUNC(tv, const struct timeval *)
      |                              ^~~~~~~
../include/json_print.h:57:45: note: in definition of macro ‘_PRINT_FUNC’
   57 |                                             type value)                 \
      |                                             ^~~~
../include/json_print.h: In function ‘print_tv’:
../include/json_print.h:60:48: error: passing argument 5 of ‘print_color_tv’ from incompatible pointer type [-Wincompatible-pointer-types]
   60 |                                                value);                  \
      |                                                ^~~~~
      |                                                |
      |                                                const struct timeval *
```

4 months agoss: suppress netlink errors for unsupported protocols
Stephen Hemminger [Wed, 25 Feb 2026 20:59:13 +0000 (12:59 -0800)] 
ss: suppress netlink errors for unsupported protocols

Error messages from sock_diag were only suppressed for extended
protocols (> 255).  Protocols like SCTP and DCCP also get EINVAL
when their kernel modules are not loaded.  Remove the conditional
so all protocols suppress the error.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>