net/mlx5: Notify on trap action by blocking event
authorAya Levin <ayal@nvidia.com>
Tue, 26 Jan 2021 23:24:11 +0000 (15:24 -0800)
committerJakub Kicinski <kuba@kernel.org>
Thu, 28 Jan 2021 03:53:51 +0000 (19:53 -0800)
commit241dc159391fb9d351362d911a39dff84074cc92
tree6c8afa627849b10ae57b8ef04513e72086d2cd91
parent3eac5d949afeca60982165e6fc4cece6f5882843
net/mlx5: Notify on trap action by blocking event

In order to allow mlx5 core driver to trigger synchronous operations to
its consumers, add a blocking events handler. Add wrappers to
blocking_notifier_[call_chain/chain_register/chain_unregister]. Add trap
callback for action set and notify about this change. Following patches
in the set add a listener for this event.

Signed-off-by: Aya Levin <ayal@nvidia.com>
Reviewed-by: Tariq Toukan <tariqt@nvidia.com>
Signed-off-by: Tariq Toukan <tariqt@nvidia.com>
Signed-off-by: Saeed Mahameed <saeedm@nvidia.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/mellanox/mlx5/core/devlink.c
drivers/net/ethernet/mellanox/mlx5/core/events.c
include/linux/mlx5/device.h
include/linux/mlx5/driver.h