Skip to content

Commit

Permalink
linux/dim: Move implementation to .c files
Browse files Browse the repository at this point in the history
Moved all logic from dim.h and net_dim.h to dim.c and net_dim.c.
This is both more structurally appealing and would allow to only
expose externally used functions.

Signed-off-by: Tal Gilboa <[email protected]>
Signed-off-by: Saeed Mahameed <[email protected]>
  • Loading branch information
talgimellanox authored and Saeed Mahameed committed Jun 25, 2019
1 parent 8960b38 commit 4f75da3
Show file tree
Hide file tree
Showing 17 changed files with 547 additions and 345 deletions.
2 changes: 1 addition & 1 deletion MAINTAINERS
Original file line number Diff line number Diff line change
Expand Up @@ -5588,8 +5588,8 @@ F: include/linux/dynamic_debug.h
DYNAMIC INTERRUPT MODERATION
M: Tal Gilboa <[email protected]>
S: Maintained
F: include/linux/net_dim.h
F: include/linux/dim.h
F: lib/dim/

DZ DECSTATION DZ11 SERIAL DRIVER
M: "Maciej W. Rozycki" <[email protected]>
Expand Down
1 change: 1 addition & 0 deletions drivers/net/ethernet/broadcom/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ config NET_VENDOR_BROADCOM
default y
depends on (SSB_POSSIBLE && HAS_DMA) || PCI || BCM63XX || \
SIBYTE_SB1xxx_SOC
select DIMLIB
---help---
If you have a network (Ethernet) chipset belonging to this class,
say Y.
Expand Down
2 changes: 1 addition & 1 deletion drivers/net/ethernet/broadcom/bcmsysport.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
#include <linux/bitmap.h>
#include <linux/ethtool.h>
#include <linux/if_vlan.h>
#include <linux/net_dim.h>
#include <linux/dim.h>

/* Receive/transmit descriptor format */
#define DESC_ADDR_HI_STATUS_LEN 0x00
Expand Down
2 changes: 1 addition & 1 deletion drivers/net/ethernet/broadcom/bnxt/bnxt.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
#include <net/devlink.h>
#include <net/dst_metadata.h>
#include <net/xdp.h>
#include <linux/net_dim.h>
#include <linux/dim.h>

struct tx_bd {
__le32 tx_bd_len_flags_type;
Expand Down
2 changes: 1 addition & 1 deletion drivers/net/ethernet/broadcom/bnxt/bnxt_debugfs.c
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
#include <linux/module.h>
#include <linux/pci.h>
#include "bnxt_hsi.h"
#include <linux/net_dim.h>
#include <linux/dim.h>
#include "bnxt.h"
#include "bnxt_debugfs.h"

Expand Down
2 changes: 1 addition & 1 deletion drivers/net/ethernet/broadcom/bnxt/bnxt_dim.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* the Free Software Foundation.
*/

#include <linux/net_dim.h>
#include <linux/dim.h>
#include "bnxt_hsi.h"
#include "bnxt.h"

Expand Down
2 changes: 1 addition & 1 deletion drivers/net/ethernet/broadcom/genet/bcmgenet.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
#include <linux/mii.h>
#include <linux/if_vlan.h>
#include <linux/phy.h>
#include <linux/net_dim.h>
#include <linux/dim.h>

/* total number of Buffer Descriptors, same for Rx/Tx */
#define TOTAL_DESC 256
Expand Down
1 change: 1 addition & 0 deletions drivers/net/ethernet/mellanox/mlx5/core/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ config MLX5_CORE_EN
depends on NETDEVICES && ETHERNET && INET && PCI && MLX5_CORE
depends on IPV6=y || IPV6=n || MLX5_CORE=m
select PAGE_POOL
select DIMLIB
default n
---help---
Ethernet support in Mellanox Technologies ConnectX-4 NIC.
Expand Down
2 changes: 1 addition & 1 deletion drivers/net/ethernet/mellanox/mlx5/core/en.h
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
#include <linux/rhashtable.h>
#include <net/switchdev.h>
#include <net/xdp.h>
#include <linux/net_dim.h>
#include <linux/dim.h>
#include <linux/bits.h>
#include "wq.h"
#include "mlx5_core.h"
Expand Down
2 changes: 1 addition & 1 deletion drivers/net/ethernet/mellanox/mlx5/core/en_dim.c
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
* SOFTWARE.
*/

#include <linux/net_dim.h>
#include <linux/dim.h>
#include "en.h"

static void
Expand Down
Loading

0 comments on commit 4f75da3

Please sign in to comment.