Commit graph

18 commits

Author SHA1 Message Date
Hariprasad Shenai e894d720a5 cxgb4: Pass correct argument to t4_link_l1cfg()
Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2015-12-23 22:34:44 -05:00
Hariprasad Shenai 0bf9a7d617 cxgb4: Align rest of the ethtool get stats
Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2015-12-08 22:43:14 -05:00
Hariprasad Shenai b08f2b3569 cxgb4: Update ethtool get_drvinfo to get regdump len
Update ethtool get_drvinfo to display regdump len and also update
firmware string version print to display N/A in case FW isn't present

Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2015-10-22 07:04:02 -07:00
Hariprasad Shenai 9c673d1562 cxgb4: Use vmalloc, if kmalloc fails
Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2015-10-22 07:03:58 -07:00
Hariprasad Shenai 6ac5fe75df cxgb4: Return error if setup_rss is called before probe
Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2015-10-22 07:03:57 -07:00
Hariprasad Shenai 4116542897 cxgb4: Restore L1 cfg, if FW rejects new L1 cfg settings
In the ethtool set_settings() routine we need to remember our old L1
Configuration in case the firmware rejects the request and then restore
that.

Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2015-10-22 07:03:50 -07:00
Hariprasad Shenai 9bfdad5ef5 cxgb4: Don't disallow turning off auto-negotiation
For {1, 10, 40} Gb/s. Prohibiting turning off autonegotiation isn't anywhere
in the standard.

Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2015-10-22 07:03:50 -07:00
Hariprasad Shenai eed7342d4b cxgb4: Align ethtool get stat settings
Align the ethtool get stats settings with the rest so it looks uniform

Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2015-10-22 07:03:49 -07:00
Hariprasad Shenai 5e2a5ebc3f cxgb4: Add HW timesptamp support for RX
Adds support for ethtool get time stamp ioctl, which is used by
tcpdump to get the supported time stamp types

eg: tcpdump -i eth5 -J
Time stamp types for eth5 (use option -j to set):
  host (Host)
  adapter_unsynced (Adapter, not synced with system time)

Adds support for adapter unsynced mode, by adding SIOCSHWTSTAMP support
in driver.

Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2015-09-28 22:35:29 -07:00
Hariprasad Shenai 402b764533 cxgb4: Allow firmware flash, only if cxgb4 is the master driver
Adapter can go for a toss, if cxgb4 is loaded as slave and we try to
upgrade the firmware. So add a check for the same before flashing
firmware using ethtool.

Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2015-07-26 16:37:41 -07:00
Hariprasad Shenai 4036da9012 cxgb4: Rename t4_link_start() to t4_link_l1cfg
t4_link_start() was completely misnamed.  It does _not_ start up the
link. It merely does the L1 Configuration for the link. The Link Up
process is started automatically by the firmware when the number of
enabled Virtual Interfaces on a port goes from 0 to 1. So renaming
this routine to t4_link_l1cfg() for better documentation.

Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2015-06-05 21:25:57 -07:00
Hariprasad Shenai e2d14b42c2 cxgb4: Remove WOL get/set ethtool support
Remove ethtool get/set support for wake on lan, adapter doesn't support
it.

Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2015-06-03 23:40:19 -07:00
Hariprasad Shenai 65046e8414 cxgb4: Add support to dump loopback port stats
Add support in ethtool to dump loopback port statistics

Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2015-06-03 23:40:19 -07:00
Hariprasad Shenai a622297535 cxgb4: Add support in ethtool to dump channel stats
Add support in ethtool to dump adapter channel stats

Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2015-06-03 23:40:19 -07:00
Hariprasad Shenai a4cfd929c9 cxgb4: Add ethtool support to get adapter stats
Add ethtool support to get adapter specific hardware statistics

Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2015-06-03 23:40:19 -07:00
Hariprasad Shenai b261272276 cxgb4/cxgb4vf: function and argument name cleanup
This patch changes variable name 'fn' to 'pf' of structure adapter.
A 'fn' usually stands for PCI function which could be a PF or a VF.
However, the use of this particular variable is explicitly limited to PF
only. So, be specific about it in the variable name.

Also corrects arguments passed for fn t4_ofld_eq_free, t4_ctrl_eq_free,
t4_eth_eq_free, t4_iq_free, t4_alloc_vi, t4_fw_hello, t4_wr_mbox and
t4_cfg_pfvf function.

Also renames cxgb4_t4_bar2_sge_qregs to t4_bar2_sge_qregs and renames
the latter function name in cxgb4vf driver to t4vf_bar2_sge_qregs to
avoid conflicts. Also fixes alignment for these function.

Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2015-05-27 14:26:37 -04:00
Hariprasad Shenai 1ecc7b7a59 cxgb4/cxgb4vf: Cleanup macros, add comments and add new MACROS
Cleanup few MACROS left out in t4_hw.h to be consistent with the
existing ones. Also replace few hardcoded values with MACROS. Also
update comments for some code

Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2015-05-12 23:11:40 -04:00
Hariprasad Shenai 812034f116 cxgb4: Move ethtool related code to a separate file
Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2015-04-07 17:38:54 -04:00