Commit Graph

6610 Commits

Author SHA1 Message Date
Matthieu Baerts (NGI0)
640ebc23d8 man: mptcp: 'fullmesh' has to be used with 'subflow'
'fullmesh' affects the subflow creation, it has to be used with the
'subflow' flag. That's what is enforced on the kernel side.

Acked-by: Mat Martineau <martineau@kernel.org>
Signed-off-by: Matthieu Baerts (NGI0) <matttbe@kernel.org>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2024-08-02 10:47:39 -07:00
Matthieu Baerts (NGI0)
e3c1e2a4e2 man: mptcp: 'backup' flag also affects outgoing data
That's the behaviour with the default packet scheduler.

In some early design, the default scheduler was supposed to take into
account only the received backup flags, but it ended up not being the
case, and setting the flag would also affect outgoing data.

Suggested-by: Mat Martineau <martineau@kernel.org>
Acked-by: Mat Martineau <martineau@kernel.org>
Signed-off-by: Matthieu Baerts (NGI0) <matttbe@kernel.org>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2024-08-02 10:47:39 -07:00
Matthieu Baerts (NGI0)
8251786f3d man: mptcp: 'port' has to be used with 'signal'
That's what is enforced by the kernel: the 'port' is used to create a
new listening socket on that port, not to create a new subflow from/to
that port. It then requires the 'signal' flag.

Acked-by: Mat Martineau <martineau@kernel.org>
Signed-off-by: Matthieu Baerts (NGI0) <matttbe@kernel.org>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2024-08-02 10:47:39 -07:00
Matthieu Baerts (NGI0)
80392875fa man: mptcp: clarify 'signal' and 'subflow' flags
According to some bug reports on the MPTCP project, these options might
be a bit confusing for some.

Mentioning that the 'signal' flag is typically for a server, and the
'subflow' one is typically for a client should help the user knowing in
which context which flag should be picked.

Acked-by: Mat Martineau <martineau@kernel.org>
Signed-off-by: Matthieu Baerts (NGI0) <matttbe@kernel.org>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2024-08-02 10:47:39 -07:00
Matthieu Baerts (NGI0)
484009f46e man: mptcp: document 'dev IFNAME'
It was missing, while it is a very important option.

Indeed, without it, the kernel might not pick the right interface to
send packets for additional subflows. Mention that in the man page.

Acked-by: Mat Martineau <martineau@kernel.org>
Signed-off-by: Matthieu Baerts (NGI0) <matttbe@kernel.org>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2024-08-02 10:47:39 -07:00
Stephen Hemminger
ae32ba8273 uapi: update to 6.11-rc1
Update from 6.11-rc1

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2024-07-29 09:37:31 -07:00
Stephen Hemminger
c436c80e7f man: update ip-address man page
The ip address man page had some small things that needed update:
  - ip address delete without address returns not supported
  - always use full words for commands in man pages
       (ie "delete" not "del")

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2024-07-25 11:24:45 -07:00
xixiliguo
3e807112fd ss: fix expired time format of timer
When expired time of time-wait timer is less than or equal to 9 seconds,
as shown below, result that below 1 sec is incorrect.
Expect output should be show 9 seconds and 373 millisecond, but 9.373ms
mean only 9 millisecond and 373 microseconds

Before:
TIME-WAIT 0      0     ...    timer:(timewait,12sec,0)
TIME-WAIT 0      0     ...    timer:(timewait,11sec,0)
TIME-WAIT 0      0     ...    timer:(timewait,10sec,0)
TIME-WAIT 0      0     ...    timer:(timewait,9.373ms,0)
TIME-WAIT 0      0     ...    timer:(timewait,8.679ms,0)
TIME-WAIT 0      0     ...    timer:(timewait,1.574ms,0)
TIME-WAIT 0      0     ...    timer:(timewait,954ms,0)
TIME-WAIT 0      0     ...    timer:(timewait,303ms,0)

