cxgb4: Move ethtool related code to a separate file
Subsystems (4)
PATCH 1/1 cxgb4: Move ethtool related code to a separate file
--- drivers/net/ethernet/chelsio/cxgb4/Makefile | 2 +- drivers/net/ethernet/chelsio/cxgb4/cxgb4.h | 47 + drivers/net/ethernet/chelsio/cxgb4/cxgb4_ethtool.c | 915 +++++++++++ drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c | 1618 +------------------- drivers/net/ethernet/chelsio/cxgb4/t4_hw.c | 728 +++++++++ 5 files changed, 1702 insertions(+), 1608 deletions(-) create mode 100644 drivers/net/ethernet/chelsio/cxgb4/cxgb4_ethtool.c
drivers/net/ethernet/chelsio/cxgb4/Makefile +1 -1
@@ -4,7 +4,7 @@ obj-$(CONFIG_CHELSIO_T4) += cxgb4.o -cxgb4-objs := cxgb4_main.o l2t.o t4_hw.o sge.o clip_tbl.o +cxgb4-objs := cxgb4_main.o l2t.o t4_hw.o sge.o clip_tbl.o cxgb4_ethtool.o cxgb4-$(CONFIG_CHELSIO_T4_DCB) += cxgb4_dcb.o cxgb4-$(CONFIG_CHELSIO_T4_FCOE) += cxgb4_fcoe.o cxgb4-$(CONFIG_DEBUG_FS) += cxgb4_debugfs.o
drivers/net/ethernet/chelsio/cxgb4/cxgb4.h +47 -0
77 lines not on this page · raw message
drivers/net/ethernet/chelsio/cxgb4/cxgb4_ethtool.c new file +915 -0
915 lines not on this page · raw message
drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c +11 -1607
1,691 lines not on this page · raw message
drivers/net/ethernet/chelsio/cxgb4/t4_hw.c +728 -0
309 lines not on this page · raw message
The rest of this diff is not shown. View the raw message.
Signature · 1 line
2.3.4
Part of the diff is not shown here. View the raw message.
Quoted 1 line · Hariprasad Shenai
Signed-off-by Hariprasad Shenai <[email protected]>
A couple trivial bits:
drivers/net/ethernet/chelsio/cxgb4/cxgb4_ethtool.c
Quoted 1 line
drivers/net/ethernet/chelsio/cxgb4/cxgb4_ethtool.c +0
-0
[]
drivers/net/ethernet/chelsio/cxgb4/cxgb4_ethtool.c line 2
Quoted 4 lines
+++
b/drivers/net/ethernet/chelsio/cxgb4/cxgb4_ethtool.cdrivers/net/ethernet/chelsio/cxgb4/cxgb4_ethtool.c +2
-0@@ -0,0 +1,915 @@ +/* +* Copyright (C) 2013-2014 Chelsio Communications. All rights reserved.
2015 ?
[]
drivers/net/ethernet/chelsio/cxgb4/cxgb4_ethtool.c line 37
Quoted 1 line
drivers/net/ethernet/chelsio/cxgb4/cxgb4_ethtool.c +1
-0+static char stats_strings[][ETH_GSTRING_LEN ] = {
be nice to make this const one day.
Quoted 6 lines
drivers/net/ethernet/chelsio/cxgb4/cxgb4_ethtool.c +6
-0+"TxOctetsOK " , +"TxFramesOK " , +"TxBroadcastFrames " , +"TxMulticastFrames " , +"TxUnicastFrames " , + "TxErrorFrames ",
PATCH 1/1 chelsio cxgb/cxgb3: Make stats_strings arrays const
Move ~2KB of strings in each driver from data to text.
---
Here a patch for the other 2 drivers
drivers/net/ethernet/chelsio/cxgb/cxgb2.c | 2 +- drivers/net/ethernet/chelsio/cxgb3/cxgb3_main.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
drivers/net/ethernet/chelsio/cxgb/cxgb2.c +1 -1
@@ -354,7 +354,7 @@ static void set_msglevel(struct net_device *dev, u32 val) adapter->msg_enable = val; } -static char stats_strings[][ETH_GSTRING_LEN ] = { +static const char stats_strings[][ETH_GSTRING_LEN ] = {"TxOctetsOK" ,"TxOctetsBad" ,"TxUnicastFramesOK" ,
drivers/net/ethernet/chelsio/cxgb3/cxgb3_main.c +1 -1
@@ -1537,7 +1537,7 @@ static void set_msglevel(struct net_device *dev, u32 val) adapter->msg_enable = val; } -static char stats_strings[][ETH_GSTRING_LEN ] = { +static const char stats_strings[][ETH_GSTRING_LEN ] = {"TxOctetsOK " ,"TxFramesOK " ,"TxMulticastFramesOK" ,
Re: [PATCH net-next] chelsio cxgb/cxgb3: Make stats_strings arrays const
From: Joe Perches <[email protected]>
Date: Wed, 01 Apr 2015 08:49:24 -0700
Quoted 6 lines
Move ~2KB of strings in each driver from data to text.
Signed-off-by Joe Perches <[email protected]>---
Here a patch for the other 2 drivers
Applied, thanks Joe.