devlink: introduce selective dumps
Status from this message: This series was applied to netdev/net-next.git (main)
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v4 Latest13 patches 1 replyApplied 13/13
- v313 patches 2 repliesSuperseded
- v211 patches 23 repliesSuperseded
Earlier versions · 1
| Version | Posted | Patches | Replies | Status |
|---|---|---|---|---|
| v1 | 1 patch | 3 replies | Superseded |
Changes in v4 from the cover letter
- fixed NLM_F_DUMP_FILTERED flag handling
Patches in v4 All 13 applied
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/13 | devlink: parse linecard attr in doit() callbacksnet/ net/ net/ | +13 | 0 replies | Applied |
| 2/13 | devlink: parse rate attrs in doit() callbacksnet/ net/ net/ | +25 | 0 replies | Applied |
| 3/13 | devlink: introduce devlink_nl_pre_doit_port*() helper functionsnet/ net/ | +28 | 0 replies | Applied |
| 4/13 | devlink: rename doit callbacks for per-instance dump commandsnet/ net/ net/ +1 more | +52 | 0 replies | Applied |
| 5/13 | devlink: introduce dumpit callbacks for split opsnet/ net/ net/ +2 more | +144 | 0 replies | Applied |
| 6/13 | devlink: pass flags as an arg of dump_one() callbacknet/ net/ net/ +2 more | +56 | 0 replies | Applied |
| 7/13 | netlink: specs: devlink: add commands that do per-instance dumpDocumentation/ net/ net/ +2 more | +4319 | 0 replies | Applied |
| 8/13 | devlink: remove duplicate temporary netlink callback prototypesnet/ | +0 | 0 replies | Applied |
| 9/13 | devlink: remove converted commands from small opsnet/ net/ | +3 | 0 replies | Applied |
| 10/13 | devlink: allow user to narrow per-instance dumps by passing handle attrsnet/ | +40 | 0 replies | Applied |
| 11/13 | netlink: specs: devlink: extend per-instance dump commands to accept instance attributesDocumentation/ net/ tools/ +1 more | +799 | 0 replies | Applied |
| 12/13 | devlink: extend health reporter dump selector by port indexnet/ | +14 | 0 replies | Applied |
| 13/13 | netlink: specs: devlink: extend health reporter dump attributes by port indexDocumentation/ net/ tools/ +1 more | +15 | 0 replies | Applied |
Reviews trailers per patch
None of the 13 patches has a Reviewed-by or Acked-by of their own; the series has one for all of them.
| Patch | Jakub Kicinski |
|---|---|
| Series | A-b |
| 1/13 | |
| 2/13 | |
| 3/13 | |
| 4/13 | |
| 5/13 | |
| 6/13 | |
| 7/13 | |
| 8/13 | |
| 9/13 | |
| 10/13 | |
| 11/13 | |
| 12/13 | |
| 13/13 |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [patch net-next v4 00/13] devlink: introduce selective dumps
From: Jiri Pirko <[email protected]>
Motivation:
For SFs, one devlink instance per SF is created. There might be thousands of these on a single host. When a user needs to know port handle for specific SF, he needs to dump all devlink ports on the host which does not scale good.
Solution:
Allow user to pass devlink handle (and possibly other attributes) alongside the dump command and dump only objects which are matching the selection.
Use split ops to generate policies for dump callbacks acccording to the attributes used for selection.
The userspace can use ctrl genetlink GET_POLICY command to find out if the selective dumps are supported by kernel for particular command.
Example:
$ devlink port show auxiliary/mlx5_core.eth.0/65535: type eth netdev eth2 flavour physical port 0 splittable false auxiliary/mlx5_core.eth.1/131071: type eth netdev eth3 flavour physical port 1 splittable false
$ devlink port show auxiliary/mlx5_core.eth.0 auxiliary/mlx5_core.eth.0/65535: type eth netdev eth2 flavour physical port 0 splittable false
$ devlink port show auxiliary/mlx5_core.eth.1 auxiliary/mlx5_core.eth.1/131071: type eth netdev eth3 flavour physical port 1 splittable false
Extension:
patches #12 and #13 extends selection attributes by port index for health reporter dumping.
---v3->v4:
- fixed NLM_F_DUMP_FILTERED flag handlingv2->v3:
- redid the whole thing using generated split ops and removed nested selector attribute as suggested by Jakub. More in individual patches.v1->v2:
- the original single patch (patch #10) was extended to a patchset
Jiri Pirko (13):
devlink: parse linecard attr in doit() callbacks
devlink: parse rate attrs in doit() callbacks
devlink: introduce devlink_nl_pre_doit_port*() helper functions
devlink: rename doit callbacks for per-instance dump commands
devlink: introduce dumpit callbacks for split ops
devlink: pass flags as an arg of dump_one() callback
netlink: specs: devlink: add commands that do per-instance dump
devlink: remove duplicate temporary netlink callback prototypes
devlink: remove converted commands from small ops
devlink: allow user to narrow per-instance dumps by passing handle
attrs
netlink: specs: devlink: extend per-instance dump commands to accept
instance attributes
devlink: extend health reporter dump selector by port index
netlink: specs: devlink: extend health reporter dump attributes by
port index
Documentation/netlink/specs/devlink.yaml | 457 +++- net/devlink/dev.c | 29 +- net/devlink/devl_internal.h | 44 +- net/devlink/health.c | 40 +- net/devlink/leftover.c | 419 ++-- net/devlink/netlink.c | 110 +- net/devlink/netlink_gen.c | 424 +++- net/devlink/netlink_gen.h | 52 +- tools/net/ynl/generated/devlink-user.c | 2434 +++++++++++++++++++++- tools/net/ynl/generated/devlink-user.h | 1824 +++++++++++++++- 10 files changed, 5327 insertions(+), 506 deletions(-)
Signature · 1 line
2.41.0