Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

net/mlx5: Fix compilation warning in eq.c

mlx5_eq_table_get_rmap is being used only when CONFIG_RFS_ACCEL is
enabled, this patch fixes the below warning when CONFIG_RFS_ACCEL is
disabled.

drivers/.../mlx5/core/eq.c:903:18: [-Werror=missing-prototypes]
error: no previous prototype for ‘mlx5_eq_table_get_rmap’

Fixes: f2f3df550139 ("net/mlx5: EQ, Privatize eq_table and friends")
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>

+2 -4
+2 -4
drivers/net/ethernet/mellanox/mlx5/core/eq.c
··· 900 900 } 901 901 EXPORT_SYMBOL(mlx5_comp_irq_get_affinity_mask); 902 902 903 + #ifdef CONFIG_RFS_ACCEL 903 904 struct cpu_rmap *mlx5_eq_table_get_rmap(struct mlx5_core_dev *dev) 904 905 { 905 - #ifdef CONFIG_RFS_ACCEL 906 906 return dev->priv.eq_table->rmap; 907 - #else 908 - return NULL; 909 - #endif 910 907 } 908 + #endif 911 909 912 910 struct mlx5_eq_comp *mlx5_eqn2comp_eq(struct mlx5_core_dev *dev, int eqn) 913 911 {