After:
TIME-WAIT 0      0     ...    timer:(timewait,13sec,0)
TIME-WAIT 0      0     ...    timer:(timewait,12sec,0)
TIME-WAIT 0      0     ...    timer:(timewait,10sec,0)
TIME-WAIT 0      0     ...    timer:(timewait,9.501sec,0)
TIME-WAIT 0      0     ...    timer:(timewait,8.990sec,0)
TIME-WAIT 0      0     ...    timer:(timewait,7.865sec,0)
TIME-WAIT 0      0     ...    timer:(timewait,1.098sec,0)
TIME-WAIT 0      0     ...    timer:(timewait,476ms,0)

Signed-off-by: xixiliguo <xixiliguo@foxmail.com>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2024-07-25 10:37:53 -07:00
Beniamino Galvani
554ea3649d ip: do not print stray prefixes in monitor mode
When running "ip monitor", accept_msg() first prints the prefix and
then calls the object-specific print function, which also does the
filtering. Therefore, it is possible that the prefix is printed even
for events that get ignored later. For example:

  ip link add dummy1 type dummy
  ip link set dummy1 up
  ip -ts monitor all dev dummy1 &
  ip link add dummy2 type dummy
  ip addr add dev dummy1 192.0.2.1/24

generates:

  [2024-07-12T22:11:26.338342] [LINK][2024-07-12T22:11:26.339846] [ADDR]314: dummy1    inet 192.0.2.1/24 scope global dummy1
       valid_lft forever preferred_lft forever

Fix this by printing the prefix only after the filtering. Now the
output for the commands above is:

 [2024-07-12T22:11:26.339846] [ADDR]314: dummy1    inet 192.0.2.1/24 scope global dummy1
       valid_lft forever preferred_lft forever

