summaryrefslogtreecommitdiffstats
path: root/sys/dev/ixgbe
Commit message (Collapse)AuthorAgeFilesLines
* Run a SFP probe, which in turn will run a PHY probe.Luiz Souza2017-09-241-3/+2
| | | | | | Fixes the detection of SFP modules inserted after the boot. Ticket #7763
* MFC r312544rstone2017-02-071-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | Fix reference to free memory in ixgbe/if_media.c When ixgbe receives an interrupt indicating that a new optical module may have been inserted, it discards all of its current media types by calling ifmedia_removeall() and then creates a new set of media types for the supported media on the new module. However, ifmedia_removeall() was maintaining a pointer to whatever the current media type was before the call to ifmedia_removealL(). The result of this was that any attempt to read the current media type of the interface (e.g. via ifconfig) would return potentially garbage data from free memory (or if one were particularly unlucky on an architecture that does not malloc() from a direct map, page fault the kernel). Fix this by NULL'ing out the current media field in if_media.c, and have ixgbe update the current media type after recreating them. Submitted by: Matt Joras <matt.joras AT gmail DOT com> Reviewed by: sbruno, erj MFC after: 1 week Sponsored by: Dell EMC Isilon Differential Revision: https://reviews.freebsd.org/D9164
* MFC r303032sbruno2016-07-241-9/+6
| | | | | | | | Fixup DA cable detection routines to not set the cable type to unknown if they do not match one of two cable types. PR: 150249 Approved by: re (gjb)
* Do not initialize the adapter on MTU change when adapter status is down.sbruno2016-07-072-2/+4
| | | | | | | | | | | | This fixes long-standing problems when changing settings of the adapter. Discussed in: https://lists.freebsd.org/pipermail/freebsd-net/2016-June/045509.html Submitted by: arnaud.ysmal@stormshield.eu Reviewed by: erj@freebsd.org Approved by: re (gjb) Differential Revision: https://reviews.freebsd.org/D7030
* net: Use M_HASHTYPE_OPAQUE_HASH if the mbuf flowid has hash propertiessephe2016-06-071-1/+1
| | | | | | Reviewed by: hps, erj, tuexen Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D6688
* dev/e1000,ixgbe: minor spelling fixes.pfg2016-05-065-9/+9
| | | | | | No functional change. Differential Revision: https://reviews.freebsd.org/D6177
* Correct possible underflow conditions when checking for available spacesbruno2016-04-181-1/+1
| | | | | | | | | in the tx h/w ring buffer. Reviewed by: gnn jeb.j.cramer@intel.com MFC after: 1 week Sponsored by: Limelight Networks Differential Revision: https://reviews.freebsd.org/D5918
* Cleanup unnecessary semicolons from the kernel.pfg2016-04-102-3/+3
| | | | Found with devel/coccinelle.
* tcp/lro: Use tcp_lro_flush_all in device drivers to avoid code duplicationsephe2016-04-011-5/+1
| | | | | | | | | And factor out tcp_lro_rx_done, which deduplicates the same logic with netinet/tcp_lro.c Reviewed by: gallatin (1st version), hps, zbb, np, Dexuan Cui <decui microsoft com> Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D5725
* Prevent invalid ixgbe advertise setting warningsmh2016-03-161-4/+4
| | | | | | | | | Prevent ixgbe outputting "Invalid advertised speed" warning on boot with no customisations by moving test from sysctl handler to set handler. PR: 208022 MFC after: 3 days Sponsored by: Multiplay
* In FreeBSD 10 and higher the driver announces SCTP checksum offloading supporttuexen2016-02-041-7/+11
| | | | | | | | also for 82598, which doesn't support it. The legacy code has a check for it, which was missed when the code for dealing with CSUM_IP6_* was added. Add the same check for FreeBSD 10 and higher. Differential Revision: https://reviews.freebsd.org/D5192
* Fix ixgbe flow control autoneg reportingsmh2016-01-311-1/+4
| | | | | | | | | Fix ixgbe reporting of flow control autoneg when running under DBG 1 Reviewed by: erj MFC after: 2 days Sponsored by: Multiplay Differential Revision: https://reviews.freebsd.org/D5089
* Configure ixgbe phy & gbic powersmh2016-01-315-4/+36
| | | | | | | | | | | | Setup phy and gbic power as per Linux 4.3.13 driver. This fixes link not detected on X540-AT2 after booting to Linux which turns the phy power off on detach. Reviewed by: sbruno MFC after: 2 days Sponsored by: Multiplay Differential Revision: https://reviews.freebsd.org/D5107
* ixgbe sysctl hardware defaultssmh2016-01-262-49/+86
| | | | | | | | | | | | | | | Added hw.ix.flow_control which enables the default flow_control of all ix interfaces to be set in loader.conf. Added hw.ix.advertise_speed which enables the default advertised_speed of all ix interfaces to be set in loader.conf. Made enable_aim device independent based on hw.ix.enable_aim default. Reviewed by: erj MFC after: 1 week Sponsored by: Multiplay Differential Revision: https://reviews.freebsd.org/D5060
* Fix ixgbe compliation with DBG 1smh2016-01-251-3/+26
| | | | | | | | Fixed ERROR_REPORTXX macros so that ixgbe compiles with #define DBG 1 MFC after: 1 week Sponsored by: Multiplay Differential Revision: https://reviews.freebsd.org/D5061
* Fix ix advertise value after media changesmh2016-01-221-4/+10
| | | | | | | | | | | | | When ifconfig sets media then the values displayed by the advertise_speed value are invalidated. Fix this by setting the bits correctly including setting advertise to 0 for media = auto. Reviewed by: sbruno MFC after: 1 week Sponsored by: Multiplay Differential Revision: https://reviews.freebsd.org/D5034
* Add optimizing LRO wrapper:hselasky2016-01-192-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Add optimizing LRO wrapper which pre-sorts all incoming packets according to the hash type and flowid. This prevents exhaustion of the LRO entries due to too many connections at the same time. Testing using a larger number of higher bandwidth TCP connections showed that the incoming ACK packet aggregation rate increased from ~1.3:1 to almost 3:1. Another test showed that for a number of TCP connections greater than 16 per hardware receive ring, where 8 TCP connections was the LRO active entry limit, there was a significant improvement in throughput due to being able to fully aggregate more than 8 TCP stream. For very few very high bandwidth TCP streams, the optimizing LRO wrapper will add CPU usage instead of reducing CPU usage. This is expected. Network drivers which want to use the optimizing LRO wrapper needs to call "tcp_lro_queue_mbuf()" instead of "tcp_lro_rx()" and "tcp_lro_flush_all()" instead of "tcp_lro_flush()". Further the LRO control structure must be initialized using "tcp_lro_init_args()" passing a non-zero number into the "lro_mbufs" argument. - Make LRO statistics 64-bit. Previously 32-bit integers were used for statistics which can be prone to wrap-around. Fix this while at it and update all SYSCTL's which expose LRO statistics. - Ensure all data is freed when destroying a LRO control structures, especially leftover LRO entries. - Reduce number of memory allocations needed when setting up a LRO control structure by precomputing the total amount of memory needed. - Add own memory allocation counter for LRO. - Bump the FreeBSD version to force recompilation of all KLDs due to change of the LRO control structure size. Sponsored by: Mellanox Technologies Reviewed by: gallatin, sbruno, rrs, gnn, transport Tested by: Netflix Differential Revision: https://reviews.freebsd.org/D4914
* Fix VF handling of VLANs.sbruno2016-01-071-3/+2
| | | | | | | | | | This helps immensily with our ability to operate in the Amazon Cloud. Discussed on Intel Networking Community call this morning. Submitted by: Jarrod Petz(petz@nisshoko.net) MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D4788
* Fixup SFP module insertion on the 82599 when insertion happens aftersbruno2016-01-071-9/+49
| | | | | | | | | | | | the system is booted and running. Add PHY detection logic to ixgbe_handle_mod() and add locking to ixgbe_handle_msf() as well. PR: 150251 Submitted by: aboyer@averesystems.com MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D3188
* Add missing #ifdef INET after r292674 to allow NOIP and NOINET kernelsbz2015-12-261-0/+2
| | | | to build.
* Fix NO INET6 build broken at svn r292674sbruno2015-12-241-0/+2
| | | | Reported by: ohartman@zedat.fu-berlin.de
* ixgbe(4): Update to version 3.1.13-ksbruno2015-12-2320-978/+961
| | | | | | | | | | Add support for two new devices: X552 SFP+ 10 GbE, and the single port version of X550T. Submitted by: erj Reviewed by: gnn Sponsored by: Intel Corporation Differential Revision: https://reviews.freebsd.org/D4186
* Add support for sysctl knobs to live tune the per interrupt rx/tx packetsbruno2015-10-134-17/+47
| | | | | | | | processing limits in ixgbe(4) Differential Revision: https://reviews.freebsd.org/D3719 Submitted by: jason wolfe (j-nitrology.com) MFC after: 2 weeks
* A misplaced #endif in ixgbe_ioctl() causes interface MTU to becomesbruno2015-08-031-3/+3
| | | | | | | | | | zero when INET and INET6 are undefined. PR: 162028 Differential Revision: https://reviews.freebsd.org/D3187 Submitted by: hoomanfazaeli@gmail.com pluknet Reviewed by: erj hiren gelbius MFC after: 2 weeks
* Remove a couple of TUNABLE_INT() calls which are unnecessary after r267961.hiren2015-07-211-2/+0
| | | | | | | r267961 did remove them but they "reappeared" when ixgbe(4) rewrite happened in r280182. Sponsored by: Limelight Networks
* Add netmap support for ixgbe SRIOV VFs (that is, to if_ixv).pkelsey2015-07-153-2/+62
| | | | | | | Differential Revision: https://reviews.freebsd.org/D2923 Reviewed by: erj, gnn Approved by: jmallett (mentor) Sponsored by: Norse Corp, Inc.
* Remove FreeBSD version check for deprecated M_FLOWID.hiren2015-07-151-4/+0
| | | | | Reviewed by: erj Sponsored by: Limelight Networks
* Fix igxbe SRIOV VF (if_ixv) initialization bugs. The MAC address forpkelsey2015-07-153-6/+8
| | | | | | | | | | | | an if_ixv instance can now set at creation time, and the receive ring tail pointer is correctly initialized (previously, things still worked because the receive ring tail pointer was being fixed up as a side effect of other activity). Differential Revision: https://reviews.freebsd.org/D2922 Reviewed by: erj, gnn Approved by: jmallett (mentor) Sponsored by: Norse Corp, Inc.
* Expose full 32bit RSS hash from card regardless of whether RSS is defined orhiren2015-07-141-45/+52
| | | | | | | | | | | | | not. When doing multiqueue, we are all setup to have full 32bit RSS hash from the card. We do not need to hide that under "ifdef RSS" and should expose that by default so others like lagg(4) can use that and avoid hashing the traffic by themselves. While here, delete the FreeBSD version check and use of deprecated M_FLOWID. Reviewed by: adrian, erj MFC after: 1 week Sponsored by: Limelight Networks
* Sync netmap sources with the version in our private tree.luigi2015-07-101-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit contains large contributions from Giuseppe Lettieri and Stefano Garzarella, is partly supported by grants from Verisign and Cisco, and brings in the following: - fix zerocopy monitor ports and introduce copying monitor ports (the latter are lower performance but give access to all traffic in parallel with the application) - exclusive open mode, useful to implement solutions that recover from crashes of the main netmap client (suggested by Patrick Kelsey) - revised memory allocator in preparation for the 'passthrough mode' (ptnetmap) recently presented at bsdcan. ptnetmap is described in S. Garzarella, G. Lettieri, L. Rizzo; Virtual device passthrough for high speed VM networking, ACM/IEEE ANCS 2015, Oakland (CA) May 2015 http://info.iet.unipi.it/~luigi/research.html - fix rx CRC handing on ixl - add module dependencies for netmap when building drivers as modules - minor simplifications to device-specific routines (*txsync, *rxsync) - general code cleanup (remove unused variables, introduce macros to access rings and remove duplicate code, Applications do not need to be recompiled, unless of course they want to use the new features (monitors and exclusive open). Those willing to try this code on stable/10 can just update the sys/dev/netmap/*, sys/net/netmap* with the version in HEAD and apply the small patches to individual device drivers. MFC after: 1 month Sponsored by: (partly) Verisign, Cisco
* Catch up to the SRIOV API changes in r283670.jhb2015-06-012-3/+4
|
* Delta D2489 - Add SRIOV support to the Intel 10G driver.jfv2015-06-016-177/+1380
| | | | | | | NOTE: This is a technology preview, while it has undergone development testing, Intel has not yet completed full validation of the feature. It is being integrated for early access and customer testing.
* Revert last commit, to remove added skeleton tree.jfv2015-06-016-1382/+181
|
* Delta D2489 - Add SRIOV support to the Intel 10G driver.jfv2015-06-016-181/+1382
| | | | | | NOTE: This is a technology preview, while it has undergone development tests, Intel has not yet completed full validation of the feature. It is being integrated for early access and customer testing.
* Remove the extra extern which makes gcc complain; I assume it came frombz2015-05-011-4/+0
| | | | | | | r282289. We do include ixgbe.h which does include ixgbe_common.h which has the extern statement for ixgbe_stop_mac_link_on_d3_82599().
* Add support for certain Intel X550 devices.erj2015-04-3030-400/+4793
| | | | | | | | | | | | These include standalone X550 adapters, X552 10GbE backplane, and X552/X557-AT 10GBASE-T; with the latter two being integrated into Xeon D SoCs. As well, this bumps the ixgbe version number to 2.8.3, and includes updates to shared code for support for the new devices. Differential Revision: D2414 Reviewed by: gnn, adrian Approved by: jfv (mentor), gnn (mentor)
* Various fixes to the stats in igb(4), ixgbe(4), and ixl(4).jhb2015-04-301-0/+11
| | | | | | | | | | | | | | | | | | | - Use hardware counters for ifnet stats in igb(4) when possible. This ensures these stats include packets that bypass the regular stack via netmap. - Don't derefence values off the end of the igb(4) VF stats structure. Instead, add a dedicated if_get_counter method for igb(4) VF interfaces. - Report missed packets on igb(4) as input queue drops rather than an input error. - Report bug_ring drop counts as output queue drops for igb(4) and ixgbe(4). - Export the buf_ring drop stats for individual rings via sysctl on ixgbe(4). - Fix a typo that in ixl(4) that caused output queue drops to be reported as input queue drops and input queue drops to be unreported. Differential Revision: https://reviews.freebsd.org/D2402 Reviewed by: jfv, rstone (6) Sponsored by: Norse Corp, Inc.
* Add back ixgbe_rxeof, just remove the assignment to more.araujo2015-04-201-0/+1
|
* Remove unused variable.araujo2015-04-201-2/+0
| | | | | Differential Revision: D2331 Reviewed by: erj
* Make changes to busdma code in tx/rx path similar to the ones made in r257541.erj2015-04-011-4/+3
| | | | | | | | | | - bus_dmamap_create() does not take the BUS_DMA_NOWAIT flag - properly unload maps - do not assign NULL to dma map pointers Submitted by: Konstantin Belousov <kostikbel@gmail.com> Approved by: jfv (mentor) MFC after: 1 week
* Fix building ixgbe with gcc, it doesn't like nested extern declarations.andrew2015-03-191-1/+2
| | | | | The fix is to move the extern declaration ix_crcstrip out of ixgbe_setup_hw_rsc.
* Fix i386 LINT build issues, and remove unused variable.jfv2015-03-182-5/+4
|
* Fix ixgbe(4) to compile - with RSS; with ix+ixv in the kernel.adrian2015-03-183-11/+18
| | | | | | | | | | | | | | | * Fix the multiple same-named devclasses; the duplicate name trips up the linker. * Re-do the taskqueue stuff to use the new cpuset API, not the old pinned API. * Add includes for the new location of the RSS configuration routines. This allows ixgbe to compile as a module /and/ linked into the kernel, along with RSS working. Sponsored by: Norse Corp, Inc.
* Resolve a few build issues, add module directories back into Makefile,jfv2015-03-173-1/+10
| | | | | then correct a NETMAP problem resulting from the split, and finally temporarily disable the X550 functionality.
* Update to the Intel ixgbe driver:jfv2015-03-1730-8111/+8355
| | | | | | | | | | | | | | | | | | | - Split the driver into independent pf and vf loadables. This is in preparation for SRIOV support which will be following shortly. This also allows us to keep a seperate revision control over the two parts, making for easier sustaining. - Make the TX/RX code a shared/seperated file, in the old code base the ixv code would miss fixes that went into ixgbe, this model will eliminate that problem. - The driver loadables will now match the device names, something that has been requested for some time. - Rather than a modules/ixgbe there is now modules/ix and modules/ixv - It will also be possible to make your static kernel with only one or the other for streamlined installs, or both. Enjoy! Submitted by: jfv and erj
* Fix style(9) from my previous commit r279803.araujo2015-03-091-24/+23
| | | | Spotted by: kevlo
* Now ifconfig(8) can set the media option as 10Gbase-T for ixgbe(4).araujo2015-03-091-0/+1
| | | | | | | Differential Revision: D823 Reviewed by: jfvogel Approved by: jfvogel Sponsored by: QNAP Systems Inc.
* Fix the media detected for copper cables NIC based on chipset X540T.araujo2015-03-091-11/+24
| | | | | | | Phabric: D811 Reviewed by: jfvogel Approved by: jfvogel Sponsored by: QNAP Systems Inc.
* Pad RX copy alignment calculation to avoid illegal memory accessesngie2015-02-281-2/+3
| | | | | | | | | | | | | | | | | | | | The optimization made in r239940 is valid for struct mbuf's current structure and size in FreeBSD, but hardcodes assumptions about sizes of struct mbuf, which are unfortunately broken if additional data is added to the beginning of struct mbuf X-MFC note (discussed with rwatson): This change requires the MPKTHSIZE definition, which is only available after head@r277203 and will not be MFCed as it breaks mbuf(9) KPI. A direct commit to stable/10 and merges to other branches to add the necessary definitions to work with the code as-is will be done to facilitate this MFC PR: 194314 MFC after: 2 weeks Approved/Reviewed by: erj, jfv Sponsored by: EMC / Isilon Storage Division
* Migrate using CPU_ZERO() + CPU_SET() -> CPU_SETOF().adrian2015-02-251-2/+1
| | | | | | | | | Tested: * ixgbe, igb, RSS enabled Submitted by: jhb Sponsored by: Norse Corp, Inc.
OpenPOWER on IntegriCloud