diff options
author | Mohamad Haj Yahia <mohamad@mellanox.com> | 2016-09-09 17:35:22 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2016-09-11 07:21:49 +0300 |
commit | 62a9b90ad83ebe584bf22a2e716a96e75f82e137 (patch) | |
tree | ac97f622762a41f3674210dfe5105da94fd40e6a /drivers/net/ethernet/mellanox/mlx5/core/eswitch.h | |
parent | acab721b5d8d9431cc80acc827973eeeda4dec24 (diff) | |
download | linux-62a9b90ad83ebe584bf22a2e716a96e75f82e137.tar.xz |
net/mlx5: Implement eswitch attach/detach flows
Needed for lightweight and modular internal/pci error handling.
Implement eswitch attach function which allocates/starts hw related
resources.
Implement eswitch detach function which releases/stops hw related
resources.
Init/cleanup function only handle eswitch software context allocation
and destruction.
Signed-off-by: Mohamad Haj Yahia <mohamad@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/mellanox/mlx5/core/eswitch.h')
-rw-r--r-- | drivers/net/ethernet/mellanox/mlx5/core/eswitch.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/net/ethernet/mellanox/mlx5/core/eswitch.h b/drivers/net/ethernet/mellanox/mlx5/core/eswitch.h index a96140971d77..48c273d5b709 100644 --- a/drivers/net/ethernet/mellanox/mlx5/core/eswitch.h +++ b/drivers/net/ethernet/mellanox/mlx5/core/eswitch.h @@ -204,6 +204,8 @@ struct mlx5_eswitch { /* E-Switch API */ int mlx5_eswitch_init(struct mlx5_core_dev *dev); void mlx5_eswitch_cleanup(struct mlx5_eswitch *esw); +void mlx5_eswitch_attach(struct mlx5_eswitch *esw); +void mlx5_eswitch_detach(struct mlx5_eswitch *esw); void mlx5_eswitch_vport_event(struct mlx5_eswitch *esw, struct mlx5_eqe *eqe); int mlx5_eswitch_enable_sriov(struct mlx5_eswitch *esw, int nvfs, int mode); void mlx5_eswitch_disable_sriov(struct mlx5_eswitch *esw); |