See also commit 7e0a889b54 ("bridge: Do not print stray prefixes in
monitor mode") which fixed the same problem in the bridge tool.

Signed-off-by: Beniamino Galvani <b.galvani@gmail.com>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2024-07-17 16:48:25 -07:00
Maks Mishin
b06341a252 f_flower: Remove always zero checks
Expression 'ttl & ~(255 >> 0)' is always zero, because right operand
has 8 trailing zero bits, which is greater or equal than the size
of the left operand == 8 bits.

Found by RASU JSC.

Signed-off-by: Maks Mishin <maks.mishinFZ@gmail.com>
Reviewed-by: Guillaume Nault <gnault@redhat.com>
Reviewed-by: Simon Horman <horms@kernel.org>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2024-07-17 16:47:57 -07:00
Stephen Hemminger
4917f98a64 Merge ssh://gitolite.kernel.org/pub/scm/network/iproute2/iproute2-next 2024-07-17 09:07:26 -07:00
Stephen Hemminger
db0edb90d2 v6.10.0 2024-07-16 19:38:17 -07:00
David Ahern
af9559b233 Merge remote-tracking branch 'main/main' into next
Signed-off-by: David Ahern <dsahern@kernel.org>
2024-07-08 22:36:13 +00:00
Przemek Kitszel
830f490e92 man: devlink-resource: add missing words in the example
Add missing "size" and "path" words in the example, as the current example
is incorrect and will be rejected by the command.

The keywords were missing from very inception of devlink-resource man page

Fixes: 58b48c5d75 ("devlink: Update man pages and add resource man")
Signed-off-by: Przemek Kitszel <przemyslaw.kitszel@intel.com>
Reviewed-by: Michal Kubiak <michal.kubiak@intel.com>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2024-07-08 15:01:50 -07:00
Tobias Waldekranz
dae3e5de6e bridge: mst: Add get/set support for MST states
Allow a port's spanning tree state to be modified on a per-MSTI basis,
and support dumping the current MST states for every port and MSTI.

Signed-off-by: Tobias Waldekranz <tobias@waldekranz.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
2024-07-08 03:33:53 +00:00
Tobias Waldekranz
ace3c9c1fe bridge: vlan: Add support for setting a VLANs MSTI
Allow the user to associate one or more VLANs with a multiple spanning
tree instance (MSTI), when MST is enabled on the bridge.

Signed-off-by: Tobias Waldekranz <tobias@waldekranz.com>
Reviewed-by: Hangbin Liu <liuhangbin@gmail.com>
Acked-by: Nikolay Aleksandrov <razor@blackwall.org>
Signed-off-by: David Ahern <dsahern@kernel.org>
2024-07-08 03:33:53 +00:00
Tobias Waldekranz
60a95a8a2e ip: bridge: add support for mst_enabled
When enabled, the bridge's legacy per-VLAN STP facility is replaced
with the Multiple Spanning Tree Protocol (MSTP) compatible version.

Signed-off-by: Tobias Waldekranz <tobias@waldekranz.com>
Reviewed-by: Hangbin Liu <liuhangbin@gmail.com>
Acked-by: Nikolay Aleksandrov <razor@blackwall.org>
Signed-off-by: David Ahern <dsahern@kernel.org>
2024-07-08 03:33:53 +00:00
Przemek Kitszel
77241a525b devlink: print missing params even if an unknown one is present
Print all of the missing parameters, also in the presence of unknown ones.

Take for example a correct command:
    $ devlink resource set pci/0000:01:00.0 path /kvd/linear size 98304
And remove the "size" keyword:
    $ devlink resource set pci/0000:01:00.0 path /kvd/linear 98304
That yields output:
    Resource size expected.
    Unknown option "98304"

Prior to the patch only the last line of output was present. And if user
would forgot also the "path" keyword, there will be additional line:
    Resource path expected.
in the stderr.

Reviewed-by: Maciej Fijalkowski <maciej.fijalkowski@intel.com>
Signed-off-by: Przemek Kitszel <przemyslaw.kitszel@intel.com>
Reviewed-by: Michal Kubiak <michal.kubiak@intel.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
2024-07-07 16:48:51 +00:00
Mark Zhang
5caf6c1764 rdma: Supports to add/delete a device with type SMI
This patch adds a new device attribute "type", as well as supports to
add and delete a rdma device with a specific type. This new device
provides a subset of functionalists defined in IBTA spec.

Currently only type "SMI" is supported: A SMI device provides SMI (QP0)
interface; This device and it's parent associates with the same HCA port
and shares the physical link, so when the parent doesn't support SMI,
It allows the subnet manager to configure the link.

This patch also supports to print device type and parent if any.

Examples:
$ rdma dev add smi1 type SMI parent ibp8s0f1
$ rdma dev show smi1
2: smi1: node_type ca fw 20.38.1002 node_guid 9803:9b03:009f:d5ef sys_image_guid 9803:9b03:009f:d5ee type smi parent ibp8s0f1
$ rdma dev del smi1

Signed-off-by: Mark Zhang <markzhang@nvidia.com>
Acked-by: Leon Romanovsky <leon@kernel.org>
Signed-off-by: David Ahern <dsahern@kernel.org>
2024-07-07 16:30:14 +00:00
Mark Zhang
ac257904ed rdma: update uapi header
Update rdma_netlink.h file upto kernel commit 294424839b5e
("RDMA/nldev: Add support to dump device type and parent device if exists")

Signed-off-by: Mark Zhang <markzhang@nvidia.com>
Acked-by: Leon Romanovsky <leon@kernel.org>
Signed-off-by: David Ahern <dsahern@kernel.org>
2024-07-07 16:30:12 +00:00
Stephen Hemminger
0ea0699ea0 route: filter by interface on multipath routes
The ip route command would silently hide multipath routes when filter
by interface. The problem was it was not looking for interface when
filter multipath routes.

Example:
	ip link add name dummy1 up type dummy
	ip link add name dummy2 up type dummy
	ip address add 192.0.2.1/28 dev dummy1
	ip address add 192.0.2.17/28 dev dummy2
	ip route add 198.51.100.0/24 \
		nexthop via 192.0.2.2 dev dummy1 \
		nexthop via 192.0.2.18 dev dummy2

Before:
ip route show dev dummy1
192.0.2.0/28 proto kernel scope link src 192.0.2.1

After:
ip route show dev dummy1
192.0.2.0/28 proto kernel scope link src 192.0.2.1
198.51.100.0/24
	nexthop via 192.0.2.2 dev dummy1 weight 1
	nexthop via 192.0.2.18 dev dummy2 weight 1

Reported-by: "Muggeridge, Matt" <matt.muggeridge2@hpe.com>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2024-07-04 17:44:55 -07:00
Stephen Hemminger
357808abd3 ss: fix format string warnings
Clang complains that format string is not a string literal
unless the functions are annotated.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2024-06-27 09:59:18 -07:00
Parav Pandit
c6c39f3c6d devlink: Fix setting max_io_eqs as the sole attribute
dl_opts_put() function missed to consider IO eqs option flag.
Due to this, when max_io_eqs setting is applied only when it
is combined with other attributes such as roce/hw_addr.
When max_io_eqs is the only attribute set, it missed to
apply the attribute.

Fix it by adding the missing flag.

Fixes: e8add23c59 ("devlink: Support setting max_io_eqs")
Signed-off-by: Parav Pandit <parav@nvidia.com>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2024-06-11 08:05:24 -07:00
William Tu
459ddd094d devlink: trivial: fix err format on max_io_eqs
Add missing ']'.

Signed-off-by: William Tu <witu@nvidia.com>
Fixes: e8add23c59 ("devlink: Support setting max_io_eqs")
Reviewed-by: Parav Pandit <parav@nvidia.com>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2024-06-11 08:05:16 -07:00
Christian Hopps
7cf98ef28b xfrm: document new SA direction option
Signed-off-by: Christian Hopps <chopps@labn.net>
Signed-off-by: David Ahern <dsahern@kernel.org>
2024-06-04 22:53:29 +00:00
Christian Hopps
7f7726a7a4 xfrm: add SA direction attribute
Add support for new SA direction netlink attribute.

Co-developed-by: Antony Antony <antony.antony@secunet.com>
Co-developed-by: Christian Hopps <chopps@labn.net>
Signed-off-by: Christian Hopps <chopps@labn.net>
Signed-off-by: David Ahern <dsahern@kernel.org>
2024-06-04 22:53:26 +00:00
Dragan Simic
900162c09e ss: use COLUMNS from the environment, if TIOCGWINSZ fails
Use the COLUMNS environment variable [1] when determining the screen width,
if using TIOCGWINSZ isn't possible or if it fails.  This allows better use
of the available horizontal screen space in certain scenarios, and makes
the produced outputs more readable, as described further below.

All major shells can maintain the COLUMNS variable according to the current
screen size, [2][3][4] but this shell variable isn't actually an environment
variable, i.e. it doesn't get exported to the shell subprocesses by default.
For example, no COLUMNS environment variable reaches ss(8) when it's executed
as part of a shell pipeline or inside a shell script.

Though, users can opt to export the COLUMNS variable by hand, or they can
rely on some other utilities to do that for them.  A good example of such
utilities is watch(1) that exports COLUMNS as an environment variable to
the processes it executes. [5]  Using ss(8) together with watch(1) is rather
useful, and honoring the exported COLUMNS variable makes the outputs produced
by ss(8) in this scenario more readable.

The behavior of shells, which don't export the COLUMNS variable by default,
makes this change safe in the sense of not affecting the usual shell pipeline
workflows or various shell scripts that use ss(8).

[1] https://pubs.opengroup.org/onlinepubs/9699919799.2016edition/basedefs/V1_chap08.html
[2] https://man.archlinux.org/man/bash.1.en#COLUMNS
[3] https://man.archlinux.org/man/tcsh.1.en#Terminal_management_(+)
[4] https://man.archlinux.org/man/zshall.1.en#Configuration
[5] https://gitlab.com/procps-ng/procps/-/blob/master/NEWS?ref_type=heads#L623

Signed-off-by: Dragan Simic <dsimic@manjaro.org>
Signed-off-by: David Ahern <dsahern@kernel.org>
2024-05-29 15:58:11 +00:00
David Ahern
3a84a49a53 Merge remote-tracking branch 'main/main' into next
Signed-off-by: David Ahern <dsahern@kernel.org>
2024-05-24 14:36:16 -06:00
Ismael Luceno
f9601b10c2 Fix usage of poll.h header
Change the legacy <sys/poll.h> to <poll.h> (POSIX.1-2001).

Signed-off-by: Ismael Luceno <ismael@iodev.co.uk>
Reviewed-by: Jiri Pirko <jiri@nvidia.com>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2024-05-23 09:27:55 -07:00
Stephen Hemminger
39e4b6f5f3 uapi: update to pre 6.10-rc1 headers
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2024-05-20 08:45:51 -07:00
Yedaya Katsman
3cd62286ac rtmon: Align usage with ip help
Also update the man page accordingly, and add ip-monitor to see also

Signed-off-by: Yedaya Katsman <yedaya.ka@gmail.com>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2024-05-13 22:23:55 -07:00
Gabi Falk
53a89bfd86 bridge/vlan.c: bridge/vlan.c: fix build with gcc 14 on musl systems
On glibc based systems the definition of 'struct timeval' is pulled in
with inclusion of <stdlib.h> header, but on musl based systems it
doesn't work this way.  Missing definition triggers an
incompatible-pointer-types error with gcc 14 (warning on previous
versions of gcc):

../include/json_print.h:80:30: warning: 'struct timeval' declared inside parameter list will not be visible outside of this definition or declaration
   80 | _PRINT_FUNC(tv, const struct timeval *)
      |                              ^~~~~~~
../include/json_print.h:50:37: note: in definition of macro '_PRINT_FUNC'
   50 |                                     type value);                        \
      |                                     ^~~~
