diff options
author | David S. Miller <davem@davemloft.net> | 2020-07-10 23:32:02 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2020-07-10 23:32:02 +0200 |
commit | ac4cd4781eacd1fd185c85522e869bd5d3254b96 (patch) | |
tree | 7b4b4650e3d949131994e985d6f6991b2c872728 /drivers/usb/mon | |
parent | Merge tag 'mlx5-updates-2020-07-09' of git://git.kernel.org/pub/scm/linux/ker... (diff) | |
parent | net/mlx5e: Move devlink-health rx and tx reporters to devlink port (diff) | |
download | linux-ac4cd4781eacd1fd185c85522e869bd5d3254b96.tar.xz linux-ac4cd4781eacd1fd185c85522e869bd5d3254b96.zip |
Merge branch 'devlink-health'
Moshe Shemesh says:
====================
Add devlink-health support for devlink ports
Implement support for devlink health reporters on per-port basis.
This patchset comes to fix a design issue as some health reporters report
on errors and run recovery on device level while the actual functionality
is on port level. As for the current implemented devlink health reporters
it is relevant only to Tx and Rx reporters of mlx5, which has only one
port, so no real effect on functionality, but this should be fixed before
more drivers will use devlink health reporters.
First part in the series prepares common functions parts for health
reporter implementation. Second introduces required API to devlink-health
and mlx5e ones demonstrate its usage and implement the feature for mlx5
driver.
The per-port reporter functionality is achieved by adding a list of
devlink_health_reporters to devlink_port struct in a manner similar to
existing device infrastructure. This is the only major difference and
it makes possible to fully reuse device reporters operations.
The effect will be seen in conjunction with iproute2 additions and
will affect all devlink health commands. User can distinguish between
device and port reporters by looking at a devlink handle. Port reporters
have a port index at the end of the address and such addresses can be
provided as a parameter in every place where devlink-health accepted it.
These can be obtained from devlink port show command.
For example:
$ devlink health show
pci/0000:00:0a.0:
reporter fw
state healthy error 0 recover 0 auto_dump true
pci/0000:00:0a.0/1:
reporter tx
state healthy error 0 recover 0 grace_period 500 auto_recover true auto_dump true
$ devlink health set pci/0000:00:0a.0/1 reporter tx grace_period 1000 \
auto_recover false auto_dump false
$ devlink health show pci/0000:00:0a.0/1 reporter tx
pci/0000:00:0a.0/1:
reporter tx
state healthy error 0 recover 0 grace_period 1000 auto_recover flase auto_dump false
Note: User can use the same devlink health uAPI commands can get now either
port health reporter or device health reporter.
For example, the recover command:
Before this patchset: devlink health recover DEV reporter REPORTER_NAME
After this patchset: devlink health recover { DEV | DEV/PORT_INDEX } reporter REPORTER_NAME
Changes v1 -> v2:
Fixed functions comment to match parameters list.
Changes v2 -> v3:
Added motivation to cover letter and note on uAPI.
====================
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/usb/mon')
0 files changed, 0 insertions, 0 deletions