Page MenuHomeFreeBSD

e1000: always enable PCSD when RSS hashing is used
ClosedPublic

Authored by kbowling on Aug 11 2021, 7:25 AM.
Tags
None
Referenced Files
F102642112: D31501.id.diff
Fri, Nov 15, 5:51 AM
Unknown Object (File)
Wed, Nov 13, 9:53 AM
Unknown Object (File)
Wed, Nov 13, 6:07 AM
Unknown Object (File)
Wed, Nov 13, 6:07 AM
Unknown Object (File)
Wed, Nov 13, 6:07 AM
Unknown Object (File)
Wed, Nov 13, 5:50 AM
Unknown Object (File)
Mon, Nov 11, 1:45 AM
Unknown Object (File)
Wed, Nov 6, 3:57 PM

Details

Summary

To enable RSS hashing in the NIC, the PCSD bit must be set.

By default, this is never set when RXCSUM is disabled - which
causes problems higher up in the stack.

While here improve the RXCSUM flag assignments when enabling or disabling
IFCAP_RXCSUM.

See also: https://lists.freebsd.org/pipermail/freebsd-current/2020-May/076148.html

Co-authored-by: Stephan de Wit <stephan.dewt@yahoo.co.uk>
Co-authored-by: Franco Fichtner <franco@opnsense.org>

Diff Detail

Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

Taking a look at this.. I suspect the 82574 MQ case will be mishandled let me check the various datasheets.

kbowling edited reviewers, added: franco_opnsense.org; removed: kbowling.

Taking this so I can show you my changes, feel free to re-take after looking

kbowling added a reviewer: markj.
kbowling changed the repository for this revision from rS FreeBSD src repository - subversion to rG FreeBSD src repository.

PCSD is supposed to be set when using RSS features so I moved setting it into there.

I noticed some other issues and tried to clean this up based on your review, let me know what you think.

Here is my datasheet stash: http://iommu.com/datasheets/e1000-datasheets/

The main ones I check are for lem, em, and igb:

I also checked NetBSD's if_wm for this which doesn't directly use the Intel code and is a good cross-reference for errata.

Much nicer, thanks! Added Stephan as reviewer who originally worked on this to give it a go.

One small thing while we edit defines: can E1000_MRQC_ENABLE_RSS_4Q either be removed or defined as E1000_MRQC_ENABLE_RSS_8Q since it's the same value and practically unused?

This revision is now accepted and ready to land.Aug 12 2021, 7:05 AM
franco_opnsense.org retitled this revision from e1000: do not check for multiqueue when setting non-RSS features to e1000: always enable PCSD when RSS hashing is used.Aug 12 2021, 7:14 AM
franco_opnsense.org edited the summary of this revision. (Show Details)
This revision now requires review to proceed.Aug 15 2021, 7:03 PM
This revision is now accepted and ready to land.Aug 16 2021, 6:41 AM