../include/json_print.h:80:30: warning: 'struct timeval' declared inside parameter list will not be visible outside of this definition or declaration
   80 | _PRINT_FUNC(tv, const struct timeval *)
      |                              ^~~~~~~
../include/json_print.h:55:45: note: in definition of macro '_PRINT_FUNC'
   55 |                                             type value)                 \
      |                                             ^~~~
../include/json_print.h: In function 'print_tv':
../include/json_print.h:58:48: error: passing argument 5 of 'print_color_tv' from incompatible pointer type [-Wincompatible-pointer-types]
   58 |                                                value);                  \
      |                                                ^~~~~
      |                                                |
      |                                                const struct timeval *

Signed-off-by: Gabi Falk <gabifalk@gmx.com>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2024-05-13 22:21:38 -07:00
Stephen Hemminger
08cd3ce70a Merge git://git.kernel.org/pub/scm/network/iproute2/iproute2-next 2024-05-13 16:21:11 -07:00
Stephen Hemminger
03e50e0880 v6.9.0 2024-05-12 20:07:45 -07:00
Stephen Hemminger
853f34bf09 uapi: spelling fix for xfrm.h
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2024-05-10 16:19:35 -07:00
Andrea Claudi
397383a30c man: fix typo in tc-mirred man page
Signed-off-by: Andrea Claudi <aclaudi@redhat.com>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2024-05-08 08:11:41 -07:00
Yedaya Katsman
c9eab8973c ip: Add missing options to route get help output
The "as", "to", "connected" and "notify" options were missing from the
help message in the route get section. Add them to usage help and man
page.

