]> git.baikalelectronics.ru Git - kernel.git/commit
mlxsw: Update module's settings when module is plugged in
authorAmit Cohen <amcohen@nvidia.com>
Sun, 27 Sep 2020 07:50:14 +0000 (10:50 +0300)
committerDavid S. Miller <davem@davemloft.net>
Sun, 27 Sep 2020 20:27:01 +0000 (13:27 -0700)
commit05cf5828bc8e18fcff095222395e188766683409
treebc5a66a4ba313e9fd876e3ccde8ae7a8efafd72e
parent3bdbab3fee87e7d2b29a61ea55808ae9d993f1d2
mlxsw: Update module's settings when module is plugged in

Module temperature warning events are enabled for modules that have a
temperature sensor and configured according to the temperature
thresholds queried from the module.

When a module is unplugged we are guaranteed not to get temperature
warning events. However, when a module is plugged in we need to
potentially update its current settings (i.e., event enablement and
thresholds).

Register to port module plug/unplug events and update module's settings
upon plug in events.

Signed-off-by: Amit Cohen <amcohen@nvidia.com>
Signed-off-by: Ido Schimmel <idosch@nvidia.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mellanox/mlxsw/core_env.c
drivers/net/ethernet/mellanox/mlxsw/reg.h
drivers/net/ethernet/mellanox/mlxsw/spectrum.c
drivers/net/ethernet/mellanox/mlxsw/trap.h