diff options
author | Shay Drory <shayd@nvidia.com> | 2021-11-23 11:48:07 +0300 |
---|---|---|
committer | Saeed Mahameed <saeedm@nvidia.com> | 2022-01-07 03:22:51 +0300 |
commit | 424544df97b0197b1d87d2fd1c18c6b936aa02b1 (patch) | |
tree | d8380e3e69800e3dd5626a2fcb7ee9bd1007d33d /drivers/net/ethernet/mellanox/mlx5/core/mlx5_irq.h | |
parent | 30c6afa735db60b4fb6ca81da568d11d19aa2c15 (diff) | |
download | linux-424544df97b0197b1d87d2fd1c18c6b936aa02b1.tar.xz |
net/mlx5: Split irq_pool_affinity logic to new file
The downstream patches add more functionality to irq_pool_affinity.
Move the irq_pool_affinity logic to a new file in order to ease the
coding and maintenance of it.
Signed-off-by: Shay Drory <shayd@nvidia.com>
Reviewed-by: Moshe Shemesh <moshe@nvidia.com>
Signed-off-by: Saeed Mahameed <saeedm@nvidia.com>
Diffstat (limited to 'drivers/net/ethernet/mellanox/mlx5/core/mlx5_irq.h')
-rw-r--r-- | drivers/net/ethernet/mellanox/mlx5/core/mlx5_irq.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/drivers/net/ethernet/mellanox/mlx5/core/mlx5_irq.h b/drivers/net/ethernet/mellanox/mlx5/core/mlx5_irq.h index 7028e4b43837..db58f5e3f457 100644 --- a/drivers/net/ethernet/mellanox/mlx5/core/mlx5_irq.h +++ b/drivers/net/ethernet/mellanox/mlx5/core/mlx5_irq.h @@ -31,4 +31,15 @@ int mlx5_irq_detach_nb(struct mlx5_irq *irq, struct notifier_block *nb); struct cpumask *mlx5_irq_get_affinity_mask(struct mlx5_irq *irq); int mlx5_irq_get_index(struct mlx5_irq *irq); +struct mlx5_irq_pool; +#ifdef CONFIG_MLX5_SF +struct mlx5_irq *mlx5_irq_affinity_request(struct mlx5_irq_pool *pool, + const struct cpumask *req_mask); +#else +static inline struct mlx5_irq * +mlx5_irq_affinity_request(struct mlx5_irq_pool *pool, const struct cpumask *req_mask) +{ + return ERR_PTR(-EOPNOTSUPP); +} +#endif #endif /* __MLX5_IRQ_H__ */ |