353669 |
16-Oct-2019 |
erj |
MFC r353599
MFCs ixgbe: Disable EEE for backplane X550EM_X
This prevents a possible kernel panic on X552 backplane devices.
PR: 240320 Sponsored by: Intel Corporation |
347419 |
10-May-2019 |
erj |
ix(4): Move {mod,msf,mbx,fdir,phy,link}_task to lock protected handler
This patch introduces adapter->task_requests register responsible for recording requests for mod_task, msf_task, mbx_task, fdir_task, phy_task and link_task calls. Instead of enqueueing each of these tasks with GROUPTASK_ENQUEUE, new task is created and all handlers are called from one task while holding adapter->core_mtx lock.
SIOCGIFXMEDIA ioctl() call reads adapter->media list. The list is deleted and rewritten in ixgbe_handle_msf() task without holding adapter->core_mtx lock. This change is needed to maintain data coherency when sharing adapter info via ioctl() calls.
Since handlers for abovementioned tasks will no longer act as task handlers, but as regular functions, 'pending' parameter is removed from them.
This patch also removes ixgbe_update_link_status() call from ixgbe_handle_link() handler. From now on, link status will be updated by calling ixgbe_update_link_status() periodically from ixgbe_local_timer(). This fixes problem with link flapping during changing interface state to UP.
Parameter keep_traffic is added to ixgbe_disable_intr(). This enables ixgbe_handle_admin_task() to not disable and queue interrupts. Accordingly, skip_traffic parameter is added to ixgbe_enable_intr() to let ixgbe_handle_admin_task() skip enabling queues while enabling interrupts.
This patch is a port of r343621. r343621 can't be merged from current since stable/11 contains ixgbe driver without iflib support.
Patch co-authored by Krzysztof Galazka <krzysztof.galazka@intel.com>.
Submitted by: Piotr Pietruszewski <piotr.pietruszewski@intel.com> Reviewed by: #IntelNetworking Sponsored by: Intel Corporation Differential Revision: https://reviews.freebsd.org/D19711 |
344095 |
13-Feb-2019 |
marius |
MFC: r343203
ixgbe: this statement may fall through warnings with gcc
The recent gcc versions (7 and 8 at least) can check for switch case statements for fall through (implicit-fallthrough). When fall through is intentional, the default method for warning suppression is to place comment /* FALLTHROUGH */ exactly before next case statement.
Differential Revision: https://reviews.freebsd.org/D18577 |
344047 |
12-Feb-2019 |
vmaffione |
MFC r343772, r343867
netmap: refactor logging macros and pipes
Changelist: - Replace ND, D and RD macros with nm_prdis, nm_prinf, nm_prerr and nm_prlim, to avoid possible naming conflicts. - Add netmap_krings_mode_commit() helper function and use that to reduce code duplication. - Refactor pipes control code to export some functions that can be reused by the veth driver (on Linux) and epair(4). - Add check to reject API requests with version less than 11. - Small code refactoring for the null adapter. |
341477 |
04-Dec-2018 |
vmaffione |
MFC r339639
netmap: align codebase to the current upstream (sha 8374e1a7e6941)
Changelist: - Move large parts of VALE code to a new file and header netmap_bdg.[ch]. This is useful to reuse the code within upcoming projects. - Improvements and bug fixes to pipes and monitors. - Introduce nm_os_onattach(), nm_os_onenter() and nm_os_onexit() to handle differences between FreeBSD and Linux. - Introduce some new helper functions to handle more host rings and fake rings (netmap_all_rings(), netmap_real_rings(), ...) - Added new sysctl to enable/disable hw checksum in emulated netmap mode. - nm_inject: add support for NS_MOREFRAG
Approved by: gnn (mentor) Differential Revision: https://reviews.freebsd.org/D17364 |
332481 |
13-Apr-2018 |
shurd |
Move 1-second spin into ixgbe_netmap_reg()
This should still work around the netmap issue, but should not impact other calls to ixgbe_stop().
PR: 221317 Sponsored by: Limelight Networks |
332447 |
12-Apr-2018 |
shurd |
Work around netmap issue with ixgbe
After multiple start/stop of netmap, ixgbe will get into a bad state requiring a reboot to recover. Adding a delay before stopping the interface appears to work around the issue.
The -CURRENT driver has diverged too far from -STABLE for an MFC.
PR: 221317 Submitted by: Sylvain Galliano <sg@efficientip.com> Reported by: Cassiano Peixoto <peixoto.cassiano@gmail.com> Sponsored by: Limelight Networks |
332288 |
08-Apr-2018 |
brooks |
MFC r331797:
Use an accessor function to access ifr_data.
This fixes 32-bit compat (no ioctl command defintions are required as struct ifreq is the same size).
Reviewed by: kib Obtained from: CheriBSD Sponsored by: DARPA, AFRL Differential Revision: https://reviews.freebsd.org/D14900 |
331722 |
29-Mar-2018 |
eadler |
Revert r330897:
This was intended to be a non-functional change. It wasn't. The commit message was thus wrong. In addition it broke arm, and merged crypto related code.
Revert with prejudice.
This revert skips files touched in r316370 since that commit was since MFCed. This revert also skips files that require $FreeBSD$ property changes.
Thank you to those who helped me get out of this mess including but not limited to gonzo, kevans, rgrimes.
Requested by: gjb (re) |
330897 |
14-Mar-2018 |
eadler |
Partial merge of the SPDX changes
These changes are incomplete but are making it difficult to determine what other changes can/should be merged.
No objections from: pfg |
325618 |
09-Nov-2017 |
sbruno |
Merge r323509 and r324994 adding Cavium LiquidIO Driver (lio) to stable/11.
Submitted by: pkanneganti@cavium.com ((Prasad V Kanneganti) Sponsored by: Cavium Networks Differential Revision: https://reviews.freebsd.org/D12425 |
323212 |
06-Sep-2017 |
kib |
MFC r323024: Only make the if_ix module depend on netmap when netmap is configured. |
320917 |
12-Jul-2017 |
sbruno |
MFC r320916
Reset unsupported SFP tuneable back to original entry name.
Reported by: olivier@ |
320897 |
11-Jul-2017 |
erj |
MFC r316541, r316544, and r320688 from HEAD to stable/11.
r316541: Fix a double free in ixgbe_rxeof()
r316544: Don't overwrite vf->flags variable at the end of ixgbe(4) ixgbe_add_vf()
r320688: ixgbe(4): Update HEAD (p3) to 3.2.12-k
Includes:
- Support for X550EM devices. - Support for Bypass adapters. - Flow Director code moved to separate files - SR-IOV code moved to separate files - Netmap code moved to separate files
Sponsored by: Intel Corporation |
313388 |
07-Feb-2017 |
rstone |
MFC r312544
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 |
303268 |
24-Jul-2016 |
sbruno |
MFC r303032 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) |
302408 |
08-Jul-2016 |
gjb |
Copy head@r302406 to stable/11 as part of the 11.0-RELEASE cycle. Prune svn:mergeinfo from the new branch, as nothing has been merged here.
Additional commits post-branch will follow.
Approved by: re (implicit) Sponsored by: The FreeBSD Foundation |
302384 |
07-Jul-2016 |
sbruno |
Do not initialize the adapter on MTU change when adapter status is down. 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
|
301538 |
07-Jun-2016 |
sephe |
net: Use M_HASHTYPE_OPAQUE_HASH if the mbuf flowid has hash properties
Reviewed by: hps, erj, tuexen Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D6688
|
299200 |
06-May-2016 |
pfg |
dev/e1000,ixgbe: minor spelling fixes.
No functional change.
Differential Revision: https://reviews.freebsd.org/D6177
|
298224 |
18-Apr-2016 |
sbruno |
Correct possible underflow conditions when checking for available space 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
|
297793 |
10-Apr-2016 |
pfg |
Cleanup unnecessary semicolons from the kernel.
Found with devel/coccinelle.
|
297482 |
01-Apr-2016 |
sephe |
tcp/lro: Use tcp_lro_flush_all in device drivers to avoid code duplication
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
|
296922 |
16-Mar-2016 |
smh |
Prevent invalid ixgbe advertise setting warning
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
|
295273 |
04-Feb-2016 |
tuexen |
In FreeBSD 10 and higher the driver announces SCTP checksum offloading support 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
|
295094 |
31-Jan-2016 |
smh |
Fix ixgbe flow control autoneg reporting
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
|
295093 |
31-Jan-2016 |
smh |
Configure ixgbe phy & gbic power
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
|
294795 |
26-Jan-2016 |
smh |
ixgbe sysctl hardware defaults
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
|
294734 |
25-Jan-2016 |
smh |
Fix ixgbe compliation with DBG 1
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
|
294578 |
22-Jan-2016 |
smh |
Fix ix advertise value after media change
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
|
294327 |
19-Jan-2016 |
hselasky |
Add optimizing LRO wrapper:
- 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
|
293338 |
07-Jan-2016 |
sbruno |
Fix VF handling of VLANs.
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
|
293334 |
07-Jan-2016 |
sbruno |
Fixup SFP module insertion on the 82599 when insertion happens after 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
|
292751 |
26-Dec-2015 |
bz |
Add missing #ifdef INET after r292674 to allow NOIP and NOINET kernels to build.
|
292697 |
24-Dec-2015 |
sbruno |
Fix NO INET6 build broken at svn r292674
Reported by: ohartman@zedat.fu-berlin.de
|
292674 |
23-Dec-2015 |
sbruno |
ixgbe(4): Update to version 3.1.13-k
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
|
289238 |
13-Oct-2015 |
sbruno |
Add support for sysctl knobs to live tune the per interrupt rx/tx packet processing limits in ixgbe(4)
Differential Revision: https://reviews.freebsd.org/D3719 Submitted by: jason wolfe (j-nitrology.com) MFC after: 2 weeks
|
286238 |
03-Aug-2015 |
sbruno |
A misplaced #endif in ixgbe_ioctl() causes interface MTU to become 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
|
285736 |
21-Jul-2015 |
hiren |
Remove a couple of TUNABLE_INT() calls which are unnecessary after r267961. r267961 did remove them but they "reappeared" when ixgbe(4) rewrite happened in r280182.
Sponsored by: Limelight Networks
|
285592 |
15-Jul-2015 |
pkelsey |
Add netmap support for ixgbe SRIOV VFs (that is, to if_ixv).
Differential Revision: https://reviews.freebsd.org/D2923 Reviewed by: erj, gnn Approved by: jmallett (mentor) Sponsored by: Norse Corp, Inc.
|
285591 |
15-Jul-2015 |
hiren |
Remove FreeBSD version check for deprecated M_FLOWID.
Reviewed by: erj Sponsored by: Limelight Networks
|
285590 |
15-Jul-2015 |
pkelsey |
Fix igxbe SRIOV VF (if_ixv) initialization bugs. The MAC address for 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.
|
285528 |
14-Jul-2015 |
hiren |
Expose full 32bit RSS hash from card regardless of whether RSS is defined or 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
|
285349 |
10-Jul-2015 |
luigi |
Sync netmap sources with the version in our private tree. 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
|
283893 |
01-Jun-2015 |
jhb |
Catch up to the SRIOV API changes in r283670.
|
283883 |
01-Jun-2015 |
jfv |
Delta D2489 - Add SRIOV support to the Intel 10G driver.
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.
|
283882 |
01-Jun-2015 |
jfv |
Revert last commit, to remove added skeleton tree.
|
283881 |
01-Jun-2015 |
jfv |
Delta D2489 - Add SRIOV support to the Intel 10G driver.
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.
|
282299 |
01-May-2015 |
bz |
Remove the extra extern which makes gcc complain; I assume it came from 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().
|
282289 |
30-Apr-2015 |
erj |
Add support for certain Intel X550 devices.
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)
|
282280 |
30-Apr-2015 |
jhb |
Various fixes to the stats in igb(4), ixgbe(4), and ixl(4). - 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.
|
281773 |
20-Apr-2015 |
araujo |
Add back ixgbe_rxeof, just remove the assignment to more.
|
281772 |
20-Apr-2015 |
araujo |
Remove unused variable.
Differential Revision: D2331 Reviewed by: erj
|
280962 |
01-Apr-2015 |
erj |
Make changes to busdma code in tx/rx path similar to the ones made in r257541.
- 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
|
280252 |
19-Mar-2015 |
andrew |
Fix building ixgbe with gcc, it doesn't like nested extern declarations. The fix is to move the extern declaration ix_crcstrip out of ixgbe_setup_hw_rsc.
|
280228 |
18-Mar-2015 |
jfv |
Fix i386 LINT build issues, and remove unused variable.
|
280204 |
18-Mar-2015 |
adrian |
Fix ixgbe(4) to compile - with RSS; with ix+ixv in the kernel.
* 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.
|
280197 |
17-Mar-2015 |
jfv |
Resolve a few build issues, add module directories back into Makefile, then correct a NETMAP problem resulting from the split, and finally temporarily disable the X550 functionality.
|
280182 |
17-Mar-2015 |
jfv |
Update to the Intel ixgbe driver: - 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
|
279805 |
09-Mar-2015 |
araujo |
Fix style(9) from my previous commit r279803.
Spotted by: kevlo
|
279804 |
09-Mar-2015 |
araujo |
Now ifconfig(8) can set the media option as 10Gbase-T for ixgbe(4).
Differential Revision: D823 Reviewed by: jfvogel Approved by: jfvogel Sponsored by: QNAP Systems Inc.
|
279803 |
09-Mar-2015 |
araujo |
Fix the media detected for copper cables NIC based on chipset X540T.
Phabric: D811 Reviewed by: jfvogel Approved by: jfvogel Sponsored by: QNAP Systems Inc.
|
279393 |
28-Feb-2015 |
ngie |
Pad RX copy alignment calculation to avoid illegal memory accesses
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
|
279299 |
25-Feb-2015 |
adrian |
Migrate using CPU_ZERO() + CPU_SET() -> CPU_SETOF().
Tested:
* ixgbe, igb, RSS enabled
Submitted by: jhb Sponsored by: Norse Corp, Inc.
|
279255 |
24-Feb-2015 |
adrian |
Change uses of taskqueue_start_threads_pinned() -> taskqueue_start_threads_cpuset()
Differential Revision: https://reviews.freebsd.org/D1897 Reviewed by: jfv
|
277331 |
18-Jan-2015 |
adrian |
Refactor / restructure the RSS code into generic, IPv4 and IPv6 specific bits.
The motivation here is to eventually teach netisr and potentially other networking subsystems a bit more about how RSS work queues / buckets are configured so things have a hope of auto-configuring in the future.
* net/rss_config.[ch] takes care of the generic bits for doing configuration, hash function selection, etc; * topelitz.[ch] is now in net/ rather than netinet/; * (and would be in libkern if it didn't directly include RSS_KEYSIZE; that's a later thing to fix up.) * netinet/in_rss.[ch] now just contains the IPv4 specific methods; * and netinet/in6_rss.[ch] now just contains the IPv6 specific methods.
This should have no functional impact on anyone currently using the RSS support.
Differential Revision: D1383 Reviewed by: gnn, jfv (intel driver bits)
|
275431 |
02-Dec-2014 |
jfv |
Revert r275136, it was not approved, it was sloppy, if a feature like this is needed please resubmit for Intel's approval.
|
275358 |
01-Dec-2014 |
hselasky |
Start process of removing the use of the deprecated "M_FLOWID" flag from the FreeBSD network code. The flag is still kept around in the "sys/mbuf.h" header file, but does no longer have any users. Instead the "m_pkthdr.rsstype" field in the mbuf structure is now used to decide the meaning of the "m_pkthdr.flowid" field. To modify the "m_pkthdr.rsstype" field please use the existing "M_HASHTYPE_XXX" macros as defined in the "sys/mbuf.h" header file.
This patch introduces new behaviour in the transmit direction. Previously network drivers checked if "M_FLOWID" was set in "m_flags" before using the "m_pkthdr.flowid" field. This check has now now been replaced by checking if "M_HASHTYPE_GET(m)" is different from "M_HASHTYPE_NONE". In the future more hashtypes will be added, for example hashtypes for hardware dedicated flows.
"M_HASHTYPE_OPAQUE" indicates that the "m_pkthdr.flowid" value is valid and has no particular type. This change removes the need for an "if" statement in TCP transmit code checking for the presence of a valid flowid value. The "if" statement mentioned above is now a direct variable assignment which is then later checked by the respective network drivers like before.
Additional notes: - The SCTP code changes will be committed as a separate patch. - Removal of the "M_FLOWID" flag will also be done separately. - The FreeBSD version has been bumped.
MFC after: 1 month Sponsored by: Mellanox Technologies
|
275136 |
26-Nov-2014 |
alfred |
Make igb and ixgbe check tunables at probe time.
This allows one to make a kernel module to tune the number of queues before the driver loads.
This is needed so that a module at SI_SUB_CPU can set tunables for these drivers to take. Otherwise getenv is called too early by the TUNABLE macros.
Reviewed by: smh Phabric: https://reviews.freebsd.org/D1149
|
274588 |
16-Nov-2014 |
melifaro |
Fix r273112: do not turn DROP_EN by default.
Due to adapter->hw.fc.requested_mode is filled with default value after ixgbe_initialize_receive_units(), this leads to enabling DROP_EN in most cases.
Tested by: ae MFC after: 1 week
|
273377 |
21-Oct-2014 |
hselasky |
Fix multiple incorrect SYSCTL arguments in the kernel:
- Wrong integer type was specified.
- Wrong or missing "access" specifier. The "access" specifier sometimes included the SYSCTL type, which it should not, except for procedural SYSCTL nodes.
- Logical OR where binary OR was expected.
- Properly assert the "access" argument passed to all SYSCTL macros, using the CTASSERT macro. This applies to both static- and dynamically created SYSCTLs.
- Properly assert the the data type for both static and dynamic SYSCTLs. In the case of static SYSCTLs we only assert that the data pointed to by the SYSCTL data pointer has the correct size, hence there is no easy way to assert types in the C language outside a C-function.
- Rewrote some code which doesn't pass a constant "access" specifier when creating dynamic SYSCTL nodes, which is now a requirement.
- Updated "EXAMPLES" section in SYSCTL manual page.
MFC after: 3 days Sponsored by: Mellanox Technologies
|
273112 |
15-Oct-2014 |
adrian |
Set the DROP_EN bit before the RX queue is brought up and active.
He noticed issues setting this bit in SRRCTL after the queue was up, so doing it from the sysctl handler isn't enough and may not actually work correctly.
This commit doesn't remove the sysctl path or try to change its behaviour. I'll talk with others about how to finish fixing that before I tackle that.
PR: kern/194311 Submitted by: luigi MFC after: 3 days Sponsored by: Norse Corp, Inc
|
272240 |
28-Sep-2014 |
glebius |
Convert to if_get_counter().
|
272238 |
28-Sep-2014 |
glebius |
Mechanically switch ixv(4) to if_inc_counter().
|
271648 |
15-Sep-2014 |
adrian |
The error bits are not valid with EOP=0; so intermediary fragments should not be discarded.
Submitted by: Marc De La Gueronniere <mdelagueronniere@verisign.com> MFC after: 1 week Sponsored by: Verisign, Inc.
|
271647 |
15-Sep-2014 |
adrian |
Fix a double-free of mbufs in rx_ixgbe_discard().
fmp->buf at the free point is already part of the chain being freed, so double-freeing is counter-productive.
Submitted by: Marc De La Gueronniere <mdelagueronniere@verisign.com> MFC after: 1 week Sponsored by: Verisign, Inc.
|
271286 |
08-Sep-2014 |
brueffer |
Use the right constants in comparisons. This is currently a nop, as MIN_RXD == MIN_TXD and MAX_RXD == MAX_TXD.
Reviewed by: Eric Joyner @ Intel MFC after: 1 week
|
270856 |
30-Aug-2014 |
glebius |
Use define from if_var.h to access a field inside struct if_data, that resides in struct ifnet.
Sponsored by: Nginx, Inc.
|
270822 |
29-Aug-2014 |
melifaro |
* Add SIOCGI2C driver ioctl used to retrieve i2c info. * Convert ixgbe to use this ioctl * Convert ifconfig to use generic i2c handler for "ix" interfaces.
Approved by: Eric Joyner (ixgbe part) MFC after: 2 weeks Sponsored by: Yandex LLC
|
270063 |
16-Aug-2014 |
luigi |
Update to the current version of netmap. Mostly bugfixes or features developed in the past 6 months, so this is a 10.1 candidate.
Basically no user API changes (some bugfixes in sys/net/netmap_user.h).
In detail:
1. netmap support for virtio-net, including in netmap mode. Under bhyve and with a netmap backend [2] we reach over 1Mpps with standard APIs (e.g. libpcap), and 5-8 Mpps in netmap mode.
2. (kernel) add support for multiple memory allocators, so we can better partition physical and virtual interfaces giving access to separate users. The most visible effect is one additional argument to the various kernel functions to compute buffer addresses. All netmap-supported drivers are affected, but changes are mechanical and trivial
3. (kernel) simplify the prototype for *txsync() and *rxsync() driver methods. All netmap drivers affected, changes mostly mechanical.
4. add support for netmap-monitor ports. Think of it as a mirroring port on a physical switch: a netmap monitor port replicates traffic present on the main port. Restrictions apply. Drive carefully.
5. if_lem.c: support for various paravirtualization features, experimental and disabled by default. Most of these are described in our ANCS'13 paper [1]. Paravirtualized support in netmap mode is new, and beats the numbers in the paper by a large factor (under qemu-kvm, we measured gues-host throughput up to 10-12 Mpps).
A lot of refactoring and additional documentation in the files in sys/dev/netmap, but apart from #2 and #3 above, almost nothing of this stuff is visible to other kernel parts.
Example programs in tools/tools/netmap have been updated with bugfixes and to support more of the existing features.
This is meant to go into 10.1 so we plan an MFC before the Aug.22 deadline.
A lot of this code has been contributed by my colleagues at UNIPI, including Giuseppe Lettieri, Vincenzo Maffione, Stefano Garzarella.
MFC after: 3 days.
|
269972 |
14-Aug-2014 |
smh |
Renamed hw.ixgbe.unsupported_sfp -> hw.ix.unsupported_sfp
This now matches all other ixgbe sysctl / tunables.
Sponsored by: Multiplay
|
268917 |
20-Jul-2014 |
adrian |
Add the UDP hash -> RSS mbuf hash type for the ixgbe(4) driver.
|
268916 |
20-Jul-2014 |
adrian |
Teach ixgbe(4) about rss_gethashconfig().
If RSS is enabled, ixgbe(4) will query the RSS API for the types of hashes which should be used. It'll then only enable hashes that are exposed via the RSS layer.
This way it won't try to do things like enable UDP hashing if RSS explicitly states that it isn't supported in lookups.
Tested:
* 82599EB ixgbe(4) NIC
|
268915 |
20-Jul-2014 |
adrian |
Disable the ixgbe(4) UDP 4-tuple hashing for the time being.
A mix of fragmented and non-fragmented UDP in a single stream will end up being hashed differently, resulting in out-of-order behaviour in the receive path.
This was done in the linux e1000 driver in 2011.
Discussed with: jfv
|
268907 |
20-Jul-2014 |
adrian |
Correctly program the RSS redirection table entries.
Without this, the RSS bucket assignments aren't correct - they're DCBA instead of ABCD in each DWORD.
Tested: 82599EB ixgbe(4), TCP and UDP RSS
|
268790 |
17-Jul-2014 |
hiren |
Fix a typo.
PR: 191898 Submitted by: vsjcfm@gmail.com
|
268067 |
30-Jun-2014 |
adrian |
Initialise these variables so gcc doesn't complain.
Submitted by: luigi
|
268029 |
30-Jun-2014 |
adrian |
Add initial RSS awareness to the ixgbe(4) driver.
The ixgbe(4) hardware is capable of RSS hashing RX packets and doing RSS queue selection for up to 8 queues.
However, even if multi-queue is enabled for ixgbe(4), the RX path doesn't use the RSS flowid from the received descriptor. It just uses the MSIX queue id.
This patch does a handful of things if RSS is enabled:
* Instead of using a random key at boot, fetch the RSS key from the RSS code and program that in to the RSS redirection table.
That whole chunk of code should be double checked for endian correctness.
* Use the RSS queue mapping to CPU ID to figure out where to thread pin the RX swi thread and the taskqueue threads for each queue.
* The software queue is now really an "RSS bucket".
* When programming the RSS indirection table, use the RSS code to figure out which RSS bucket each slot in the indirection table maps to.
* When transmitting, use the flowid RSS mapping if the mbuf has an RSS aware hash. The existing method wasn't guaranteed to align correctly with the destination RSS bucket (and thus CPU ID.)
This code warns if the number of RSS buckets isn't the same as the automatically configured number of hardware queues. The administrator will have to tweak one of them for better performance.
There's currently no way to re-balance the RSS indirection table after startup. I'll worry about that later.
Additionally, it may be worthwhile to always use the full 32 bit flowid if multi-queue is enabled. It'll make things like lagg(4) behave better with respect to traffic distribution.
|
267992 |
28-Jun-2014 |
hselasky |
Pull in r267961 and r267973 again. Fix for issues reported will follow.
|
267985 |
27-Jun-2014 |
gjb |
Revert r267961, r267973:
These changes prevent sysctl(8) from returning proper output, such as:
1) no output from sysctl(8) 2) erroneously returning ENOMEM with tools like truss(1) or uname(1) truss: can not get etype: Cannot allocate memory
|
267961 |
27-Jun-2014 |
hselasky |
Extend the meaning of the CTLFLAG_TUN flag to automatically check if there is an environment variable which shall initialize the SYSCTL during early boot. This works for all SYSCTL types both statically and dynamically created ones, except for the SYSCTL NODE type and SYSCTLs which belong to VNETs. A new flag, CTLFLAG_NOFETCH, has been added to be used in the case a tunable sysctl has a custom initialisation function allowing the sysctl to still be marked as a tunable. The kernel SYSCTL API is mostly the same, with a few exceptions for some special operations like iterating childrens of a static/extern SYSCTL node. This operation should probably be made into a factored out common macro, hence some device drivers use this. The reason for changing the SYSCTL API was the need for a SYSCTL parent OID pointer and not only the SYSCTL parent OID list pointer in order to quickly generate the sysctl path. The motivation behind this patch is to avoid parameter loading cludges inside the OFED driver subsystem. Instead of adding special code to the OFED driver subsystem to post-load tunables into dynamically created sysctls, we generalize this in the kernel.
Other changes: - Corrected a possibly incorrect sysctl name from "hw.cbb.intr_mask" to "hw.pcic.intr_mask". - Removed redundant TUNABLE statements throughout the kernel. - Some minor code rewrites in connection to removing not needed TUNABLE statements. - Added a missing SYSCTL_DECL(). - Wrapped two very long lines. - Avoid malloc()/free() inside sysctl string handling, in case it is called to initialize a sysctl from a tunable, hence malloc()/free() is not ready when sysctls from the sysctl dataset are registered. - Bumped FreeBSD version to indicate SYSCTL API change.
MFC after: 2 weeks Sponsored by: Mellanox Technologies
|
267385 |
12-Jun-2014 |
jhb |
- Don't compare bus_dma map pointers for static DMA allocations against NULL to determine if bus_dmamap_unload() or bus_dmamem_free() should be called. Instead, check the associated bus and virtual addresses. - Don't clear static DMA maps to NULL.
Reviewed by: jfv
|
267187 |
06-Jun-2014 |
luigi |
make sure if_transmit returns 0 if the mbuf is enqueued. ixgbe/ixv.c still needs a similar fix but it takes a little more restructuring of the code.
MFC after: 3 days
|
263102 |
13-Mar-2014 |
glebius |
Since 32-bit if_baudrate isn't enough to describe a baud rate of a 10 Gbit interface, in the r241616 a crutch was provided. It didn't work well, and finally we decided that it is time to break ABI and simply make if_baudrate a 64-bit value. Meanwhile, the entire struct if_data was reviewed.
o Remove the if_baudrate_pf crutch.
o Make all fields of struct if_data fixed machine independent size. The notion of data (packet counters, etc) are by no means MD. And it is a bug that on amd64 we've got a 64-bit counters, while on i386 32-bit, which at modern speeds overflow within a second.
This also removes quite a lot of COMPAT_FREEBSD32 code.
o Give 16 bit for the ifi_datalen field. This field was provided to make future changes to if_data less ABI breaking. Unfortunately the 8 bit size of it had effectively limited sizeof if_data to 256 bytes.
o Give 32 bits to ifi_mtu and ifi_metric. o Give 64 bits to the rest of fields, since they are counters.
__FreeBSD_version bumped.
Discussed with: emax Sponsored by: Netflix Sponsored by: Nginx, Inc.
|
260368 |
06-Jan-2014 |
luigi |
It is 2014 and we have a new version of netmap. Most relevant features:
- netmap emulation on any NIC, even those without native netmap support.
On the ixgbe we have measured about 4Mpps/core/queue in this mode, which is still a lot more than with sockets/bpf.
- seamless interconnection of VALE switch, NICs and host stack.
If you disable accelerations on your NIC (say em0)
ifconfig em0 -txcsum -txcsum
you can use the VALE switch to connect the NIC and the host stack:
vale-ctl -h valeXX:em0
allowing sharing the NIC with other netmap clients.
- THE USER API HAS SLIGHTLY CHANGED (head/cur/tail pointers instead of pointers/count as before). This was unavoidable to support, in the future, multiple threads operating on the same rings. Netmap clients require very small source code changes to compile again. On the plus side, the new API should be easier to understand and the internals are a lot simpler.
The manual page has been updated extensively to reflect the current features and give some examples.
This is the result of work of several people including Giuseppe Lettieri, Vincenzo Maffione, Michio Honda and myself, and has been financially supported by EU projects CHANGE and OPENLAB, from NetApp University Research Fund, NEC, and of course the Universita` di Pisa.
|
259646 |
20-Dec-2013 |
glebius |
Fix build broken in r259644.
Submitted by: tuexen Pointy hat to: glebius
|
259644 |
20-Dec-2013 |
glebius |
ixgbe(4) takes packet counters from hardware in ixgbe_update_stats_counters(), so we don't need to do a per packet increment, which trashes cache line.
Submitted by: oleg
|
257695 |
05-Nov-2013 |
oleg |
- Fix link loss on vlan reconfiguration. - Fix issues with 'vlanhwfilter'.
MFC after: 1 week Silence from: jfv 5 weeks
|
257529 |
01-Nov-2013 |
luigi |
update to the latest netmap snapshot. This includes the following: - use separate memory regions for VALE ports - locking fixes - some simplifications in the NIC-specific routines - performance improvements for the VALE switch - some new features in the pkt-gen test program - documentation updates
There are small API changes that require programs to be recompiled (NETMAP_API has been bumped so you will detect old binaries at runtime).
In particular: - struct netmap_slot now is 16 bytes to support an extra pointer, which may save one data copy when using VALE ports or VMs; - the struct netmap_if has two extra fields;
MFC after: 3 days
|
257176 |
26-Oct-2013 |
glebius |
The r48589 promised to remove implicit inclusion of if_var.h soon. Prepare to this event, adding if_var.h to files that do need it. Also, include all includes that now are included due to implicit pollution via if_var.h
Sponsored by: Netflix Sponsored by: Nginx, Inc.
|
256218 |
09-Oct-2013 |
glebius |
There are some high performance NICs that count statistics in hardware, and there are ifnets, that do that via counter(9). Provide a flag that would skip cache line trashing '+=' operation in ether_input().
Sponsored by: Netflix Sponsored by: Nginx, Inc. Reviewed by: melifaro, adrian Approved by: re (marius)
|
256069 |
05-Oct-2013 |
hiren |
Expose system level ixgbe sysctls. Device level sysctls are already exposed as dev.ix.<device>
Fixing the case where number of queues for igb is auto-tuned and hw.igb.num_queues does not return current/updated value.
Reviewed by: jfv Approved by: re (delphij) MFC after: 2 weeks
|
254804 |
24-Aug-2013 |
andre |
Restructure the mbuf pkthdr to make it fit for upcoming capabilities and features. The changes in particular are:
o Remove rarely used "header" pointer and replace it with a 64bit protocol/ layer specific union PH_loc for local use. Protocols can flexibly overlay their own 8 to 64 bit fields to store information while the packet is worked on.
o Mechanically convert IP reassembly, IGMP/MLD and ATM to use pkthdr.PH_loc instead of pkthdr.header.
o Extend csum_flags to 64bits to allow for additional future offload information to be carried (e.g. iSCSI, IPsec offload, and others).
o Move the RSS hash type enumerator from abusing m_flags to its own 8bit rsstype field. Adjust accessor macros.
o Add cosqos field to store Class of Service / Quality of Service information with the packet. It is not yet supported in any drivers but allows us to get on par with Cisco/Juniper in routing applications (plus MPLS QoS) with a modernized ALTQ.
o Add four 8 bit fields l[2-5]hlen to store the relative header offsets from the start of the packet. This is important for various offload capabilities and to relieve the drivers from having to parse the packet and protocol headers to find out location of checksums and other information. Header parsing in drivers is a lot of copy-paste and unhandled corner cases which we want to avoid.
o Add another flexible 64bit union to map various additional persistent packet information, like ether_vtag, tso_segsz and csum fields. Depending on the csum_flags settings some fields may have different usage making it very flexible and adaptable to future capabilities.
o Restructure the CSUM flags to better signify their outbound (down the stack) and inbound (up the stack) use. The CSUM flags used to be a bit chaotic and rather poorly documented leading to incorrect use in many places. Bring clarity into their use through better naming. Compatibility mappings are provided to preserve the API. The drivers can be corrected one by one and MFC'd without issue.
o The size of pkthdr stays the same at 48/56bytes (32/64bit architectures).
Sponsored by: The FreeBSD Foundation
|
254263 |
12-Aug-2013 |
scottl |
Update PCI drivers to no longer look at the MEMIO-enabled bit in the PCI command register. The lazy BAR allocation code in FreeBSD sometimes disables this bit when it detects a range conflict, and will re-enable it on demand when a driver allocates the BAR. Thus, the bit is no longer a reliable indication of capability, and should not be checked. This results in the elimination of a lot of code from drivers, and also gives the opportunity to simplify a lot of drivers to use a helper API to set the busmaster enable bit.
This changes fixes some recent reports of disk controllers and their associated drives/enclosures disappearing during boot.
Submitted by: jhb Reviewed by: jfv, marius, achadd, achim MFC after: 1 day
|
254262 |
12-Aug-2013 |
jfv |
Improve the MSIX setup code in the drivers, thanks to Marius for the changes. Make sure that pci_alloc_msix() does give us the vectors we need and fall back to MSI when it doesn't, also release any that were allocated when insufficient.
MFC after: 3 days
|
254008 |
06-Aug-2013 |
jfv |
Make the various driver MSIX setup routines fallback to MSI more gracefully. This change was suggested by Marius Strobl, thank you.
PR: kern/181016 MFC after: ASAP
|
253965 |
05-Aug-2013 |
jfv |
Correct a fat-finger in the last delta.
MFC after: ASAP
|
253865 |
01-Aug-2013 |
jfv |
A number of important fixes: - mbuf reused after an RX_COPY optimized operation can sometimes have a bogus cached address, resulting in TCP hangs. Add critical save points to the cached address. Thanks to Michael and the team at Verisign for finding this problem. - A couple more spots where the rxbuf->flags member should be cleared just to be sure no incorrect RX_COPY state is left around. Thanks to Adrian for tracking these down. - Remove the rearm_queues function from the driver, this was found to be responsible for some out-of-order packets by Verisign, and was always a bandaid, with the other fixes in this delta the bandaid can finally be removed. - In the other/link interrupt handler the entire state of the EICS register was being writen back into EICR (which clears causes and thus re-enables those interrupts), this was wrong, so now mask off the queue portion of the register value, so we only clear the other/link interrupt we intend. Marc from Verisign found this. - Make the SFP+ unsupported option tuneable now, by customer request. - Finally, just a couple of minor DEBUG string fixes.
I want to call out and thank all the participants in the 10G community/Intel calls for helping track down these problems and make the driver better for everyone!
MFC after: 3 days, these are critical fixes for 9.2!
|
253285 |
12-Jul-2013 |
jfv |
Opps, need to change the VF code as well.
MFC after: ASAP
|
253284 |
12-Jul-2013 |
jfv |
Remove the conditional define around the option headers, when building the driver as a module the result of the present system results in INET and INET6 being undefined, and will cause the panic in ixgbe_tso_setup(). The Makefile in the module directory now renders the conditional in the source unnecessary and wrong.
MFC after: ASAP - the panic as a module must not get into 9.2
|
253179 |
11-Jul-2013 |
jfv |
Fix my last commit, flags rather than flag... duh.
MFC after: 2 days
|
253176 |
10-Jul-2013 |
jfv |
Fix to a panic found internally, bad pointer during rxeof processing. Thanks for John Baldwin for catching this. Not clearing the flag member of the rxbuf could result in a NULL mbuf pointer being used.
MFC after: 2 days (this needs to get into 9.2!)
|
251964 |
18-Jun-2013 |
jfv |
Add quad port probe support, this gives the admin proper information about the slot (which should be a PCIE Gen 3 slot for this adapter) by looking back thru the PCI parent devices to the slot device.
The fix above also corrects the bandwidth display to GT/s rather than the incorrect Gb/s
Next, allow the use of ALTQ if you select the compile option IXGBE_LEGACY_TX.
Allow the use of 'unsupported' optic modules by a compile option as well.
Add a phy reset capability into the stop code, this is so a static configured driver will still behave properly when taken down (not being able to unload it).
This revision synchronizes the shared code with Intel internal current code, and note that it now includes DCB supporting code, this was necessitated by some internal changes with the code, but it also will provide the opportunity to develop this feature in the core driver down the road.
I have edited the README to get rid of some of the worse anachronisms in it as well, its by no means as robust as I might wish at this point however.
Oh, I also have included some conditional stuff in the code so it will be compatible in both the 9.X and 10 environments.
Performance has been a focus in recent changes and I believe this revision driver will perform very well in most workloads.
MFC after: 2 weeks
|
250108 |
30-Apr-2013 |
luigi |
use netmap_rx_irq() / netmap_tx_irq() to handle interrupts in netmap mode, removing the logic from individual drivers.
(note: if_lem.c not updated yet due to some other pending modifications)
|
248901 |
29-Mar-2013 |
jfv |
Two small fixes: Set promiscuous code was unconditionally turning off multicast when turning off promiscuous mode, this should only be done when there are less than MAX groups. Thanks to Mike Karels for this correction.
Second, the overtmp interrupt setup/detection was wrong, correcting it.
MFC after: one week
|
247823 |
04-Mar-2013 |
jfv |
Fix a small, but important bug, a task drain was mistakenly being compiled only when setting LEGACY_TX, this means you would not get the drain when needed on detach!!
Thanks to Bryan Venteicher (bryanv@freebsd.org) for catching this little gremlin!! :)
|
247822 |
04-Mar-2013 |
jfv |
First, sync to internal shared code, and then
Fixes: - flow control - don't override user value on re-init - fix to make 1G optics work correctly - change to interrupt enabling - some bits were incorrect for certain hardware. - certain stats fixes, remove a duplicate increment of ierror, thanks to Scott Long for pointing these out. - shared code link interface changed, requiring some core code changes to accomodate this. - add an m_adj() to ETHER_ALIGN on the recieve side, this was requested by Mike Karels, thanks Mike. - Multicast code corrections also thanks to Mike Karels.
|
247056 |
20-Feb-2013 |
des |
revert 247035
|
247035 |
20-Feb-2013 |
des |
Reduce excessive nesting.
|
246482 |
07-Feb-2013 |
rrs |
This fixes a out-of-order problem with several of the newer drivers. The basic problem was that the driver was pulling the mbuf off the drbr ring and then when sending with xmit(), encounting a full transmit ring. Thus the lower layer xmit() function would return an error, and the drivers would then append the data back on to the ring. For TCP this is a horrible scenario sure to bring on a fast-retransmit.
The fix is to use drbr_peek() to pull the data pointer but not remove it from the ring. If it fails then we either call the new drbr_putback or drbr_advance method. Advance moves it forward (we do this sometimes when the xmit() function frees the mbuf). When we succeed we always call advance. The putback will always copy the mbuf back to the top of the ring. Note that the putback *cannot* be used with a drbr_dequeue() only with drbr_peek(). We most of the time, in putback, would not need to copy it back since most likey the mbuf is still the same, but sometimes xmit() functions will change the mbuf via a pullup or other call. So the optimial case for the single consumer is to always copy it back. If we ever do a multiple_consumer (for lagg?) we will need a test and atomic in the put back possibly a seperate putback_mc() in the ring buf.
Reviewed by: jhb@freebsd.org, jlv@freebsd.org
|
246128 |
30-Jan-2013 |
sbz |
Use DEVMETHOD_END macro defined in sys/bus.h instead of {0, 0} sentinel on device_method_t arrays
Reviewed by: cognet Approved by: cognet
|
245952 |
26-Jan-2013 |
pfg |
Clean some 'svn:executable' properties in the tree.
Submitted by: Christoph Mallon MFC after: 3 days
|
244514 |
20-Dec-2012 |
luigi |
rename the 'tag' and 'map' fields used the rx ring to their previous names, 'ptag' and 'pmap' -- p stands for packet.
This change reduces the difference between the code in stable/9 and head, and also helps using the same ixgbe_netmap.h on both branches.
Approved by: Jack Vogel
|
243857 |
04-Dec-2012 |
glebius |
Mechanically substitute flags from historic mbuf allocator with malloc(9) flags in sys/dev.
|
243833 |
03-Dec-2012 |
jfv |
Remove the sysctl process_limit interface, after some thought I've decided its overkill,a simple tuneable for each RX and TX limit, and then init sets the ring values based on that, should be sufficient.
More importantly, fix a bug causing a panic, when changing the define style to IXGBE_LEGACY_TX a taskqueue init was inadvertently set #ifdef when it should be #ifndef.
|
243741 |
01-Dec-2012 |
jfv |
Patch #12 OK, I said there was only 11 patches, but unfortunately the revamped sysctl code did not work, and needed a change. This makes the limit get set at the time that all sysctl stats are created and is actually more elegant imho anyway.
|
243736 |
01-Dec-2012 |
jfv |
Patch #11 - The final patch: this one greatly improves the TX hot path by getting rid of index calculations and simply managing pointers. Much of the creative code is due to my coworker here at Intel, Alex Duyck, thanks Alex!
Also, this whole series of patches was given the critical eye of Gleb Smirnoff and is all the better for it, thanks Gleb!
|
243735 |
01-Dec-2012 |
jfv |
Patch #10 Performance - this changes the protocol offload interface and code in the TX path,making it tighter and hopefully more efficient.
|
243733 |
01-Dec-2012 |
jfv |
Patch #9 Performance - improve the tx dma failure path, similar to a change done in igb long ago.
|
243729 |
30-Nov-2012 |
jfv |
Patch #8 Performance changes - this one improves locality, moving some counters and data to the ring struct from the adapter struct, also compressing some data in the move.
|
243728 |
30-Nov-2012 |
jfv |
Patch #7 This is primarily about processing limit control. - add a limit for both RX and TX, change the default to 256 - change the sysctl usage to be common, and now to be called during init for each ring. - the TX limit is not yet used, but the changes in the last patch in this series uses the value. - the motivation behind these changes is to improve data locality in the final code. - rxeof interface changes since it now gets limit from the ring struct
|
243725 |
30-Nov-2012 |
jfv |
Patch #6 Whitespace cleanup, and removal of some very old defines (at Gleb's request). Also, change the defines around the old transmit code to IXGBE_LEGACY_TX, I do this to make it possible to define this regardless of the OS level (it is not defined by default). There are also a couple changed comments for clarity.
|
243724 |
30-Nov-2012 |
jfv |
Patch #5 Cleanup unused IEEE1588 code fragments, the day may come when this feature gets implemented, but its not here yet and I see no reason to leave this laying around.
|
243721 |
30-Nov-2012 |
jfv |
Patch #4 - this does two things, it removes a number of statistics, these are FCOE stats (fiber channel over ethernet), something that FreeBSD does not yet have, they were mistaken for flow control by the implementor I believe. Secondly, the real flow control stats are oddly named with a 'link' tag on the front, it was requested by my validation engineer to make these stats have the same name as the igb driver for clarity and that seemed reasonable to me.
|
243718 |
30-Nov-2012 |
jfv |
Patch #3 - Add a new ioctl to access SFP+ module diagnostic data via the I2C routines in shared code.
|
243716 |
30-Nov-2012 |
jfv |
Patch #2 - remove OACTIVE and DEPLETED notions from the multiqueue code, this functionality has proven to be more trouble than it was worth. Thanks to Gleb for a second critical look over my code and help in the patches!
|
243714 |
30-Nov-2012 |
jfv |
First of a series of 11 patches leading to new ixgbe version 2.5.0 This removes the header split and supporting code from the driver.
|
242421 |
31-Oct-2012 |
jfv |
A few important fixes: - Testing TSO6 has led me to discover that HW RSC is a problematic feature, it is ONLY designed to work with IPv4 in the first place, and if IP forwarding is done it can't be disabled as LRO in the stack, also initial testing we've done at Intel shows an equal performance using TSO[46] on the TX and LRO on RX, if you ran older code on 82599 or later hardware you actually could have detrimental performance for this reason. So I am disabling the feature by default and all our adapters will now use LRO instead.
- If you have flow control off and multiple queues it was possible when the buffer of one queue becomes full that all RX movement is stalled, to eliminate this problem a feature bit is now set that will allow packets to be dropped when full rather than stall. Note, the default is to have flow control on, and this keeps this from happening.
- Because of the recent fixes in the stack, LRO is now auto-disabled when problematic, so I have decided to enable it by default in the capabilities in the driver.
- There are some 1G modules used by some customers, a couple small tweaks to properly support those in the media code.
- A note: we have now done some testing of TSO6 and using LRO with IPv6 and it all works great!! Seeing line rate in both directions in best cases. Thanks bz for your excellent work!!
|
242403 |
31-Oct-2012 |
jfv |
Correct code that was lost somewhere in the past, this was designed to keep duplicate null vlan tags from being added. When doing vlans purely via the switch this problem will occur. Reported by external customer.
|
241917 |
22-Oct-2012 |
eadler |
Now that device disabling is generic, remove extraneous code from the device drivers that used to provide this feature.
This is a subset of 241856 (which was reverted)
Reviewed by: des Approved by: cperciva (implicit) MFC after: 1 week
|
241885 |
22-Oct-2012 |
eadler |
This isn't functionally identical. In some cases a hint to disable unit 0 would in fact disable all units.
This reverts r241856
Approved by: cperciva (implicit)
|
241856 |
22-Oct-2012 |
eadler |
Now that device disabling is generic, remove extraneous code from the device drivers that used to provide this feature.
Reviewed by: des Approved by: cperciva MFC after: 1 week
|
241646 |
17-Oct-2012 |
emax |
provide helper if_initbaudrate() to set if_baudrate_pf and if_baudrate_pf. again, use ixgbe(4) as an example of how to use new helper function.
Reviewed by: jhb MFC after: 1 week
|
241616 |
16-Oct-2012 |
emax |
introduce concept of ifi_baudrate power factor. the idea is to work around the problem where high speed interfaces (such as ixgbe(4)) are not able to report real ifi_baudrate. bascially, take a spare byte from struct if_data and use it to store ifi_baudrate power factor. in other words,
real ifi_baudrate = ifi_baudrate * 10 ^ ifi_baudrate power factor
this should be backwards compatible with old binaries. use ixgbe(4) as an example on how drivers would set ifi_baudrate power factor
Discussed with: kib, scottl, glebius MFC after: 1 week
|
241037 |
28-Sep-2012 |
glebius |
The drbr(9) API appeared to be so unclear, that most drivers in tree used it incorrectly, which lead to inaccurate overrated if_obytes accounting. The drbr(9) used to update ifnet stats on drbr_enqueue(), which is not accurate since enqueuing doesn't imply successful processing by driver. Dequeuing neither mean that. Most drivers also called drbr_stats_update() which did accounting again, leading to doubled if_obytes statistics. And in case of severe transmitting, when a packet could be several times enqueued and dequeued it could have been accounted several times.
o Thus, make drbr(9) API thinner. Now drbr(9) merely chooses between ALTQ queueing or buf_ring(9) queueing. - It doesn't touch the buf_ring stats any more. - It doesn't touch ifnet stats anymore. - drbr_stats_update() no longer exists.
o buf_ring(9) handles its stats itself: - It handles br_drops itself. - br_prod_bytes stats are dropped. Rationale: no one ever reads them but update of a common counter on every packet negatively affects performance due to excessive cache invalidation. - buf_ring_enqueue_bytes() reduced to buf_ring_enqueue(), since we no longer account bytes.
o Drivers handle their stats theirselves: if_obytes, if_omcasts.
o mlx4(4), igb(4), em(4), vxge(4), oce(4) and ixv(4) no longer use drbr_stats_update(), and update ifnet stats theirselves.
o bxe(4) was the most correct driver, it didn't call drbr_stats_update(), thus it was the only driver accurate under moderate load. Now it also maintains stats itself.
o ixgbe(4) had already taken stats from hardware, so just - drop software stats updating. - take multicast packet count from hardware as well.
o mxge(4) just no longer needs NO_SLOW_STATS define.
o cxgb(4), cxgbe(4) need no change, since they obtain stats from hardware.
Reviewed by: jfv, gnn
|
240968 |
26-Sep-2012 |
jhb |
Merge similar fixes from 223198 from igb to ixgbe: - Use a dedicated task to handle deferred transmits from the if_transmit method instead of reusing the existing per-queue interrupt task. Reusing the per-queue interrupt task could result in both an interrupt thread and the taskqueue thread trying to handle received packets on a single queue resulting in out-of-order packet processing and lock contention. - Don't define ixgbe_start() at all where if_transmit is used.
Tested by: Vijay Singh Reviewed by: jfv MFC after: 2 weeks
|
240466 |
13-Sep-2012 |
eadler |
Define missing DEBUGOUT# macros. DEBUGOUT[45] are not yet used but are being defined pre-emptively to avoid future build breakage
PR: kern/168967 Submitted by: fuzhli <fuzl@arraynetworks.com.cn> Approved by: cperciva MFC after: 1 week
|
240366 |
11-Sep-2012 |
scottl |
Remove a prefetch() directive that, after careful testing, does more harm than good.
Submitted by: Fabien Thomas Reviewed by: jfv
|
240155 |
06-Sep-2012 |
kevlo |
Add missing braces
Obtained from: DragonFly
|
239940 |
31-Aug-2012 |
scottl |
Heavily optimize the case of small RX packets of 160 bytes or less. For this case, allocate a plain mbuf and copy the frame into it, then send the copy up the stack, leaving the original mbuf+cluster in place in the receive ring for immediate re-use. This saves a trip through 2 of the 3 zones of the compound mbuf allocator, a trip through busdma, and a trip through the 1 of the 3 mbuf destructors. For our load at Netflix, this can lower CPU consumption by as much as 20%. The copy algorithm is based on investigative work from Luigi Rizzo earlier in the year.
Reviewed by: jfv Obtained from: Netflix
|
238149 |
05-Jul-2012 |
jfv |
Update to the ixgbe driver: - Add a couple of new devices - Flow control changes in shared and core code - Bug fix to Flow Director for 82598 - Shared code sync to internal with required core change
Thanks to those helping in the testing and improvements to this driver!
MFC after:5 days
|
236729 |
07-Jun-2012 |
emax |
Correct typo(?) and actually set PTHRESH to 32 and not 16 as per Intel Linux driver 3.8.21.
MFC after: 1 week
|
236627 |
05-Jun-2012 |
emax |
Before it gets lost in the noise.
Put a bandaid to prevent ixgbe(4) from completely locking up the system under high load. Our platform has a few CPU cores and a single active ixgbe(4) port with 4 queues. Under high enough traffic load, at about 7.5GBs and 700,000 packets/sec (outbound), the entire system would deadlock. What we found was that each CPU was in an endless loop on a different ix taskqueue thread. The OACTIVE flag had gotten set on each queue, and the ixgbe_handle_queue() function was continuously rescheduling itself via the taskqueue_enqueue. Since all CPUs were busy with their taskqueue threads, the ixgbe_local_timer() function couldn't run to clear the OACTIVE flag.
Submitted by: scottl MFC after: 1 week
|
235964 |
25-May-2012 |
bz |
MFp4 bz_ipv6_fast:
Add TSO6 and LRO/IPv6 support. Fix the module Makefile to at least properly inlcude opt_inet6.h and allow builds without INET or INET6.
Sponsored by: The FreeBSD Foundation Sponsored by: iXsystems
Reviewed by: gnn (as part of the whole) MFC After: 3 days
|
235547 |
17-May-2012 |
luigi |
fix a typo in a comment
|
234620 |
23-Apr-2012 |
bz |
If we pass down 64k - L2 hdr size + 1 to 64K L3+ data adding an ether header will make the data go over the 64k limits announced to busdma as maxsize and the transaction will fail.
With TSO this can result in a TCP regression due to the lost packet.
According to the data sheets ixgbe(4) 82598 and 82599 can handle up to 256k so increase the maximum.
Reported by: Jon Kåre Hellan, UNINETT (jon.kare.hellan uninett.no) Tested by: Jon Kåre Hellan, UNINETT (jon.kare.hellan uninett.no) MFC after: 1 week
|
234229 |
13-Apr-2012 |
luigi |
Properly disable crc stripping when operating in netmap mode.
Contrarily to what i wrote in my previous commit, the 82599 does include the CRC in the length. The operating mode is reset in ixgbe_init_locked() and so we need to hook into the places where the two registers (HLREG0 and RDRXCTL) are modified.
|
234137 |
11-Apr-2012 |
luigi |
Enable prefetching of descriptors on the TX ring, using the same values as in the Intel driver 3.8.21 for linux. The fact that it is standard in the above driver suggests that it has no bad side effects.
But of course there must be a reason for enabling features, not just "it does not harm", so here it is a good one:
Prefetching enables full line rate even using a single queue (14.88 Mpps, compared to ~12 Mpps without prefetch). This in turn is terribly useful when one wants to schedule traffic.
For obvious reasons the difference is only visible with netmap or other high speed solutions, but presumably the advantage should be in the order of a fraction of a microsecond when starting transmission on an empty queue.
Discussed with Jack Vogel.
MFC after: 1 week
|
232874 |
12-Mar-2012 |
scottl |
More conversions of drivers to use the PCI parent DMA tag.
|
232238 |
27-Feb-2012 |
luigi |
A bunch of netmap fixes:
USERSPACE: 1. add support for devices with different number of rx and tx queues;
2. add better support for zero-copy operation, adding an extra field to the netmap ring to indicate how many buffers we have already processed but not yet released (with help from Eddie Kohler);
3. The two changes above unfortunately require an API change, so while at it add a version field and some spares to the ioctl() argument to help detect mismatches.
4. update the manual page for the two changes above;
5. update sample applications in tools/tools/netmap
KERNEL:
1. simplify the internal structures moving the global wait queues to the 'struct netmap_adapter';
2. simplify the functions that map kring<->nic ring indexes
3. normalize device-specific code, helps mainteinance;
4. start exploring the impact of micro-optimizations (prefetch etc.) in the ixgbe driver. Use 'legacy' descriptors on the tx ring and prefetch slots gives about 20% speedup at 900 MHz. Another 7-10% would come from removing the explict calls to bus_dmamap* in the core (they are effectively NOPs in this case, but it takes expensive load of the per-buffer dma maps to figure out that they are all NULL.
Rx performance not investigated.
I am postponing the MFC so i can import a few more improvements before merging.
|
231796 |
15-Feb-2012 |
luigi |
(This commit only touches code within the DEV_NETMAP blocks)
Introduce some functions to map NIC ring indexes into netmap ring indexes and vice versa. This way we can implement the bound checks only in one place (and hopefully in a correct way).
On passing, make the code and comments more uniform across the various drivers.
|
230790 |
30-Jan-2012 |
jfv |
Wrap the bool typedef
|
230775 |
30-Jan-2012 |
jfv |
New hardware support: Intel X540 adapter support added. Some shared code reorganization along with the new adapter. Sync changes to OACTIVE in igb into this driver. Misc small fixes.
|
230572 |
26-Jan-2012 |
luigi |
ixgbe changes: - remove experimental code for disabling CRC - use the correct constant for conversion between interrupt rate and EITR values (the previous values were off by a factor of 2) - make dev.ix.N.queueM.interrupt_rate a RW sysctl variable. Changing individual values affects the queue immediately, and propagates to all interfaces at the next reinit. - add dev.ix.N.queueM.irqs rdonly sysctl, to export the actual interrupt counts
Netmap-related changes for ixgbe: - use the "new" format for TX descriptors in netmap mode. - pass interrupt mitigation delays to the user process doing poll() on a netmap file descriptor. On the RX side this means we will not check the ring more than once per interrupt. This gives the process a chance to sleep and process packets in larger batches, thus reducing CPU usage. On the TX side we take this even further: completed transmissions are reclaimed every half ring even if the NIC interrupts more often. This saves even more CPU without any additional tx delays.
Generic Netmap-related changes: - align the netmap_kring to cache lines so that there is no false sharing (possibly useful for multiqueue NICs and MSIX interrupts, which are handled by different cores). It's a minor improvement but it does not cost anything.
Reviewed by: Jack Vogel Approved by: Jack Vogel
|
230329 |
19-Jan-2012 |
luigi |
netmap-related changes: 1. correct the initialization of RDT when there is an ixgbe_init() while a netmap client is active. This code was previously in ixgbe_initialize_receive_units() but RDT is overwritten shortly afterwards in ixgbe_init_locked()
2. add code (not active yet) to disable CRCSTRIP while in netmap mode. From all evidence i could gather, it seems that when the 82599 has to write a data block that is not a full cache line, it first reads the line (64 bytes) and then writes back the updated version. This hurts reception of min-sized frames, which are only 60 bytes if the CRC is stripped: i could never get above 11Mpps (received from one queue) with CRCSTRIP enabled, whyle 64+4-byte packets reach 14.2 Mpps (the theoretical maximum). Leaving the CRC in gets us 14.88Mpps for 60+4 byte frames, (and penalizes 64+4). The min-size case is important not just because it looks good in benchmarks, but also because this is the size of pure acks. Note we cannot leave CRCSTRIP on by default because it is incompatible with some other features (LRO etc.)
|
229939 |
10-Jan-2012 |
luigi |
small code cleanup in preparation for future modifications in the memory allocator used by netmap. No functional change, two small bug fixes: - in if_re.c add a missing bus_dmamap_sync() - in netmap.c comment out a spurious free() in an error handling block
|
229767 |
07-Jan-2012 |
kevlo |
ether_ifattach() sets if_mtu to ETHERMTU, don't bother set it again
Reviewed by: yongari
|
228440 |
12-Dec-2011 |
mdf |
Consistently use types in ixgbe driver code:
- {ixgbe,ixv}_header_split is passed to TUNABLE_INT, so delcare it int, not bool. - {ixgbe,ixv}_tx_ctx_setup() returns a boolean value, so declare it bool, not int. - {ixgbe,ixv}_tso_setup() returns a bool, so declare it bool, not boolean_t. - {ixgbe,ixv}_txeof() returns a bool, so declare it bool, not boolean_t. - Do not re-define bool if the symbol already exists.
MFC after: 2 weeks Sponsored by: Isilon Systems, LLC
|
228276 |
05-Dec-2011 |
luigi |
1. Fix the handling of link reset while in netmap more. A link reset now is completely transparent for the netmap client: even if the NIC resets its own ring (e.g. restarting from 0), the client will not see any change in the current rx/tx positions, because the driver will keep track of the offset between the two.
2. make the device-specific code more uniform across different drivers There were some inconsistencies in the implementation of the netmap support routines, now drivers have been aligned to a common code structure.
3. import netmap support for ixgbe . This is implemented as a very small patch for ixgbe.c (233 lines, 11 chunks, mostly comments: in total the patch has only 54 lines of new code) , as most of the code is in an external file sys/dev/netmap/ixgbe_netmap.h , following some initial comments from Jack Vogel about making changes less intrusive. (Note, i have emailed Jack multiple times asking if he had comments on this structure of the code; i got no reply so i assume he is fine with it).
Support for other drivers (em, lem, re, igb) will come later.
"ixgbe" is now the reference driver for netmap support. Both the external file (sys/dev/netmap/ixgbe_netmap.h) and the device-specific patches (in sys/dev/ixgbe/ixgbe.c) are heavily commented and should serve as a reference for other device drivers.
Tested on i386 and amd64 with the pkt-gen program in tools/tools/netmap, the sender does 14.88 Mpps at 1050 Mhz and 14.2 Mpps at 900 MHz on an i7-860 with 4 cores and 82599 card. Haven't tried yet more aggressive optimizations such as adding 'prefetch' instructions in the time-critical parts of the code.
|
225405 |
05-Sep-2011 |
qingli |
The maximum read size of incoming packets is done in 1024-byte increments. The current code was rounding down the maximum frame size instead of routing up, resulting in a read size of 1024 bytes, in the non-jumbo frame case, and splitting the packets across multiple mbufs.
Consequently the above problem exposed another issue, which is when packets were splitted across multiple mbufs, and all of the mbufs in the chain have the M_PKTHDR flag set.
Submitted by: original patch by Ray Ruvinskiy at BlueCoat dot com Reviewed by: jfv, kmacy, rwatson Approved by: re (rwatson) MFC after: 5 days
|
222592 |
02-Jun-2011 |
jfv |
Cut and paste mistake corrected.
|
222588 |
02-Jun-2011 |
jfv |
First off: update the driver README, the old one was horribly crusty, and this still isn't perfect, but its at least a bit more recent.
Secondly, a few improvements to the driver from Andrew Boyer, support hint to allow devices to not attach, add VLAN_HWTSO capability so vlans can use TSO, fix in the interrupt handler to make sure the stack TX queue is processed. Oh, and also make sure IPv6 does not cause a re-init in the ioctl routine. Thanks for your efforts Andrew!
Thanks to Claudio Jeker for noticing the ixgbe_xmit() routine was not correctly swapping the dma map from the first to the last descriptor in a multi-descriptor transmission, corrected this.
|
221189 |
28-Apr-2011 |
jfv |
Add a #define for driver portability to older OS
|
221041 |
25-Apr-2011 |
jfv |
- Add the RX refresh changes from igb to ixgbe - Also a couple minor tweaks to the TX code from the same source. - Add the INET ioctl code which has been missing from this driver, and which caused IP aliases to reset the interface. - Last, some minor logic changes that just reflect upcoming hardware support, but have no other functional effect now.
MFC after a week
|
219902 |
23-Mar-2011 |
jhb |
Do a sweep of the tree replacing calls to pci_find_extcap() with calls to pci_find_cap() instead.
|
217707 |
22-Jan-2011 |
jfv |
Don't bother to run the flowcontrol code if there is no change. Thanks to Andrew for the tweak.
|
217706 |
22-Jan-2011 |
jfv |
Missing case for 82598DA type adapter, thanks Andrew.
|
217705 |
22-Jan-2011 |
jfv |
Leftover bogus TX UNLOCK removed. Thanks to Andrew Boyer.
|
217593 |
19-Jan-2011 |
jfv |
Update driver to version 2.3.8: CRITICAL FIX - with stats changes the older 82598 will panic and trash the stack on driver load, FCOE registers ONLY exist in 82599 and must not be read otherwise.
kern/153951 - to correct incorrect media type on adapters with pluggable modules I have eliminated the old static table in favor of a new dynamic shared code routine. This also has the benefit of detecting changes when a different module is inserted.
Performance/enhancement to the Flow Director code from my linux coworker (the developer of the code).
Fixes from Michael Tuexen - a data corruption problem on the 82599 (CRITICAL), fix so the buf size correctly adjusts as the cluster changes, and max descriptors are set properly. Also added 16K clusters for those REALLY big jumbos :)
In the RX path, the RX LOCK was not being released, and this causes LOR problems. Add the code that igb already has.
Sync with in house shared code, this was necessary for the Flow Director fix.
MFC in 2 days
|
217556 |
18-Jan-2011 |
mdf |
Specify a CTLTYPE_FOO so that a future sysctl(8) change does not need to rely on the format string.
|
217318 |
12-Jan-2011 |
mdf |
sysctl(9) cleanup checkpoint: amd64 GENERIC builds cleanly.
Commit the Intel drivers.
|
217132 |
07-Jan-2011 |
jfv |
CSUM flags need to be OS version sensitive in ixv code
MFC in 3 days
|
217131 |
07-Jan-2011 |
jfv |
kern/150247 - virtualization code also needs fix for 7.X to be buildable...
MFC in 3 days
|
217129 |
07-Jan-2011 |
jfv |
Fix to kern/150247 - make ixgbe buildable for 7.x
|
217127 |
07-Jan-2011 |
jfv |
kern/153772 fix variable names.
Thank you Andrew Boyer for catching these
MFC in 3 days
|
216171 |
04-Dec-2010 |
jfv |
This small little change is a bug that drove me nuts finding. The test to compare the mbuf m_len against a fixed value and then returning needs to be removed.
When using VLANS and doing HW_TAGGING, and IPV6, the ICMP6 packets actually fail this condition, the constant assumes that the tag is IN the frame, and its not, so the length is actually tiny. Furthermore, I'm not sure what the point was to just return??
MFC after: 3 days
|
215924 |
27-Nov-2010 |
jfv |
Interrupt handler, and stats changes from Michael Tuexen, thanks Michael!
|
215914 |
27-Nov-2010 |
jfv |
and the header...
|
215913 |
27-Nov-2010 |
jfv |
A couple fixes got clobbered, putting them back.
|
215911 |
26-Nov-2010 |
jfv |
Update ixgbe driver to verion 2.3.6 - This adds a VM SRIOV interface, ixv, it is however transparent to the user, it links with the ixgbe.ko, but when ixgbe is loaded in a virtualized guest with SRIOV configured this will be detected. - Sync shared code to latest - Many bug fixes and improvements, thanks to everyone who has been using the driver and reporting issues.
|
215034 |
09-Nov-2010 |
brucec |
Fix typos.
PR: bin/148894 Submitted by: olgeni
|
211913 |
28-Aug-2010 |
yongari |
Do not allocate multicast array memory in multicast filter configuration function. For failed memory allocations, em(4)/lem(4) called panic(9) which is not acceptable on production box. igb(4)/ixgb(4)/ix(4) allocated the required memory in stack which consumed 768 bytes of stack memory which looks too big.
To address these issues, allocate multicast array memory in device attach time and make multicast configuration success under any conditions. This change also removes the excessive use of memory in stack.
Reviewed by: jfv
|
211907 |
28-Aug-2010 |
yongari |
Do not call voluntary panic(9) in case of if_alloc() failure.
Reviewed by: jfv
|
209622 |
01-Jul-2010 |
kevlo |
Fix build
|
209609 |
30-Jun-2010 |
jfv |
Left out header change in last delta - new member in adapter so that advertise changes can be done to one port without the other changing.
|
209607 |
30-Jun-2010 |
glebius |
Fix build.
|
209603 |
30-Jun-2010 |
jfv |
BAH, I apologize, the wrong version of the code got fat fingered in place, this is the correct version that actually works... <sheepish grin>
MFC: in a week
|
209602 |
30-Jun-2010 |
jfv |
Add a new sysctl option, this will allow one to limit the advertised speed of an SFP+ to 1G, effectively "forcing" link at that lower speed. It is off by default and is enabled by sysctl dev.ix.0.force_gig=1, 0 will set it back to the norm.
|
209070 |
11-Jun-2010 |
jfv |
Change the mbuf memory calls back to NOWAIT as a problem has been seen in one case with doing the M_WAITOK
|
209060 |
11-Jun-2010 |
jfv |
Remove a disable_queue from the beginning of the interrupt handler, automask handles it. Also, add in msix vector descriptions.
MFC for 8.1 asap
|
208762 |
03-Jun-2010 |
jfv |
Fixes for panic experienced in test at Intel, when doing bidirectional stress traffic on 82598.
Also a couple bug fixes from Michael Tuexen, thank you!!
Add a workaround into the header so that 8 REL can use the driver (adds local copy of ALTQ fix).
MFC: in a few days
|
208282 |
19-May-2010 |
jfv |
A few changes: When not defining header split do not allocate mbufs, this can be a BIG savings in the mbuf memory pool.
Also keep seperate dma maps for the header and payload pieces when doing header split. The basis of this code was a patch done a while ago by yongari, thank you :)
A number of white space changes.
MFC: in a few days
|
208102 |
14-May-2010 |
jfv |
A few minor fixes: - add a moderation value to the Link vector - allow disabling HW RSC on the 82599 if LRO is not enabled. - correct error in the stats code - change optic type on the 82598 DA device
Thanks to Andrew Boyer for the changes.
|
206705 |
16-Apr-2010 |
jfv |
Remove the tx queue selection based on the cpu whe no flowid is present, this was causing some bad reordering, now just use 0.
Also, add a few watchdog bits, and tx handler bits that were corrected in igb.
|
205919 |
30-Mar-2010 |
jfv |
fix my clobber of the copyright date :)
|
205904 |
30-Mar-2010 |
jfv |
Thanks to Michael Tuexen for adding SCTP support for 82599, also for finding a one character bug that kept TSO from working.
Sometimes with direct attach cables a failure can occur in init, the old method of calling detach was broken, there is no way to return an error to the system from init, so I have changed it to return failure thru the ioctl.
And, have fixed the ALTQ code changes of Max Laier, sorry Max :)
|
205720 |
27-Mar-2010 |
jfv |
Update the driver to Intel version 2.1.6 - add some new hardware support for 82599 - Big change to interrupt architecture, it now uses a queue which contains an RX/TX pair as the recipient of the interrupt. This will reduce overall system interrupts/msix usage. - Improved RX mbuf handling: the old get_buf routine is no longer synchronized with rxeof, this allows the elimination of packet discards due to mbuf allocation failure. - Much simplified and improved AIM code, it now happens in the queue interrupt context and takes into account both the traffic on the RX AND TX side. - variety of small tweaks, like ring size, that have been seen as performance improvements. - Thanks to those that provided feedback or suggested changes, I hope I've caught all of them.
|
203834 |
13-Feb-2010 |
mlaier |
Fix drbr and altq interaction: - introduce drbr_needs_enqueue that returns whether the interface/br needs an enqueue operation: returns true if altq is enabled or there are already packets in the ring (as we need to maintain packet order) - update all drbr consumers - fix drbr_flush - avoid using the driver queue (IFQ_DRV_*) in the altq case as the multiqueue consumer does not provide enough protection, serialize altq interaction with the main queue lock - make drbr_dequeue_cond work with altq
Discussed with: kmacy, yongari, jfv MFC after: 4 weeks
|
201758 |
07-Jan-2010 |
mbr |
Remove extraneous semicolons, no functional changes.
Submitted by: Marc Balmer <marc@msys.ch> MFC after: 1 week
|
200239 |
07-Dec-2009 |
jfv |
Update driver to Intel version 2.0.7:
This adds new feature support for the 82599, a hardware assist to LRO, doing this required a large revamp to the RX cleanup code because the descriptor ring may not be processed out of order, this necessitated the elimination of global pointers.
Additionally, the RX routine now does not refresh mbufs on every descriptor, rather it will do a range, and then update the hardware pointer at that time. These are performance oriented changes.
The TX side now has a cleaner simpler watchdog algorithm as well, in TX cleanup a read of ticks is stored, that can then be compared in local_timer to determine if there is a hang.
Various other cleanups along the way, thanks to all who have provided input and testing.
|
198988 |
06-Nov-2009 |
jhb |
Take a step towards removing if_watchdog/if_timer. Don't explicitly set if_watchdog/if_timer to NULL/0 when initializing an ifnet. if_alloc() sets those members to NULL/0 already.
|
197084 |
11-Sep-2009 |
jfv |
Stats missed packet handling was still not quite right, thanks to Dmitrij Tejblum for the correction, need a variable with scope only within the for loop for all queues.
MFC: 3 days
|
196844 |
04-Sep-2009 |
jfv |
If an interface is brought up with no cable it will experience watchdog resets, this is due to a missing check for link in the new multiqueue start code.
MFC: 3 days
|
196798 |
03-Sep-2009 |
jfv |
Stupid cut and paste error on a stats struct member, thanks to Ryan at Small Tree for finding this one.
|
196518 |
24-Aug-2009 |
jfv |
A couple of changes: first, make header split on by default and remove from its dependency on LRO, my tests have shown that its always beneficial, even when doing bridging. Second, fix up a few problems in the statistics code, the adapter dependencies had gotten lost so some code that should only run on 82599 was always running, this resulted in bogus flow control numbers on 82598.
|
195857 |
24-Jul-2009 |
jfv |
Improvement on the last change, this gives a precise way to tell the one and only interface that a vlan event is for. Thanks to John Baldwin for the patch.
Approved by: re
|
195851 |
24-Jul-2009 |
jfv |
This delta fixes two bugs: - When a vlan event occurs a check was not made that the event was actually for the interface, thus resulting in a panic. All three drivers have this vulnerability. Add a check for this condition. - Secondly, there was a duplicate buf_ring free in the em driver resulting in a panic on unload. Remove.
Approved by: re
|
195244 |
01-Jul-2009 |
jfv |
Multiqueue RX is not correctly enabled on the new 82599 adapter, the SRRCTL register needs to be setup per queue.
Approved by: re
|
195049 |
26-Jun-2009 |
rwatson |
Use if_maddr_rlock()/if_maddr_runlock() rather than IF_ADDR_LOCK()/ IF_ADDR_UNLOCK() across network device drivers when accessing the per-interface multicast address list, if_multiaddrs. This will allow us to change the locking strategy without affecting our driver programming interface or binary interface.
For two wireless drivers, remove unnecessary locking, since they don't actually access the multicast address list.
Approved by: re (kib) MFC after: 6 weeks
|
194988 |
25-Jun-2009 |
jfv |
Decided to limit the interrupt bind to multiqueue config as done in igb.
|
194978 |
25-Jun-2009 |
jfv |
Change intr_bind to bus_bind_intr, thanks to John Baldwin for pointing out this simplification.
|
194926 |
24-Jun-2009 |
jfv |
Make CPU bind call architecture specific to satisfy LINT
|
194875 |
24-Jun-2009 |
jfv |
Update for the Intel 10G driver, this adds support for newest hardware, adds multiqueue tx interface, infrastructure cleanup to allow up to 32 MSIX vectors on newer Nehalem systems. Bug fixes, etc.
|
190877 |
10-Apr-2009 |
jfv |
Add missing file, sorry bout that :)
|
190873 |
10-Apr-2009 |
jfv |
Update the ixgbe driver to 1.7.4, this includes support for the new 82599 adapter family, adds header split, and many small fixes. The driver should now be added to the GENERIC kernel.
MFC after: 2 weeks
|
185356 |
27-Nov-2008 |
jfv |
Small nit I just noticed, a pre-decrement should be post.
|
185352 |
26-Nov-2008 |
jfv |
Updated ixgbe driver - version 1.6.2
-This version has header split, and as a result a number of aspects of the code have been improved/simplified. - Interrupt handling refined for performance - Many small bugs fixed along the way
MFC after: ASAP - in time for 7.1
|
181003 |
30-Jul-2008 |
jfv |
This updates the ixgbe driver to Intel internal version 1.4.7 Shared code changes, core driver fixes, vlan event/filter support
Also Kip Macy's fix to allow any number of queues, thanks Kip!
|
179740 |
11-Jun-2008 |
jfv |
Change include to reflect tcp_lro.h move.
|
179739 |
11-Jun-2008 |
jfv |
Remove the tcp_lro.[ch] files as they are now in netinet.
|
179055 |
16-May-2008 |
jfv |
This is driver version 1.4.4 of the Intel ixgbe driver. -It has new hardware support -It uses a new method of TX cleanup called Head Write Back -It includes the provisional generic TCP LRO feature contributed by Myricom and made general purpose by me. This should move into the stack upon approval but for this driver drop its in here. -Also bug fixes and etc...
MFC in a week if no serious issues arise.
|
172043 |
04-Sep-2007 |
jfv |
This is an update to the new Intel 10G 82598 driver. The first drop was Beta, this code is expected to be the release version. Note that this driver code will build in either 6.2 or 7. If you use the code in 6.2 you will not get TSO or MSI/X support but it will function in a legacy mode.
Approved by: re
|
171412 |
12-Jul-2007 |
jfv |
A couple late breaking bugs that testing have turned up. - change include style so build in kernel try OR standalone work. - Limit HWCSUM - I was led to believe that it would work with RSS, but our testing had odd issues which suggests this is false. - A fatfinger error in the ioctl code made ifconfig up not work.
Approved by: re
|
171384 |
11-Jul-2007 |
jfv |
Add the actual source too :)
Approved by: re
|