Note that there isn't an explanation for "as" or "notify" in the man
page.

Signed-off-by: Yedaya Katsman <yedaya.ka@gmail.com>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2024-05-07 08:06:10 -07:00
David Ahern
977d51cfec Merge remote-tracking branch 'main/main' into next
Signed-off-by: David Ahern <dsahern@kernel.org>
2024-05-03 15:40:02 +00:00
Lukasz Majewski
c72323d2ef ip link: hsr: Add support for passing information about INTERLINK device
The HSR capable device can operate in two modes of operations -
Doubly Attached Node for HSR (DANH) and RedBOX (HSR-SAN).

The latter one allows connection of non-HSR aware device(s) to HSR
network.
This node is called SAN (Singly Attached Network) and is connected via
INTERLINK network device.

This patch adds support for passing information about the INTERLINK
device, so the Linux driver can properly setup it.

Signed-off-by: Lukasz Majewski <lukma@denx.de>
Signed-off-by: David Ahern <dsahern@kernel.org>
2024-05-03 15:19:30 +00:00
David Ahern
0475c997c0 Update kernel headers
Update kernel headers to commit:
    5829614a7b3b ("Merge branch 'net-sysctl-sentinel'")

Signed-off-by: David Ahern <dsahern@kernel.org>
2024-05-03 15:18:43 +00:00
Chiara Meiohas
57d7a8fd90 rdma: Add an option to display driver-specific QPs in the rdma tool
Utilize the -dd flag (driver-specific details) in the rdmatool
to view driver-specific QPs which are not exposed yet.

