Skip to content

Commit 7ec5691

Browse files
Binary-Eaterkuba-moo
authored andcommitted
net/mlx5e: Move DIM function declarations to en/dim.h
Create a header specifically for DIM-related declarations. Move existing DIM-specific functionality from en.h. Future DIM-related functionality will be declared in en/dim.h in subsequent patches. Co-developed-by: Nabil S. Alramli <dev@nalramli.com> Signed-off-by: Nabil S. Alramli <dev@nalramli.com> Co-developed-by: Joe Damato <jdamato@fastly.com> Signed-off-by: Joe Damato <jdamato@fastly.com> Signed-off-by: Rahul Rameshbabu <rrameshbabu@nvidia.com> Signed-off-by: Tariq Toukan <tariqt@nvidia.com> Link: https://lore.kernel.org/r/20240419080445.417574-2-tariqt@nvidia.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
1 parent b240fc5 commit 7ec5691

File tree

5 files changed

+18
-3
lines changed

5 files changed

+18
-3
lines changed

drivers/net/ethernet/mellanox/mlx5/core/en.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1210,8 +1210,6 @@ int mlx5e_netdev_change_profile(struct mlx5e_priv *priv,
12101210
void mlx5e_netdev_attach_nic_profile(struct mlx5e_priv *priv);
12111211
void mlx5e_set_netdev_mtu_boundaries(struct mlx5e_priv *priv);
12121212
void mlx5e_build_nic_params(struct mlx5e_priv *priv, struct mlx5e_xsk *xsk, u16 mtu);
1213-
void mlx5e_rx_dim_work(struct work_struct *work);
1214-
void mlx5e_tx_dim_work(struct work_struct *work);
12151213

12161214
void mlx5e_set_xdp_feature(struct net_device *netdev);
12171215
netdev_features_t mlx5e_features_check(struct sk_buff *skb,
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
/* SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB */
2+
/* Copyright (c) 2023, NVIDIA CORPORATION & AFFILIATES. All rights reserved */
3+
4+
#ifndef __MLX5_EN_DIM_H__
5+
#define __MLX5_EN_DIM_H__
6+
7+
#include <linux/types.h>
8+
9+
/* Forward declarations */
10+
struct work_struct;
11+
12+
void mlx5e_rx_dim_work(struct work_struct *work);
13+
void mlx5e_tx_dim_work(struct work_struct *work);
14+
15+
#endif /* __MLX5_EN_DIM_H__ */

drivers/net/ethernet/mellanox/mlx5/core/en_dim.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,8 @@
3030
* SOFTWARE.
3131
*/
3232

33-
#include <linux/dim.h>
3433
#include "en.h"
34+
#include "en/dim.h"
3535

3636
static void
3737
mlx5e_complete_dim_work(struct dim *dim, struct dim_cq_moder moder,

drivers/net/ethernet/mellanox/mlx5/core/en_ethtool.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@
3333
#include <linux/ethtool_netlink.h>
3434

3535
#include "en.h"
36+
#include "en/dim.h"
3637
#include "en/port.h"
3738
#include "en/params.h"
3839
#include "en/ptp.h"

drivers/net/ethernet/mellanox/mlx5/core/en_main.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@
4343
#include <net/xdp_sock_drv.h>
4444
#include "eswitch.h"
4545
#include "en.h"
46+
#include "en/dim.h"
4647
#include "en/txrx.h"
4748
#include "en_tc.h"
4849
#include "en_rep.h"

0 commit comments

Comments
 (0)