summaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/intel/igb/igb_ethtool.c
Commit message (Collapse)AuthorAgeFilesLines
...
* igb: Support for modifying UDP RSS flow hashingAkeem G. Abodunrin2012-11-131-0/+181
| | | | | | | | | | | This patch provides ability to enable or disable UDP RSS hashing. It gives users option of generating RSS hash based on the UDP source and destination ports numbers. Currently, UDP flow hash is always disabled in igb-driver. Signed-off-by: Akeem G Abodunrin <akeem.g.abodunrin@intel.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* ptp: Enable clock drivers along with associated net/PHY driversBen Hutchings2012-11-011-2/+0
| | | | | | | | | | | | | | | | Where a PTP clock driver is associated with a net or PHY driver, it should be enabled automatically whenever that driver is enabled. Therefore: - Make PTP clock drivers select rather than depending on PTP_1588_CLOCK - Remove separate boolean options for PTP clock drivers that are built as part of net driver modules. (This also fixes cases where the PTP subsystem is wrongly forced to be built-in.) - Set 'default y' for PTP clock drivers that depend on specific net drivers but are built separately Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* igb: Lock buffer size at 2K even on systems with larger pagesAlexander Duyck2012-10-191-2/+2
| | | | | | | | | | This change locks us in at 2K buffers even on a system that supports larger frames. The reason for this change is to make better use of pages and to reduce the overall truesize of frames generated by igb. Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
* igb: Map entire page and sync half instead of mapping and unmapping half pagesAlexander Duyck2012-10-191-13/+13
| | | | | | | | | | This change makes it so that we map the entire page and just sync half of it for the device at a time. The advantage to this approach is that we can avoid the locking on map/unmap seen in many IOMMU implementations. Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
* igb: Do not use header split, instead receive all frames into a single bufferAlexander Duyck2012-10-191-11/+20
| | | | | | | | | | | | This change makes it so that we no longer use header split. The idea is to reduce partial cache line writes by hardware when handling frames larger then header size. We can compensate for the extra overhead of having to memcpy the header buffer by avoiding the cache misses seen by leaving an full skb allocated and sitting on the ring. Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
* igb: Correct PTP support query from ethtool.Matthew Vick2012-09-171-24/+38
| | | | | | | | | | | | | | | Update ethtool_get_ts_info to not report any supported functionality on 82575 and add support for V2 Sync and V2 Delay packets. In the case where CONFIG_IGB_PTP is not defined, we should be reporting default values. v2: Correct the function to return EOPNOTSUPP when there is no PTP support or the device does not support PTP. Also fix minor whitespace issue. Signed-off-by: Matthew Vick <matthew.vick@intel.com> Cc: Richard Cochran <richardcochran@gmail.com> Tested-by: Jeff Pieper <jeffrey.e.pieper@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
* igb: Update PTP function names/variables and locations.Matthew Vick2012-09-171-17/+17
| | | | | | | | | | | Where possible, move PTP-related functions into igb_ptp.c and update the names of functions and variables to match the established coding style in the files and specify that they are PTP-specific. Cc: Richard Cochran <richardcochran@gmail.com> Signed-off-by: Matthew Vick <matthew.vick@intel.com> Tested-by: Jeff Pieper <jeffrey.e.pieper@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
* igb: Tidy up wrapping for CONFIG_IGB_PTP.Matthew Vick2012-09-171-2/+2
| | | | | | | | | | | For users without CONFIG_IGB_PTP=y, we should not be compiling any PTP code into the driver. Tidy up the wrapping in igb to support this. Cc: Richard Cochran <richardcochran@gmail.com> Signed-off-by: Matthew Vick <matthew.vick@intel.com> Acked-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Jeff Pieper <jeffrey.e.pieper@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
* igb: Supported and Advertised Pause FrameAkeem G. Abodunrin2012-09-041-3/+18
| | | | | | | | | This patch add ethtool supports for Supported and Advertised Pause Frame, based on Adapter Flow Control settings. Signed-off-by: Akeem G. Abodunrin <akeem.g.abodunrin@intel.com> Tested-by: Jeff Pieper <jeffrey.e.pieper@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
* igb: Add loopback test support for i210Carolyn Wyborny2012-09-041-35/+16
| | | | | | | | | Early release of i210 devices had the loopback test of the ethtool self-test disabled. This patch enables the loopback test for i210 devices. Signed-off-by: Carolyn Wyborny <carolyn.wyborny@intel.com> Tested-by: Jeff Pieper <jeffrey.e.pieper@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
* Merge branch 'master' of ↵David S. Miller2012-08-221-0/+42
|\ | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/net-next Jeff Kirsher says: ==================== This series contains updates to ethtool.h, e1000, e1000e, and igb to implement MDI/MDIx control. ==================== Signed-off-by: David S. Miller <davem@davemloft.net>
| * igb: update to allow reading/setting MDI stateJesse Brandeburg2012-08-211-0/+42
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This is the implementation for igb to allow forcing MDI state via ethtool, allowing users to work around some improperly behaving switches. Forcing in this driver is for now only allowed when auto-neg is enabled. Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com> CC: Carolyn Wyborny <carolyn.wyborny@intel.com> Tested-by: Aaron Brown aaron.f.brown@intel.com Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
* | igb: add delay to allow igb loopback test to succeed on 8086:10c9Stefan Assmann2012-08-071-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some 8086:10c9 NICs have a problem completing the ethtool loopback test. The result looks like this: ethtool -t eth1 The test result is FAIL The test extra info: Register test (offline) 0 Eeprom test (offline) 0 Interrupt test (offline) 0 Loopback test (offline) 13 Link test (on/offline) 0 A bisect clearly points to commit a95a07445ee97a2fef65befafbadcc30ca1bd145. However that seems to only trigger the bug. While adding some printk the problem disappeared, so this might be a timing issue. After some trial and error I discovered that adding a small delay just before igb_write_phy_reg() in igb_integrated_phy_loopback() allows the loopback test to succeed. I was unable to figure out the root cause so far but I expect it to be somewhere in the following executing path igb_integrated_phy_loopback ->igb_write_phy_reg_igp ->igb_write_phy_reg_mdic ->igb_acquire_phy_82575 ->igb_acquire_swfw_sync_82575 The problem could only be observed on 8086:10c9 NICs so far and not all of them show the behaviour. I did not restrict the workaround to this type of NIC as it should do no harm to other igb NICs. With the patch below the loopback test succeeded 500 times in a row using a NIC that would otherwise fail. Signed-off-by: Stefan Assmann <sassmann@kpanic.de> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
* | igb: don't break user visible strings over multiple lines in igb_ethtool.cJesper Juhl2012-08-041-12/+11
| | | | | | | | | | | | | | | | | | Even when they go beyond 80 characters, user visible strings should be on one line to make them easy to grep for. Signed-off-by: Jesper Juhl <jj@chaosbits.net> Tested-by: Jeff Pieper <jeffrey.e.pieper@intel.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
* | igb: correct hardware type (i210/i211) check in igb_loopback_test()Jesper Juhl2012-08-041-1/+1
|/ | | | | | | | | | | | | | | In the original code ... if ((adapter->hw.mac.type == e1000_i210) || (adapter->hw.mac.type == e1000_i210)) { ... the second check of 'adapter->hw.mac.type' is pointless since it tests for the exact same value as the first. Signed-off-by: Jesper Juhl <jj@chaosbits.net> Acked-by: Carolyn Wyborny <carolyn.wyborny@intel.com> Tested-by: Jeff Pieper <jeffrey.e.pieper@intel.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
* igb: Update firmware info outputCarolyn Wyborny2012-06-201-10/+7
| | | | | | | | | | | | | Our NVM image creation tools have evolved over the years and there are multiple versions contained in them, depending on the tool used to create them. This patch outputs the NVM versions available in ethtool -i output. rc2: (not sure why others show in log but not in the message) Added additional call to igb_set_fw_version per Community feedback. Signed-off-by: Carolyn Wyborny <carolyn.wyborny@intel.com> Tested-by: Jeff Pieper <jeffrey.e.pieper@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
* igb: Support the get_ts_info ethtool method.Carolyn Wyborny2012-06-201-0/+35
| | | | | | | | | | | | Based on original patch from Richard Cochran <richardcochran@gmail.com> Original patch caused build errors without CONFIG_IGB_1588_CLOCK and CONFIG_PPS enabled, since the added code was not properly wrapped. CC: Richard Cochran <richardcochran@gmail.com> Signed-off-by: Carolyn Wyborny <carolyn.wyborny@intel.com> Tested-by: Jeff Pieper <jeffrey.e.pieper@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
* igb: Add Support for new i210/i211 devices.Carolyn Wyborny2012-05-121-25/+78
| | | | | | | | | This patch adds new initialization functions and device support for i210 and i211 devices. Signed-off-by: Carolyn Wyborny <carolyn.wyborny@intel.com> Tested-by: Jeff Pieper <jeffrey.e.pieper@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
* igb: output register's information related to RX/TX queue[4-15]Koki Sanagi2012-05-091-1/+37
| | | | | | | | | | | | Current igb outputs registers related to TX/RX queues(ex. RDT, RDH, TDT, TDH). But it thinks the number of RX/TX queues is 4. But 82576 has 16 RX/TX queues. This patch modifies igb to output the rest of the registers if the device is 82576. Signed-off-by: Koki Sanagi <sanagi.koki@jp.fujitsu.com> Acked-by: Carolyn Wyborny <carolyn.wyborny@intel.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
* igb: fix ethtool offline testJeff Kirsher2012-03-121-0/+7
| | | | | | | | | | | | | | | | A bug was introduced with the following patch: Commmit bdbc063129e811264cd6c311d8c2d9b95de01231 Author: Eric Dumazet <eric.dumazet@gmail.com> igb: Add support for byte queue limits. The ethtool offline tests will cause a perpetual link flap, this is because the tests also need to account for byte queue limits (BQL). CC: Eric Dumazet <eric.dumazet@gmail.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: John Fastabend <john.r.fastabend@intel.com> Tested-by: Jeff Pieper <jeffrey.e.pieper@intel.com>
* igb: Update Copyright on all Intel copyrighted files.Carolyn Wyborny2012-01-191-1/+1
| | | | | | | Signed-off-by: Carolyn Wyborny <carolyn.wyborny@intel.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* igb: add basic runtime PM supportYan, Zheng2012-01-051-0/+16
| | | | | | | | | | | | | | | | | | Use the runtime power management framework to add basic runtime PM support to the igb driver. Namely, make the driver suspend the device when the link is off and set it up for generating a wakeup event after the link has been detected again. This feature is disabled by default. Based on e1000e's runtime PM code. Changes since v1: Don't suspend the device when shutting down the interface. Avoid race between runtime suspending and ethtool operations. Signed-off-by: Zheng Yan <zheng.z.yan@intel.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* igb: Add flow control advertising to ethtool setting.Carolyn Wyborny2012-01-021-2/+4
| | | | | | | | | Added pause flag for bi-directional flow control advertising to ethtool settings. Signed-off-by: Carolyn Wyborny <carolyn.wyborny@intel.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
* Sweep the last of the active .get_drvinfo floors under ethernet/Rick Jones2011-11-141-9/+6
| | | | | | | | | This round of floor sweeping converts strncpy calls in various .get_drvinfo routines to the preferred strlcpy. It also does a modicum of other cleaning in those routines. Signed-off-by: Rick Jones <rick.jones2@hp.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* Merge git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/net-nextDavid S. Miller2011-10-111-8/+6
|\
| * igb: leave staterr in place and instead us a helper function to check bitsAlexander Duyck2011-10-071-4/+1
| | | | | | | | | | | | | | | | | | | | Instead of doing a byte swap on the staterr bits in the Rx descriptor we can save ourselves a bit of space and some CPU time by instead just testing for the various bits out of the Rx descriptor directly. Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
| * igb: Move ITR related data into work container within the q_vectorAlexander Duyck2011-10-071-2/+2
| | | | | | | | | | | | | | | | | | | | | | This change moves information related to interrupt throttle rate configuration into a separate q_vector sub-structure called a work container. A similar change has already been made for ixgbe and this work is based off of that. Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
| * igb: avoid unnecessary conversions from u16 to intAlexander Duyck2011-10-071-2/+3
| | | | | | | | | | | | | | | | | | | | | | There are a number of places where we have values that are stored as u16 but are being converted to int unnecessarily. In order to avoid that we should convert all variables that deal with the next_to_clean, next_to_use, and count to u16 values. Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
* | net: Remove unnecessary driver assignments of ethtool_ringparam fields to zeroRick Jones2011-10-071-4/+0
|/ | | | | | | | | | Per comments from Ben Hutchings on a previous patch, sweep the floors a little removing unnecessary assignments of zero to fields of struct ethtool_ringparam in driver code supporting ethtool -g. Signed-off-by: Rick Jones <rick.jones2@hp.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* igb: split buffer_info into tx_buffer_info and rx_buffer_infoAlexander Duyck2011-10-061-7/+8
| | | | | | | | | | | | | | In order to be able to improve the performance of the TX path it has been necessary to add addition info to the tx_buffer_info structure. However a side effect is that the structure has gotten larger and this in turn has also increased the size of the RX buffer info structure. In order to avoid this in the future I am splitting the single buffer_info structure into two separate ones and instead I will join them by making the buffer_info pointer in the ring a union of the two. Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
* igb: Make Tx budget for NAPI user adjustableAlexander Duyck2011-10-061-0/+1
| | | | | | | | | | | | | | | | This change is to make the NAPI budget limits for transmit adjustable. Currently they are only set to 128, and when the changes/improvements to NAPI occur to allow for adjustability, it would be possible to tune the value for optimal performance with applications such as routing. v2: remove tie between NAPI and interrupt moderation fix work limit define name (s/IXGBE/IGB/) Update patch description to better reflect patch Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com>
* igb: Replace E1000_XX_DESC_ADV with IGB_XX_DESCAlexander Duyck2011-09-191-2/+2
| | | | | | | | | | | Since igb only uses advanced descriptors we might as well just use an IGB specific define and drop the _ADV suffix for the descriptor declarations. In addition this can be further reduced by assuming that it will be working on pointers since that is normally how the Tx descriptors are handled. Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
* igb: drop the "adv" off function names relating to descriptorsAlexander Duyck2011-09-191-3/+3
| | | | | | | | | | | | | Many of the function names in the hot path are carrying an extra "_adv" suffix on the end of them to represent the fact that they are using advanced descriptors instead of legacy descriptors. However since all igb uses are advanced descriptors adding the extra suffix doesn't really add any additional data. Since this is the case it is easiest to just drop the suffix and save us from having to store the extra characters. Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
* igb: drop support for single buffer modeAlexander Duyck2011-09-191-3/+2
| | | | | | | | | | | | This change removes support for single buffer mode from igb and makes the driver function in packet split always. The advantage to doing this is that we can reduce total memory allocation overhead significantly as we will only need to allocate one 1K slab per packet and then make use of a reusable half page instead of allocating a 2K slab per packet. Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
* intel: Move the Intel wired LAN driversJeff Kirsher2011-08-101-0/+2201
Moves the Intel wired LAN drivers into drivers/net/ethernet/intel/ and the necessary Kconfig and Makefile changes. Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
OpenPOWER on IntegriCloud