The following examples show mlx5 UMR QP which is visible now:

$ rdma resource show qp link ibp8s0f1
link ibp8s0f1/1 lqpn 360 type UD state RTS sq-psn 0 comm [mlx5_ib]
link ibp8s0f1/1 lqpn 0 type SMI state RTS sq-psn 0 comm [ib_core]
link ibp8s0f1/1 lqpn 1 type GSI state RTS sq-psn 0 comm [ib_core]

$ rdma resource show qp link ibp8s0f1 -dd
link ibp8s0f1/1 lqpn 360 type UD state RTS sq-psn 0 comm [mlx5_ib]
link ibp8s0f1/1 lqpn 465 type DRIVER subtype REG_UMR state RTS sq-psn 0 comm [mlx5_ib]
link ibp8s0f1/1 lqpn 0 type SMI state RTS sq-psn 0 comm [ib_core]
link ibp8s0f1/1 lqpn 1 type GSI state RTS sq-psn 0 comm [ib_core]

$ rdma resource show
0: ibp8s0f0: pd 3 cq 4 qp 3 cm_id 0 mr 0 ctx 0 srq 2
1: ibp8s0f1: pd 3 cq 4 qp 3 cm_id 0 mr 0 ctx 0 srq 2

$ rdma resource show -dd
0: ibp8s0f0: pd 3 cq 4 qp 4 cm_id 0 mr 0 ctx 0 srq 2
1: ibp8s0f1: pd 3 cq 4 qp 4 cm_id 0 mr 0 ctx 0 srq 2

Signed-off-by: Chiara Meiohas <cmeiohas@nvidia.com>
Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
2024-05-03 15:15:22 +00:00
Chiara Meiohas
e459ea4392 rdma: update uapi header
Update rdma_netlink.h file up to kernel commit e18fa0bbcedf
("RDMA/core: Add an option to display driver-specific QPs in the rdmatool")

Signed-off-by: Chiara Meiohas <cmeiohas@nvidia.com>
Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
Reviewed-by: Subbaraya Sundeep <sbhatta@marvell.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
2024-05-03 15:14:55 +00:00
Stephen Hemminger
89210b9ec1 uapi: update vdpa.h
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2024-04-29 11:28:23 -07:00
Yedaya Katsman
70ba338cd8 ip: Exit exec in child process if setup fails
If we forked, returning from the function will make the calling code to
continue in both the child and parent process. Make cmd_exec exit if
setup failed and it forked already.

