aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/intel/igb/igb_ethtool.c (follow)
AgeCommit message (Collapse)AuthorFilesLines
2015-08-18igb: Fix oops caused by missing queue pairingShota Suzuki1-1/+4
When initializing igb driver (e.g. 82576, I350), IGB_FLAG_QUEUE_PAIRS is set if adapter->rss_queues exceeds half of max_rss_queues in igb_init_queue_configuration(). On the other hand, IGB_FLAG_QUEUE_PAIRS is not set even if the number of queues exceeds half of max_combined in igb_set_channels() when changing the number of queues by "ethtool -L". In this case, if numvecs is larger than MAX_MSIX_ENTRIES (10), the size of adapter->msix_entries[], an overflow can occur in igb_set_interrupt_capability(), which in turn leads to an oops. Fix this problem as follows: - When changing the number of queues by "ethtool -L", set IGB_FLAG_QUEUE_PAIRS in the same way as initializing igb driver. - When increasing the size of q_vector, reallocate it appropriately. (With IGB_FLAG_QUEUE_PAIRS set, the size of q_vector gets larger.) Another possible way to fix this problem is to cap the queues at its initial number, which is the number of the initial online cpus. But this is not the optimal way because we cannot increase queues when another cpu becomes online. Note that before commit cd14ef54d25b ("igb: Change to use statically allocated array for MSIx entries"), this problem did not cause oops but just made the number of queues become 1 because of entering msi_only mode in igb_set_interrupt_capability(). Fixes: 907b7835799f ("igb: Add ethtool support to configure number of channels") CC: stable <stable@vger.kernel.org> Signed-off-by: Shota Suzuki <suzuki_shota_t3@lab.ntt.co.jp> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2015-07-23igb: report unsupported ethtool settings in set_coalesceTodd Fujinaka1-0/+21
There are many settings possible using ethtool -C/--coalesce, but not all of them are supported in igb. Report failure when an unsupported option is set. Signed-off-by: Todd Fujinaka <todd.fujinaka@intel.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2015-07-17igb: only report generic filters in get_ts_infoJacob Keller1-4/+0
Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Acked-by: Richard Cochran <richardcochran@gmail.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2014-12-08ethtool: Support for configurable RSS hash functionEyal Perry1-2/+14
This patch extends the set/get_rxfh ethtool-options for getting or setting the RSS hash function. It modifies drivers implementation of set/get_rxfh accordingly. This change also delegates the responsibility of checking whether a modification to a certain RX flow hash parameter is supported to the driver implementation of set_rxfh. User-kernel API is done through the new hfunc bitmask field in the ethtool_rxfh struct. A bit set in the hfunc field is corresponding to an index in the new string-set ETH_SS_RSS_HASH_FUNCS. Got approval from most of the relevant driver maintainers that their driver is using Toeplitz, and for the few that didn't answered, also assumed it is Toeplitz. Cc: Tom Lendacky <thomas.lendacky@amd.com> Cc: Ariel Elior <ariel.elior@qlogic.com> Cc: Prashant Sreedharan <prashant@broadcom.com> Cc: Michael Chan <mchan@broadcom.com> Cc: Hariprasad S <hariprasad@chelsio.com> Cc: Sathya Perla <sathya.perla@emulex.com> Cc: Subbu Seetharaman <subbu.seetharaman@emulex.com> Cc: Ajit Khaparde <ajit.khaparde@emulex.com> Cc: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Cc: Jesse Brandeburg <jesse.brandeburg@intel.com> Cc: Bruce Allan <bruce.w.allan@intel.com> Cc: Carolyn Wyborny <carolyn.wyborny@intel.com> Cc: Don Skidmore <donald.c.skidmore@intel.com> Cc: Greg Rose <gregory.v.rose@intel.com> Cc: Matthew Vick <matthew.vick@intel.com> Cc: John Ronciak <john.ronciak@intel.com> Cc: Mitch Williams <mitch.a.williams@intel.com> Cc: Amir Vadai <amirv@mellanox.com> Cc: Solarflare linux maintainers <linux-net-drivers@solarflare.com> Cc: Shradha Shah <sshah@solarflare.com> Cc: Shreyas Bhatewara <sbhatewara@vmware.com> Cc: "VMware, Inc." <pv-drivers@vmware.com> Cc: Ben Hutchings <ben@decadent.org.uk> Signed-off-by: Eyal Perry <eyalpe@mellanox.com> Signed-off-by: Amir Vadai <amirv@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2014-09-06igb: add flags to set eee advertisement modeTodd Fujinaka1-7/+17
Change e1000_set_eee and e1000_set_eee_i35(0|4) to allow changes in the advertised EEE speeds from ethtool. Adds two boolean flags to e1000_set_eee_i35(0|4) to pass in advertised speed data. Signed-off-by: Todd Fujinaka <todd.fujinaka@intel.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2014-06-11igb: unhide invariant returnsTodd Fujinaka1-5/+5
Return a 0 directly rather than a constant. Reported-by: Peter Senna Tschudin <peter.senna@gmail.com> Signed-off-by: Todd Fujinaka <todd.fujinaka@intel.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2014-06-06net: use ethtool_cmd_speed_set helper to set ethtool speed valueJiri Pirko1-5/+7
Signed-off-by: Jiri Pirko <jiri@resnulli.us> Signed-off-by: David S. Miller <davem@davemloft.net>
2014-06-06net: use SPEED_UNKNOWN and DUPLEX_UNKNOWN when appropriateJiri Pirko1-2/+2
Signed-off-by: Jiri Pirko <jiri@resnulli.us> Signed-off-by: David S. Miller <davem@davemloft.net>
2014-06-03igb: use mac loopback for i354 backplaneTodd Fujinaka1-2/+2
We can't know what PHY is to be used for i354 backplane, so use MAC loopback for ethtool tests. Signed-off-by: Todd Fujinaka <todd.fujinaka@intel.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2014-06-03ethtool: Replace ethtool_ops::{get,set}_rxfh_indir() with {get,set}_rxfh()Ben Hutchings1-4/+5
ETHTOOL_{G,S}RXFHINDIR and ETHTOOL_{G,S}RSSH should work for drivers regardless of whether they expose the hash key, unless you try to set a hash key for a driver that doesn't expose it. Signed-off-by: Ben Hutchings <ben@decadent.org.uk> Acked-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2014-05-13net: get rid of SET_ETHTOOL_OPSWilfried Klaebe1-1/+1
net: get rid of SET_ETHTOOL_OPS Dave Miller mentioned he'd like to see SET_ETHTOOL_OPS gone. This does that. Mostly done via coccinelle script: @@ struct ethtool_ops *ops; struct net_device *dev; @@ - SET_ETHTOOL_OPS(dev, ops); + dev->ethtool_ops = ops; Compile tested only, but I'd seriously wonder if this broke anything. Suggested-by: Dave Miller <davem@davemloft.net> Signed-off-by: Wilfried Klaebe <w-lkml@lebenslange-mailadresse.de> Acked-by: Felipe Balbi <balbi@ti.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2014-04-24igb: Replace 1/0 return values with true/falseCarolyn Wyborny1-4/+4
This patch fixes issues found by updated coccicheck. 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>
2014-04-24igb: Cleanups to fix msleep warningsCarolyn Wyborny1-8/+8
This patch fixes WARNING:MSLEEP found by checkpatch check. 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>
2014-04-24igb: Cleanups to fix line length warningsCarolyn Wyborny1-5/+8
This patch fixes WARNING:LONG_LINE found with checkpatch check. 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>
2014-04-24igb: Cleanups to fix missing break in switch statementsCarolyn Wyborny1-0/+4
This patch fixes WARNING:MISSING_BREAK found with checkpatch check. 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>
2014-04-24igb: Cleanups to change comment style on license headersCarolyn Wyborny1-25/+22
This patch fixes WARNING:NETWORKING_BLOCK_COMMENT_STYLE from checkpatch file check. 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>
2014-04-23igb: Cleanups to fix incorrect indentationCarolyn Wyborny1-9/+11
This patch fixes WARNING:LEADING_SPACE, WARNING:SPACING, ERROR:SPACING, WARNING:SPACE_BEFORE_TAB and ERROR_CODE_INDENT from checkpatch file check. 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>
2014-04-23igb: Cleanups to fix braces location warningsCarolyn Wyborny1-2/+2
This patch fixes WARNING:BRACES and ERROR:OPEN_BRACE from checkpatch file check. 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>
2014-03-21igb: specify phc_index of 82575 for get_ts_infoKen ICHIKAWA1-5/+5
82575 has only software timestamping capability and it has no PTP Hardware Clocks. Therefore, -1 has to be specified to the phc_index for ethtool's get_ts_info, otherwise a wrong value will be set to the phc_index. v2: move the if (adapter->ptp_clock) section specifying phc_index to above the switch statement as suggested by Matthew Vick. adapter->ptpclock will always be NULL for 82575. Signed-off-by: Ken ICHIKAWA <ichikawa.ken@jp.fujitsu.com> Acked-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>
2014-03-21igb: Fix memory leak in igb_get_module_eeprom()Christian Engelmayer1-1/+3
Fix a memory leak in the igb_get_module_eeprom() error handling path. Detected by Coverity: CID 1016508. Signed-off-by: Christian Engelmayer <cengelma@gmx.at> Tested-by: Jeff Pieper <jeffrey.e.pieper@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2014-03-14net: Replace u64_stats_fetch_begin_bh to u64_stats_fetch_begin_irqEric W. Biederman1-6/+6
Replace the bh safe variant with the hard irq safe variant. We need a hard irq safe variant to deal with netpoll transmitting packets from hard irq context, and we need it in most if not all of the places using the bh safe variant. Except on 32bit uni-processor the code is exactly the same so don't bother with a bh variant, just have a hard irq safe variant that everyone can use. Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2014-03-12igb: Fix for devices using ethtool for EEE settingsCarolyn Wyborny1-16/+29
This patch fixes a problem where using ethtool for EEE setting was not working correctly. This patch also fixes a problem where the function that checks for EEE status on i354 devices was not being called and was causing warnings with static analysis tools. Reported-by: Rashika Kheria <rashika.kheria@gmail.com> Reported-by: Josh Triplett <josh@joshtriplett.org> Reported-by: Stephen Hemminger <stephen@networkplumber.org> 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>
2014-02-26igb: Update license text to remove FSF address and update copyright.Carolyn Wyborny1-3/+2
This patch updates the license text to remove address of Free Software Foundation and refer users to www.gnu.org instead. This patch also updates the copyright dates in appropriate igb driver files. Signed-off-by: Carolyn Wyborny <carolyn.wyborny@intel.com> Signed-off-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2013-12-17igb: Change to use statically allocated array for MSIx entriesCarolyn Wyborny1-3/+3
This patch changes how the driver initializes MSIx and checks for MSIx configuration. This change makes it easier to reconfigure the device when queue changes happen at runtime using ethtool's set_channels feature. 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>
2013-12-10igb: Add new feature Media Auto Sense for 82580 devices onlyCarolyn Wyborny1-0/+4
This patch adds support for the hardware feature Media Auto Sense. This feature requires a custom EEPROM image provided by our customer support team. The feature allows hardware designed with dual PHY's, fiber and copper to be used with either media without additional EEPROM changes. Fiber is preferred and driver will swap and configure for fiber media if sensed by the device at any time. Device will swap back to copper if it is the only media detected. 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>
2013-11-29igb: Fixed Wake On LAN supportAkeem G Abodunrin1-3/+4
This patch fixes Wake on LAN being reported as supported on some Ethernet ports, in contrary to Hardware capability. 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>
2013-11-11igb: Update link modes display in ethtoolCarolyn Wyborny1-24/+27
This patch fixes multiple problems in the link modes display in ethtool. Newer parts have more complicated methods to determine actual link capabilities. Older parts cannot communicate with their SFP modules. Finally, all the available defines are not displayed by ethtool. This updates the link modes to be as accurate as possible depending on what data is available to the driver at any given time. 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> Signed-off-by: David S. Miller <davem@davemloft.net>
2013-11-01igb: Don't let ethtool try to write to iNVM in i210/i211Fujinaka, Todd1-1/+3
Don't let ethtool try to write to iNVM in i210/i211. This fixes an issue seen by Marek Vasut. Reported-by: Marek Vasut <marex@denx.de> Signed-off-by: Todd Fujinaka <todd.fujinaka@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2013-10-08Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/netDavid S. Miller1-0/+2
Conflicts: include/linux/netdevice.h net/core/sock.c Trivial merge issues. Removal of "extern" for functions declaration in netdevice.h at the same time "const" was added to an argument. Two parallel line additions in net/core/sock.c Signed-off-by: David S. Miller <davem@davemloft.net>
2013-10-02igb: Avoid uninitialized advertised variable in eee_set_curAndi Kleen1-0/+2
eee_get_cur assumes that the output data is already zeroed. It can read-modify-write the advertised field: if (ipcnfg & E1000_IPCNFG_EEE_100M_AN) 2594 edata->advertised |= ADVERTISED_100baseT_Full; This is ok for the normal ethtool eee_get call, which always zeroes the input data before. But eee_set_cur also calls eee_get_cur and it did not zero the input field. Later on it then compares agsinst the field, which can contain partial stack garbage. Zero the input field in eee_set_cur() too. Cc: jeffrey.t.kirsher@intel.com Cc: netdev@vger.kernel.org Signed-off-by: Andi Kleen <ak@linux.intel.com> Acked-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2013-10-01Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/netDavid S. Miller1-0/+3
Conflicts: drivers/net/ethernet/emulex/benet/be.h drivers/net/usb/qmi_wwan.c drivers/net/wireless/brcm80211/brcmfmac/dhd_bus.h include/net/netfilter/nf_conntrack_synproxy.h include/net/secure_seq.h The conflicts are of two varieties: 1) Conflicts with Joe Perches's 'extern' removal from header file function declarations. Usually it's an argument signature change or a function being added/removed. The resolutions are trivial. 2) Some overlapping changes in qmi_wwan.c and be.h, one commit adds a new value, another changes an existing value. That sort of thing. Signed-off-by: David S. Miller <davem@davemloft.net>
2013-10-01igb: Add ethtool support to configure number of channelsLaura Mihaela Vasilescu1-0/+84
This patch adds the ethtool callbacks necessary to configure the number of RSS queues. The maximum number of queues is in accordance with the datasheets. Signed-off-by: Laura Mihaela Vasilescu <laura.vasilescu@rosedu.org> 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>
2013-10-01igb: Add ethtool offline tests for i354Fujinaka, Todd1-2/+4
Add the ethtool offline tests for i354 devices. Signed-off-by: Todd Fujinaka <todd.fujinaka@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>
2013-09-27igb: Fix ethtool loopback test for 82580 copperTodd Fujinaka1-0/+3
Add back 82580 loopback tests to ethtool. Signed-off-by: Todd Fujinaka <todd.fujinaka@intel.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2013-09-04igb: Implementation to report advertised/supported link on i354 devicesAkeem G Abodunrin1-11/+15
This patch changes the way we report supported/advertised link for i354 devices, especially for 2.5 GB. Instead of reporting 2.5 GB for all i354 devices erroneously, check first, if it is 2.5 GB capable. 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>
2013-08-22igb: Expose RSS indirection table for ethtoolLaura Mihaela Vasilescu1-0/+87
This patch adds the ethtool callbacks necessary to change the RETA indirection table from userspace. In order to achieve this, we add the indirection table field (rss_indir_tbl) in the board specific data structure (struct igb_adapter) to preserve the values across hardware resets. The indirection table must be initialized with default values in the following cases: * at module init time * when the number of RX queues changes. For this reason we add a new field (rss_indir_tbl_init) in igb_adapter that keeps track of the number of RX queues. Whenever the number of RX queues changes, the rss_indir_tbl is modified and initialized with default values. The rss_indir_tbl_init is updated accordingly. CC: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: Laura Mihaela Vasilescu <laura.vasilescu@rosedu.org> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2013-08-22igb: Add device support for flashless SKU of i210 deviceCarolyn Wyborny1-2/+13
This patch adds the specific device id support for versions of i210 that do not have flash installed. 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>
2013-08-22igb: Reset the link when EEE setting changedAkeem G Abodunrin1-1/+3
This patch resets the link, if link is up - whenever users enable or disable EEE 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>
2013-05-21igb: Fix set_ethtool function to call update nvm for entire imageCarolyn Wyborny1-4/+2
This patch fixes a problem where we were only checking to update checksum on first part of nvm image. Newer parts have multiple checksum fields and checksum function will accommodate that as long as we call it in the first place for any changes made. 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>
2013-05-21igb: SerDes flow control settingAkeem G. Abodunrin1-15/+19
This path allows users to get appropriate flow control setting on SerDes devices, based on original implementation for Copper devices. Also, since 100baseFX does not support setting flow control, so exclude it from the setting mechanism. 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>
2013-05-21igb: Support for SFP modules discoveryAkeem G. Abodunrin1-20/+14
This patch adds support for SFP modules media type discovery for SGMII, which will enable driver to detect supported external PHYs, including 100baseFXSFP module. Signed-off-by: Akeem G Abodunrin <akeem.g.abodunrin@intel.com> Signed-off-by: Carolyn Wyborny <carolyn.wyborny@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2013-04-24igb: SERDES loopback sigdetect bit on i210 devicesAkeem G. Abodunrin1-7/+2
This patch implements SERDES loopback configuration for i210 devices by unsetting sigdetect bit, so as to fix Ethtool loopback test failure. Old sigdetect code is also simplified to take care of all devices newer than 82580 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>
2013-04-18igb: Add support for i354 devicesCarolyn Wyborny1-17/+50
This patch adds base support for new i354 devices. Loopback test is unsupported for this release. Signed-off-by: Carolyn Wyborny <carolyn.wyborny@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2013-04-18igb: Enable EEE LP advertisementMatthew Vick1-1/+29
On EEE-capable devices, query the PHY to determine what the link partner is advertising. Signed-off-by: Matthew Vick <matthew.vick@intel.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2013-04-18igb: Fix code comments and whitespaceJeff Kirsher1-66/+71
Aligns the multi-line code comments with the desired style for the networking tree. Also cleaned up whitespace issues found during the cleanup of code comments (i.e. remove unnecessary blank lines, use tabs where possible, properly wrap lines and keep strings on a single line) Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com>
2013-04-18igb: Support to read and export SFF-8472/8079 dataAkeem G. Abodunrin1-0/+81
This patch adds support to read and export SFF-8472/8079 (SFP data) over i2c, through Ethtool. v2: Changed implementation to accommodate any offset within SFF module length boundary. Reported-by: Aurélien Guillaume <footplus@gmail.com> CC: Aurélien Guillaume <footplus@gmail.com> CC: Ben Hutchings <bhutchings@solarflare.com> 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>
2013-04-18igb: Support for 100base-fx SFPAkeem G. Abodunrin1-13/+35
This patch adds support for 100base-fx SFP and report proper link speed/duplex via Ethtool. v2: fix smatch warnings CC: Dan Carpenter <dan.carpenter@oracle.com> 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>
2013-02-15igb: increase timeout for ethtool offline self-testStefan Assmann1-1/+1
On several machines with i350 adapters the ethtool offline self-test sometimes fails. This happens because link auto negotiation may take longer than the timeout of 4 seconds. Increasing the timeout by 1 seconds resolves the issue. Output from a failing i350 offline self-test: while [ 1 ]; do ethtool -t eth2 offline; done The test result is PASS The test extra info: Register test (offline) 0 Eeprom test (offline) 0 Interrupt test (offline) 0 Loopback test (offline) 0 Link test (on/offline) 0 The test result is FAIL The test extra info: Register test (offline) 0 Eeprom test (offline) 0 Interrupt test (offline) 0 Loopback test (offline) 0 Link test (on/offline) 1 The test result is PASS The test extra info: Register test (offline) 0 Eeprom test (offline) 0 Interrupt test (offline) 0 Loopback test (offline) 0 Link test (on/offline) 0 Signed-off-by: Stefan Assmann <sassmann@kpanic.de> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2013-01-19igb: Copyright string update to year 2013Akeem G. Abodunrin1-1/+1
This patch updates Copyright year to 2013 v2: Changed Copyright year on Makefile 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>
2013-01-18igb: Add mechanism for detecting latched hardware Rx timestampMatthew Vick1-0/+1
Add a check against possible Rx timestamp freezing in the hardware via watchdog mechanism. This situation can occur when an Rx timestamp has been latched, but the packet has been dropped because the Rx ring is full. Whenever a packet comes in that should be timestamped, the Rx timestamp gets latched into the hardware registers and we will store the jiffy value in the rx_ring. The watchdog will keep track of his own jiffy timer whenever there is no valid timestamp in the registers. If the watchdog detects a valid timestamp in the registers, meaning that no Rx packet has consumed it yet, it will check which time is most recent: the last time in the watchdog or any time in the rx_rings. If the most recent "event" was more than 5 seconds ago, it will flush the Rx timestamp and print a warning message to the syslog. Cc: Richard Cochran <richardcochran@gmail.com> Signed-off-by: Matthew Vick <matthew.vick@intel.com> Acked-by: Richard Cochran <richardcochran@gmail.com> Acked-by: Jacob Keller <Jacob.e.keller@intel.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>