mirror of
https://github.com/Fishwaldo/linux-bl808.git
synced 2025-06-17 20:25:19 +00:00
net/mlx5e: Change enum to better reflect usage
Change MLX5E_STATE_ASYNC_EVENTS_ENABLE to
MLX5E_STATE_ASYNC_EVENTS_ENABLED since it represent a state and not an
operation.
Fixes: acff797cd1
('net/mlx5: Extend mlx5_core to support ConnectX-4 Ethernet functionality')
Signed-off-by: Eli Cohen <eli@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
7092fe8669
commit
e0f46eb9f6
2 changed files with 4 additions and 4 deletions
|
@ -401,7 +401,7 @@ enum mlx5e_traffic_types {
|
||||||
};
|
};
|
||||||
|
|
||||||
enum {
|
enum {
|
||||||
MLX5E_STATE_ASYNC_EVENTS_ENABLE,
|
MLX5E_STATE_ASYNC_EVENTS_ENABLED,
|
||||||
MLX5E_STATE_OPENED,
|
MLX5E_STATE_OPENED,
|
||||||
MLX5E_STATE_DESTROYING,
|
MLX5E_STATE_DESTROYING,
|
||||||
};
|
};
|
||||||
|
|
|
@ -244,7 +244,7 @@ static void mlx5e_async_event(struct mlx5_core_dev *mdev, void *vpriv,
|
||||||
{
|
{
|
||||||
struct mlx5e_priv *priv = vpriv;
|
struct mlx5e_priv *priv = vpriv;
|
||||||
|
|
||||||
if (!test_bit(MLX5E_STATE_ASYNC_EVENTS_ENABLE, &priv->state))
|
if (!test_bit(MLX5E_STATE_ASYNC_EVENTS_ENABLED, &priv->state))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
switch (event) {
|
switch (event) {
|
||||||
|
@ -260,12 +260,12 @@ static void mlx5e_async_event(struct mlx5_core_dev *mdev, void *vpriv,
|
||||||
|
|
||||||
static void mlx5e_enable_async_events(struct mlx5e_priv *priv)
|
static void mlx5e_enable_async_events(struct mlx5e_priv *priv)
|
||||||
{
|
{
|
||||||
set_bit(MLX5E_STATE_ASYNC_EVENTS_ENABLE, &priv->state);
|
set_bit(MLX5E_STATE_ASYNC_EVENTS_ENABLED, &priv->state);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void mlx5e_disable_async_events(struct mlx5e_priv *priv)
|
static void mlx5e_disable_async_events(struct mlx5e_priv *priv)
|
||||||
{
|
{
|
||||||
clear_bit(MLX5E_STATE_ASYNC_EVENTS_ENABLE, &priv->state);
|
clear_bit(MLX5E_STATE_ASYNC_EVENTS_ENABLED, &priv->state);
|
||||||
synchronize_irq(mlx5_get_msix_vec(priv->mdev, MLX5_EQ_VEC_ASYNC));
|
synchronize_irq(mlx5_get_msix_vec(priv->mdev, MLX5_EQ_VEC_ASYNC));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue