aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/emulex/benet/be_ethtool.c
AgeCommit message (Collapse)Author
2013-10-01be2net: add a counter for pkts dropped in xmit pathSathya Perla
In the xmit path, the driver may drop some pkts due to reasons such as DMA mapping errors, out of memory conditions or to protect HW from unrecoverable errors. Add a counter in TX-stats for such drops. Signed-off-by: Sathya Perla <sathya.perla@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2013-10-01be2net: fix adaptive interrupt coalescingSathya Perla
The current EQ delay calculation for AIC is based only on RX packet rate. This fails to be effective when there's only TX and no RX. This patch inclues: - Calculating EQ-delay based on both RX and TX pps. - Modifying EQ-delay of all EQs via one cmd, instead of issuing a separate cmd for each EQ. - A new structure to store interrupt coalescing parameters, in a separate cache-line from the EQ-obj. Signed-off-by: Sathya Perla <sathya.perla@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2013-08-27be2net: implement ethtool set/get_channel hooksSathya Perla
Support is provided only for combined channels. When SR-IOV is not enabled, BE3 supports upto 16 channels and Lancer-R/SH-R support upto 32 channels. Signed-off-by: Sathya Perla <sathya.perla@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2013-05-31be2net: Implement initiate FW dump feature for LancerSomnath Kotur
Added code to initiate FW dump via ethtool. Driver checks if the previous dump has been cleared before initiating the dump. It doesn't initiate the dump if it is not cleared. Signed-off-by: Kalesh AP <kalesh.purayil@emulex.com> Signed-off-by: Somnath Kotur <somnath.kotur@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2013-05-27be2net: cleanup be_get_drvinfo()Somnath Kotur
Removing the be_cmd_get_fw_ver() query from be_get_drvinfo() and invoking the same from be_setup() and/or post firmware download. Signed-off-by: Kalesh AP <kalesh.purayil@emulex.com> Signed-off-by: Somnath Kotur <somnath.kotur@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2013-05-02be2net: Fix to show tx priority pause counter in ethtool -SAjit Khaparde
The tx priority pause count is available with the driver. But we were not showing it. This change should fix it and display it in ethtool stats. Signed-off-by: Ajit Khaparde <ajit.khaparde@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2013-04-30Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/netDavid S. Miller
Conflicts: drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c drivers/net/ethernet/emulex/benet/be.h include/net/tcp.h net/mac802154/mac802154.h Most conflicts were minor overlapping stuff. The be2net driver brought in some fixes that added __vlan_put_tag calls, which in net-next take an additional argument. Signed-off-by: David S. Miller <davem@davemloft.net>
2013-04-29be2net: Fix to show wol disabled/enabled state correctly.Sarveshwar Bandi
Signed-off-by: Sarveshwar Bandi <sarveshwar.bandi@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2013-04-26be2net: Avoid diagnostic test in certain versions of firmware to avoid NIC ↵Suresh Reddy
freeze. Signed-off-by: Suresh Reddy <suresh.reddy@emulex.com> Signed-off-by: Sarveshwar Bandi <sarveshwar.bandi@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2013-04-26be2net: Renamed rx_address_mismatch_errors to rx_address_filteredSuresh Reddy
Signed-off-by: Suresh Reddy <suresh.reddy@emulex.com> Signed-off-by: Sarveshwar Bandi <sarveshwar.bandi@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2013-04-26be2net: Add support for setting and getting rx flow hash optionsSuresh Reddy
Signed-off-by: Suresh Reddy <suresh.reddy@emulex.com> Signed-off-by: Sarveshwar Bandi <sarveshwar.bandi@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2013-03-15drivers:net: Remove dma_alloc_coherent OOM messagesJoe Perches
I believe these error messages are already logged on allocation failure by warn_alloc_failed and so get a dump_stack on OOM. Remove the unnecessary additional error logging. Around these deletions: o Alignment neatening. o Remove unnecessary casts of dma_alloc_coherent. o Hoist assigns from ifs. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2013-03-07be2net: Update copyright yearVasundhara Volam
Signed-off-by: Vasundhara Volam <vasundhara.volam@emulex.com> Signed-off-by: Sarveshwar Bandi <sarveshwar.bandi@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2013-01-06ethtool: fix drvinfo strings set in driversJiri Pirko
Use strlcpy where possible to ensure the string is \0 terminated. Use always sizeof(string) instead of 32, ETHTOOL_BUSINFO_LEN and custom defines. Use snprintf instead of sprint. Remove unnecessary inits of ->fw_version Remove unnecessary inits of drvinfo struct. Signed-off-by: Jiri Pirko <jiri@resnulli.us> Signed-off-by: David S. Miller <davem@davemloft.net>
2012-10-21be2net: Fix ethtool get_settings output for VFPadmanabh Ratnakar
Return default values for fields for which VFs dont have privilege to get the required information from FW. Signed-off-by: Padmanabh Ratnakar <padmanabh.ratnakar@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2012-10-21be2net: Fix error messages while driver load for VFsPadmanabh Ratnakar
VF does not have privileges to execute many commands. When VFs try to execute those commands there are unnecessary error messages. Fix this by executing only those commands for which VF has privilege. Signed-off-by: Padmanabh Ratnakar <padmanabh.ratnakar@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2012-09-30be2net: cleanup code related to be_link_status_query()Sathya Perla
1) link_status_query() is always called to query the link-speed (speed after applying qos). When there is no qos setting, link-speed is derived from port-speed. Do all this inside this routine and hide this from the callers. 2) adpater->phy.forced_port_speed is not being set anywhere after being initialized. Get rid of this variable. 3) Ignore async link_speed notifications till the initial value has been fetched from FW. Signed-off-by: Sathya Perla <sathya.perla@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2012-07-25be2net: Missing byteswap in be_get_fw_log_level causes oops on PowerPCAnton Blanchard
We are seeing an oops in be_get_fw_log_level on ppc64 where we walk off the end of memory. commit 941a77d582c8 (be2net: Fix to allow get/set of debug levels in the firmware.) requires byteswapping of num_modes and num_modules. Cc: stable@vger.kernel.org # 3.5+ Signed-off-by: Anton Blanchard <anton@samba.org> Acked-by: Sathya Perla <sperla@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2012-07-12be2net: Fix error while toggling autoneg of pause parametersPadmanabh Ratnakar
Autonegotiation of pause parameters is possible only on some PHYs. Ability of autoneg of pause parameters is reported by adapter. Autoneg of pause parameters cannot be changed from driver. Fix driver to give error when autoneg mode is toggled by user. Signed-off-by: Padmanabh Ratnakar <padmanabh.ratnakar@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2012-05-18be2net: Fix to allow get/set of debug levels in the firmware.Somnath Kotur
Patch re-spin. Incorporated review comments by Ben Hutchings. Signed-off-by: Suresh Reddy <suresh.reddy@emulex.com> Signed-off-by: Somnath Kotur <somnath.kotur@emulex.com> Acked-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2012-05-02be2net: Fix to apply duplex value as unknown when link is down.Somnath Kotur
Suggested-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: Sarveshwar Bandi <sarveshwar.bandi@emulex.com> Signed-off-by: Somnath Kotur <somnath.kotur@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2012-05-02be2net: Fix to not set link speed for disabled functions of a UMC cardSomnath Kotur
This renders the interface view somewhat inconsistent from the Host OS POV considering the rest of the interfaces are showing their respective speeds based on the bandwidth assigned to them. Signed-off-by: Somnath Kotur <somnath.kotur@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2012-04-27be2net: fix speed displayed by ethtool on certain SKUsAjit Khaparde
logical speed returned by link_status_query needs to be multiplied by 10. Signed-off-by: Ajit Khaparde <ajit.khaparde@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2012-04-26be2net: Fix ethtool self test for LancerPadmanabh Ratnakar
Lancer does not support DDR self test. Fix ethtool self test by skipping this test for Lancer. Signed-off-by: Padmanabh Ratnakar <padmanabh.ratnakar@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2012-04-23be2net: fix ethtool get settingsAjit Khaparde
ethtool get settings was not displaying all the settings correctly. use the get_phy_info to get more information about the PHY to fix this. Signed-off-by: Ajit Khaparde <ajit.khaparde@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2012-03-19be2net: enable WOL by default if h/w supports itAjit Khaparde
Signed-off-by: Ajit Khaparde <ajit.khaparde@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2012-02-13be2net: event queue re-designSathya Perla
v2: Fixed up the bad typecasting pointed out by David... In the current design 8 TXQs are serviced by 1 EQ, while each RSS queue is serviced by a separate EQ. This is being changed as follows: - Upto 8 EQs will be used (based on the availabilty of msix vectors). Each EQ will handle 1 RSS and 1 TX ring. The default non-RSS RX queue and MCC queue are handled by the last EQ. - On cards which provide support, upto 8 RSS rings will be used, instead of the current limit of 4. The new design allows spreading the TX multi-queue completion processing across multiple CPUs unlike the previous design. Signed-off-by: Sathya Perla <sathya.perla@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2012-02-04Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/netDavid S. Miller
2012-02-01ethtool: Null-terminate filename passed to ethtool_ops::flash_deviceBen Hutchings
The parameters for ETHTOOL_FLASHDEV include a filename, which ought to be null-terminated. Currently the only driver that implements ethtool_ops::flash_device attempts to add a null terminator if necessary, but does it wrongly. Do it in the ethtool core instead. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2012-02-01be2net: add descriptions for stat counters reported via ethtoolSathya Perla
Also rename a few counters appropritely and delete 2 counters that are not implemented in HW. vlan_mismatch_drops does not exist in BE3 and is accounted for in address_mismatch_drops. Do the same thing for BE2 and Lancer. Signed-off-by: Sathya Perla <sathya.perla@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-12-30be2net: query link status in be_open()Ajit Khaparde
be2net gets an async link status notification from the FW when it creates an MCC queue. There are some cases in which this gratuitous notification is not received from FW. To cover this explicitly query the link status in be_open(). Signed-off-by: Vasundhara Volam <vasundhara.volam@emulex.com> Signed-off-by: Sathya Perla <sathya.perla@emulex.com> Signed-off-by: Ajit Khaparde <ajit.khaparde@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-12-13be2net: fix ethtool ringparam reportingSathya Perla
The ethtool "-g" option is supposed to report the max queue length and user modified queue length for RX and TX queues. be2net doesn't support user modification of queue lengths. So, the correct values for these would be the max numbers. be2net incorrectly reports the queue used values for these fields. Signed-off-by: Sathya Perla <sathya.perla@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-16be2net: Add EEPROM dump feature for LancerPadmanabh Ratnakar
Implemented eeprom dump using ethtool feature for Lancer. Signed-off-by: Padmanabh Ratnakar <padmanabh.ratnakar@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-16be2net: add register dump feature for LancerPadmanabh Ratnakar
Implement register dump using ethtool for Lancer. Signed-off-by: Padmanabh Ratnakar <padmanabh.ratnakar@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-11-08sweep the floors and convert some .get_drvinfo routines to strlcpyRick Jones
Per the mention made by Ben Hutchings that strlcpy is now the preferred string copy routine for a .get_drvinfo routine, do a bit of floor sweeping and convert some of the as-yet unconverted ethernet drivers to it. Signed-off-by: Rick Jones <rick.jones2@hp.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-09-27be2net: Show newly flashed FW ver in ethtoolSathya Perla
This fix provides a newly flashed FW version (appended, in braces) along with the currently running FW version via ethtool. The newly flashed version runs only after a system reset. Signed-off-by: Suresh Reddy <Suresh.Reddy@emulex.com> Signed-off-by: Sathya Perla <sathya.perla@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-08-11be2net: Move the Emulex driverJeff Kirsher
Moves the Emulex driver into drivers/net/ethernet/emulex/ and make the necessary Kconfig and Makefile changes. CC: Sathya Perla <sathya.perla@emulex.com> CC: Subbu Seetharaman <subbu.seetharaman@emulex.com> CC: Ajit Khaparde <ajit.khaparde@emulex.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>