aboutsummaryrefslogtreecommitdiff
path: root/sys/dev/qlxge
Commit message (Collapse)AuthorAgeFilesLines
* qlxge: Derive both RSS keys from the common keyKevin Bowling2026-09-181-14/+13
| | | | | | | | | | | | | | Replace the embedded default with rss_getkey(). Preserve the ICB's little-endian representation of each big-endian key word, then copy the initial 16 bytes of the serialized IPv6 key into the IPv4 key. This retains the old default-key bytes and allows a configured common key to take effect. Leave RSS flags and queue mapping unchanged. Reviewed by: gallatin MFC after: 2 weeks Sponsored by: BBOX.io Differential Revision: https://reviews.freebsd.org/D59802
* chore: replace {0, 0} with {DEV,KOBJ}METHOD_ENDEnji Cooper2026-02-251-1/+1
| | | | | | | | | | | | | | Both of the aforementioned macros have been present in FreeBSD for well over a decade: 2009 for `KOBJMETHOD_END`; 2011 for `DEVMETHOD_END`. Adapt all hardcoded references of `{0, 0}` with `DEVMETHOD_END` and `KOBJMETHOD_END` as appropriate. This helps ensure that future adaptations to drivers following patterns documented in driver(9) can be made more easily/without issue. MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D55414
* net: Remove unneeded NULL check for the allocated ifnetZhenlei Huang2024-06-281-4/+0
| | | | | | | | | | | Change 4787572d0580 made if_alloc_domain() never fail, then also do the wrappers if_alloc(), if_alloc_dev(), and if_gethandle(). No functional change intended. Reviewed by: kp, imp, glebius, stevek MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D45740
* qlxge: replace device_printf with QL_DPRINT2Fuqian Huang2024-05-281-12/+12
| | | | | | | | | QL_DPRINT2 checks the debug level first before printing. Replace device_printf with QL_DPRINT2 to check debug level first before printing out the kernel pointers. PR: 238656 MFC after: 1 week
* sys: Remove $FreeBSD$: one-line sh patternWarner Losh2023-08-161-1/+0
| | | | Remove /^\s*#[#!]?\s*\$FreeBSD\$.*$\n/
* sys: Remove $FreeBSD$: one-line .c patternWarner Losh2023-08-166-12/+0
| | | | Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/
* sys: Remove $FreeBSD$: two-line .h patternWarner Losh2023-08-169-18/+0
| | | | Remove /^\s*\*\n \*\s+\$FreeBSD\$$\n/
* spdx: Remove duplicate linesWarner Losh2023-05-121-2/+0
| | | | | | Remove duplicated SPDX lines. Sponsored by: Netflix
* spdx: The BSD-2-Clause-FreeBSD identifier is obsolete, drop -FreeBSDWarner Losh2023-05-1215-16/+16
| | | | | | | | | The SPDX folks have obsoleted the BSD-2-Clause-FreeBSD identifier. Catch up to that fact and revert to their recommended match of BSD-2-Clause. Discussed with: pfg MFC After: 3 days Sponsored by: Netflix
* Mechanically convert qlxge(4) to IfAPIJustin Hibbits2023-03-075-79/+78
| | | | | | Reviewed by: zlei Sponsored by: Juniper Networks, Inc. Differential Revision: https://reviews.freebsd.org/D37819
* qlxge: purge EOL release compatibilityElliott Mitchell2023-02-041-4/+0
| | | | | | | | Drop code ensuring FreeBSD 9 or newer Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/603 Differential Revision: https://reviews.freebsd.org/D35560
* qlnx/qlxgb/qlxgbe/qlxge: Remove unused devclass arguments to DRIVER_MODULE.John Baldwin2022-05-091-3/+1
|
* qlxgb/qlxgbe/qlxge: Fix build without INET and/or without INET6.John Baldwin2022-04-224-5/+35
| | | | This is in preparation for adding these drivers to amd64 NOTES.
* qlxge: Inline the one use of a variable only used in a debug trace.John Baldwin2022-04-211-4/+2
| | | | | | | | | The other QL_DPRINT*() invocations in qls_init_hw_if() all used the expanded form instead of the local variable. The module build always defines QL_DBG in CFLAGS so doesn't trip over this, but adding qlxge to a kernel config builds without QL_DBG. Reported by: olivier
* qlxge: Remove unused variables.John Baldwin2022-04-084-26/+4
|
* qlxge: clean up empty lines in .c and .h filesMateusz Guzik2020-09-0112-165/+26
| | | | Notes: svn path=/head/; revision=365166
* Mark more nodes as CTLFLAG_MPSAFE or CTLFLAG_NEEDGIANT (17 of many)Pawel Biernacki2020-02-262-12/+12
| | | | | | | | | | | | | | | | | | | r357614 added CTLFLAG_NEEDGIANT to make it easier to find nodes that are still not MPSAFE (or already are but aren’t properly marked). Use it in preparation for a general review of all nodes. This is non-functional change that adds annotations to SYSCTL_NODE and SYSCTL_PROC nodes using one of the soon-to-be-required flags. Mark all obvious cases as MPSAFE. All entries that haven't been marked as MPSAFE before are by default marked as NEEDGIANT Approved by: kib (mentor, blanket) Commented by: kib, gallatin, melifaro Differential Revision: https://reviews.freebsd.org/D23718 Notes: svn path=/head/; revision=358333
* qlxge(4): Ditto r357244Conrad Meyer2020-01-291-1/+1
| | | | | | | | Reported by: Coverity CID: 1193716 Notes: svn path=/head/; revision=357245
* Convert to if_foreach_llmaddr() KPI.Gleb Smirnoff2019-10-211-19/+15
| | | | Notes: svn path=/head/; revision=353857
* ifnet: Replace if_addr_lock rwlock with epoch + mutexMatt Macy2018-05-181-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Run on LLNW canaries and tested by pho@ gallatin: Using a 14-core, 28-HTT single socket E5-2697 v3 with a 40GbE MLX5 based ConnectX 4-LX NIC, I see an almost 12% improvement in received packet rate, and a larger improvement in bytes delivered all the way to userspace. When the host receiving 64 streams of netperf -H $DUT -t UDP_STREAM -- -m 1, I see, using nstat -I mce0 1 before the patch: InMpps OMpps InGbs OGbs err TCP Est %CPU syscalls csw irq GBfree 4.98 0.00 4.42 0.00 4235592 33 83.80 4720653 2149771 1235 247.32 4.73 0.00 4.20 0.00 4025260 33 82.99 4724900 2139833 1204 247.32 4.72 0.00 4.20 0.00 4035252 33 82.14 4719162 2132023 1264 247.32 4.71 0.00 4.21 0.00 4073206 33 83.68 4744973 2123317 1347 247.32 4.72 0.00 4.21 0.00 4061118 33 80.82 4713615 2188091 1490 247.32 4.72 0.00 4.21 0.00 4051675 33 85.29 4727399 2109011 1205 247.32 4.73 0.00 4.21 0.00 4039056 33 84.65 4724735 2102603 1053 247.32 After the patch InMpps OMpps InGbs OGbs err TCP Est %CPU syscalls csw irq GBfree 5.43 0.00 4.20 0.00 3313143 33 84.96 5434214 1900162 2656 245.51 5.43 0.00 4.20 0.00 3308527 33 85.24 5439695 1809382 2521 245.51 5.42 0.00 4.19 0.00 3316778 33 87.54 5416028 1805835 2256 245.51 5.42 0.00 4.19 0.00 3317673 33 90.44 5426044 1763056 2332 245.51 5.42 0.00 4.19 0.00 3314839 33 88.11 5435732 1792218 2499 245.52 5.44 0.00 4.19 0.00 3293228 33 91.84 5426301 1668597 2121 245.52 Similarly, netperf reports 230Mb/s before the patch, and 270Mb/s after the patch Reviewed by: gallatin Sponsored by: Limelight Networks Differential Revision: https://reviews.freebsd.org/D15366 Notes: svn path=/head/; revision=333813
* sys/dev: further adoption of SPDX licensing ID tags.Pedro F. Giffuni2017-11-2715-15/+47
| | | | | | | | | | | | | | | Mainly focus on files that use BSD 2-Clause license, however the tool I was using misidentified many licenses so this was mostly a manual - error prone - task. The Software Package Data Exchange (SPDX) group provides a specification to make it easier for automated tools to detect and summarize well known opensource licenses. We are gradually adopting the specification, noting that the tags are considered only advisory and do not, in any way, superceed or replace the license texts. Notes: svn path=/head/; revision=326255
* ql*_def.h: fix QL_ALIGN parenthesizationRyan Libby2017-10-181-1/+1
| | | | | | | | | | | | QL_ALIGN is a set of copies of roundup2, but it was missing an outer set of parentheses, which began to matter with r324538. Now, fully copy the parenthesization of roundup2. Reviewed by: davidcs Differential Revision: https://reviews.freebsd.org/D12673 Notes: svn path=/head/; revision=324728
* Remove register keyword from sys/ and ANSIfy prototypesEd Maste2017-05-171-1/+1
| | | | | | | | | | | | | | | A long long time ago the register keyword told the compiler to store the corresponding variable in a CPU register, but it is not relevant for any compiler used in the FreeBSD world today. ANSIfy related prototypes while here. Reviewed by: cem, jhb Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D10193 Notes: svn path=/head/; revision=318389
* net: Use M_HASHTYPE_OPAQUE_HASH if the mbuf flowid has hash propertiesSepherosa Ziehau2016-06-071-1/+1
| | | | | | | | | Reviewed by: hps, erj, tuexen Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D6688 Notes: svn path=/head/; revision=301538
* sys/dev: minor spelling fixes.Pedro F. Giffuni2016-05-033-4/+4
| | | | | | | Most affect comments, very few have user-visible effects. Notes: svn path=/head/; revision=298955
* tcp/lro: Use tcp_lro_flush_all in device drivers to avoid code duplicationSepherosa Ziehau2016-04-011-6/+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 Notes: svn path=/head/; revision=297482
* CALLOUT_MPSAFE has lost its meaning since r141428, i.e., for more than tenJung-uk Kim2015-05-221-1/+1
| | | | | | | | | | | | | years for head. However, it is continuously misused as the mpsafe argument for callout_init(9). Deprecate the flag and clean up callout_init() calls to make them more consistent. Differential Revision: https://reviews.freebsd.org/D2613 Reviewed by: jhb MFC after: 2 weeks Notes: svn path=/head/; revision=283291
* Start process of removing the use of the deprecated "M_FLOWID" flagHans Petter Selasky2014-12-012-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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 Notes: svn path=/head/; revision=275358
* Mechanically convert to if_inc_counter().Gleb Smirnoff2014-09-191-2/+2
| | | | Notes: svn path=/head/; revision=271849
* Use define from if_var.h to access a field inside struct if_data,Gleb Smirnoff2014-08-301-1/+1
| | | | | | | | | that resides in struct ifnet. Sponsored by: Nginx, Inc. Notes: svn path=/head/; revision=270856
* Unload maps for DMA buffers allocated via bus_dmamem_alloc() beforeJohn Baldwin2014-06-111-0/+1
| | | | | | | | | freeing the buffers. Reviewed by: davidcs Notes: svn path=/head/; revision=267375
* Since 32-bit if_baudrate isn't enough to describe a baud rate of a 10 GbitGleb Smirnoff2014-03-131-7/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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. Notes: svn path=/head/; revision=263102
* Another round of removing historical mbuf(9) allocator flags.Gleb Smirnoff2014-01-161-2/+2
| | | | | | | | | They are breeding! New ones arouse since last round. Sponsored by: Nginx, Inc. Notes: svn path=/head/; revision=260718
* Fix undefined behavior: (1 << 31) is not defined as 1 is an int and thisEitan Adler2013-11-301-1/+1
| | | | | | | | | | | | | | | | shifts into the sign bit. Instead use (1U << 31) which gets the expected result. This fix is not ideal as it assumes a 32 bit int, but does fix the issue for most cases. A similar change was made in OpenBSD. Discussed with: -arch, rdivacky Reviewed by: cperciva Notes: svn path=/head/; revision=258780
* Validate the buffer and its length passed to QLA_MPI_DUMP.David C Somayajulu2013-11-151-5/+8
| | | | | | | | | copyout dump only if qls_mpi_core_dump() is successful. (like to credit x90c for pointing the issue) Submitted by:David C Somayajulu Notes: svn path=/head/; revision=258156
* Include necessary headers that now are available due to pollutionGleb Smirnoff2013-10-281-0/+1
| | | | | | | | | | via if_var.h. Sponsored by: Netflix Sponsored by: Nginx, Inc. Notes: svn path=/head/; revision=257241
* Add Qlogic 10Gb Ethernet Driver for Qlogic 8100 Series CNA AdapterDavid C Somayajulu2013-06-2516-0/+9208
Driver version (v2.0.0) Submitted by: David C Somayajulu (davidcs@freebsd.org) QLogic Corporation Approved by: George Neville-Neil (gnn@freebsd.org) Notes: svn path=/head/; revision=252206