An example of issues this causes, where a failure in setup causes
multiple unnecessary tries:

```
$ ip netns
ef
ab
$ ip -all netns exec ls

netns: ef
setting the network namespace "ef" failed: Operation not permitted

netns: ab
setting the network namespace "ab" failed: Operation not permitted

netns: ab
setting the network namespace "ab" failed: Operation not permitted
```

Signed-off-by: Yedaya Katsman <yedaya.ka@gmail.com>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2024-04-25 12:00:25 -07:00
David Ahern
c34ca74085 Merge branch 'pfcp' into next
Wojciech Drewek  says:

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

New PFCP module was accepted in the kernel together with cls_flower
changes which allow to filter the packets using PFCP specific fields [1].
Packet Forwarding Control Protocol is a 3GPP Protocol defined in
TS 29.244 [2].

Extended ip link with the support for the new PFCP device.
Add pfcp_opts support in tc-flower.

[1] https://lore.kernel.org/netdev/171196563119.11638.12210788830829801735.git-patchwork-notify@kernel.org/
[2] https://portal.3gpp.org/desktopmodules/Specifications/SpecificationDetails.aspx?specificationId=3111

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

Signed-off-by: David Ahern <dsahern@kernel.org>
2024-04-23 16:29:52 +00:00
Stephen Hemminger
911c62bf9d use missing argument helper
There is a helper in utilities to handle missing argument,
but it was not being used consistently.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2024-04-23 09:01:46 -07:00
Michal Swiatkowski
976dca372e f_flower: implement pfcp opts
Allow adding tc filter for PFCP header.

Add support for parsing TCA_FLOWER_KEY_ENC_OPTS_PFCP.
Options are as follows: TYPE:SEID.

TYPE is a 8-bit value represented in hex and can be  1
for session header and 0 for node header. In PFCP packet
this is S flag in header.

SEID is a 64-bit session id value represented in hex.

This patch enables adding hardware filters using PFCP fields, see [1].

[1] https://git.kernel.org/pub/scm/linux/kernel/git/netdev/net-next.git/commit/?id=d823265dd45bbf14bd67aa476057108feb4143ce

Signed-off-by: Michal Swiatkowski <michal.swiatkowski@linux.intel.com>
Signed-off-by: Wojciech Drewek <wojciech.drewek@intel.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
2024-04-23 15:34:19 +00:00
Wojciech Drewek
a25f6771be ip: PFCP device support
Packet Forwarding Control Protocol is a 3GPP Protocol defined in
TS 29.244 [1]. Add support for PFCP device type in ip link.
It is capable of receiving PFCP messages and extracting its
metadata (session ID).

Its only purpose is to be used together with tc flower to create
SW/HW filters.

PFCP module does not take any netlink attributes so there is no
need to parse any args. Add new sections to the man to let the
user know about new device type.

[1] https://portal.3gpp.org/desktopmodules/Specifications/SpecificationDetails.aspx?specificationId=3111

Signed-off-by: Wojciech Drewek <wojciech.drewek@intel.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
2024-04-23 15:31:23 +00:00
Jiayun Chen
11543416d9 man: fix doc, ip link does support "change"
ip link does support "change".

if (matches(*argv, "set") == 0 ||
    matches(*argv, "change") == 0)
    return iplink_modify(RTM_NEWLINK, 0,
                 argc-1, argv+1);

The attached patch documents this.

Signed-off-by: Jiayun Chen <jiayunchen@smail.nju.edu.cn>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2024-04-20 20:07:28 -07:00
Stephen Hemminger
95c886b8e8 tc/util: remove unused argument from print_tcstats2_attr
The function doesn't use the FILE handle.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Signed-off-by: David Ahern <dsahern@kernel.org>
2024-04-21 01:45:48 +00:00