Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

e1000: Sync DPDK ich8lan #539

Closed
wants to merge 1 commit into from
Closed

Conversation

kev009
Copy link
Member

@kev009 kev009 commented Sep 17, 2021

This contains a probable regression for suspend/resume and other issues on I219, break it out so users can help test.

Also of note, I left out two changes to the FreeBSD driver to try and opportunistically use ULP https://cgit.freebsd.org/src/diff/sys/dev/e1000/if_em.c?id=a4378873e9ce1b35b55378c21f8eae69e58c2525

@ricera

@kev009 kev009 mentioned this pull request Sep 17, 2021
@kev009
Copy link
Member Author

kev009 commented Sep 22, 2021

@ricera is there any way to get guidance from intel on this file? The datasheets for the client parts are not very enlightening and it's hard to tell whether FreeBSD or OOT or DPDK is authoritative WRT clients.

@ricera
Copy link
Contributor

ricera commented Sep 22, 2021

@ricera is there any way to get guidance from intel on this file? The datasheets for the client parts are not very enlightening and it's hard to tell whether FreeBSD or OOT or DPDK is authoritative WRT clients.

Basically not from within because of its age; but have you looked for the "software developers manuals" instead for those parts? In the past, that contained the stuff that was interesting to drivers, and that stuff wasn't included in the datasheets. Here's one for some old parts, but I don't know exactly what's in ich8lan: https://www.intel.com/content/dam/www/public/us/en/documents/manuals/pcie-gbe-controllers-open-source-manual.pdf

@ricera
Copy link
Contributor

ricera commented Sep 22, 2021

For ICH8/9/10, it looks like you'd need "Intel® ICH 8/9/10 and 82566/82567/82562V: Developers Manual", but I can't get a link to it atm

@kev009
Copy link
Member Author

kev009 commented Sep 22, 2021

For ICH8/9/10, it looks like you'd need "Intel® ICH 8/9/10 and 82566/82567/82562V: Developers Manual", but I can't get a link to it atm

The problem in particular is with I218/I219 ULP there isn't really documentation on this stuff. I can't tell if the FreeBSD or DPDK code is newer in e1000_enable_ulp_lpt_lp().

@ricera
Copy link
Contributor

ricera commented Sep 22, 2021

For ICH8/9/10, it looks like you'd need "Intel® ICH 8/9/10 and 82566/82567/82562V: Developers Manual", but I can't get a link to it atm

The problem in particular is with I218/I219 ULP there isn't really documentation on this stuff. I can't tell if the FreeBSD or DPDK code is newer in e1000_enable_ulp_lpt_lp().

I would assume the DPDK version is newer, and I also think we might have excluded ULP stuff in the FreeBSD driver.

@kev009
Copy link
Member Author

kev009 commented Sep 22, 2021

I was able to find it on archive.org http://web.archive.org/web/20170226164709/https://www.intel.com/content/dam/doc/manual/i-o-controller-hub-8-9-10-82566-82567-82562v-software-dev-manual.pdf

This will be useful but doesn't seem to cover the LPT+ chipsets.

@ricera
Copy link
Contributor

ricera commented Sep 22, 2021

Ok, I compared the freebsd in-kernel version with the DPDK and internal versions of the file, and it definitely looks like the DPDK version matches the internal one more closely; it's probably the more definitive file to use.

As for I219-ish documentation, that might be when Intel stopped publishing external software documentation for them, I dunno. I have an internal one, but I haven't found any external-facing one yet.

@kev009 kev009 force-pushed the e1000-DPDK-ich8lan branch 2 times, most recently from b9c5032 to 65d2de1 Compare September 23, 2021 19:52
@@ -1093,9 +1093,6 @@ em_if_attach_pre(if_ctx_t ctx)
}
}

/* Disable ULP support */
e1000_disable_ulp_lpt_lp(hw, true);
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is redundant, it is called in ich8lan setup via e1000_setup_init_funcs() above.

@kev009
Copy link
Member Author

kev009 commented Sep 23, 2021

I've got this working on I219 now with https://reviews.freebsd.org/D32087 (!)

@kev009 kev009 marked this pull request as ready for review September 23, 2021 21:15
@kev009
Copy link
Member Author

kev009 commented Sep 27, 2021

@ricera I feel like I still don't have enough information to make any decisions on the majority of the changes

In particular, this changeset results in:

  • a hardware initialization failure message when booting I219 (2) without a cable/link (seems otherwise benign)
  • When AMT is enabled on the system firmware, the link flaps regularly. This does not happen without this changeset.

The LSC to CSC change is interesting, Linux and any intel.com Linux and BSD drivers seem to not carry it.

@kev009
Copy link
Member Author

kev009 commented Sep 29, 2021

Tempted to close this based on my own and additional user testing, the code in main empirically works better. @ricera I am attempting to get "privileged access" with Intel, hopefully that will allow me to learn the details of I21x ULP

@kev009
Copy link
Member Author

kev009 commented Oct 2, 2021

After much trial and error the link flaps appear to be related to a particular old cable. Will need to trace through the shared code to see what is causing the hw init failure message.

@bsdimp
Copy link
Member

bsdimp commented Feb 4, 2023

This branch looks like it may no longer be relevant. Is it still active? Or can it be closed?

kev009 added a commit to kev009/freebsd that referenced this pull request Feb 9, 2023
This contains a possible regression for suspend/resume, break it out
so users can help test.

Obtained from:	DPDK
MFC after:	2 weeks
Pull Request:	freebsd#539
kev009 added a commit to kev009/freebsd that referenced this pull request Feb 9, 2023
This contains a possible regression for suspend/resume, break it out
so users can help test.

Obtained from:	DPDK
MFC after:	2 weeks
Pull Request:	freebsd#539
kev009 added a commit to kev009/freebsd that referenced this pull request Feb 9, 2023
This contains a possible regression for suspend/resume, break it out
so users can help test.

Obtained from:	DPDK
MFC after:	2 weeks
Pull Request:	freebsd#539
kev009 added a commit to kev009/freebsd that referenced this pull request Feb 9, 2023
This contains a possible regression for suspend/resume, break it out
so users can help test.

Obtained from:	DPDK
MFC after:	2 weeks
Pull Request:	freebsd#539
This contains a possible regression for suspend/resume, break it out
so users can help test.

Obtained from:	DPDK
MFC after:	2 weeks
Pull Request:	freebsd#539
@kev009
Copy link
Member Author

kev009 commented Feb 9, 2023

Committed relevant parts as d36fbdb

@kev009 kev009 closed this Feb 9, 2023
@kev009 kev009 deleted the e1000-DPDK-ich8lan branch February 9, 2023 00:32
freebsd-git pushed a commit that referenced this pull request Feb 9, 2023
This call only makes sense for ich8lan, and the shared code does it in
e1000_setup_init_funcs() above this deletion.

Obtained from:	DPDK
MFC after:	2 weeks
Sponsored by:	BBOX.io
Pull Request:	#539
hardenedbsd-services pushed a commit to HardenedBSD/hardenedBSD that referenced this pull request Feb 10, 2023
freebsd-git pushed a commit that referenced this pull request Feb 23, 2023
This call only makes sense for ich8lan, and the shared code does it in
e1000_setup_init_funcs() above this deletion.

Obtained from:	DPDK
Sponsored by:	BBOX.io
Pull Request:	#539

(cherry picked from commit d36fbdb)
freebsd-git pushed a commit that referenced this pull request Feb 23, 2023
This call only makes sense for ich8lan, and the shared code does it in
e1000_setup_init_funcs() above this deletion.

Obtained from:	DPDK
Sponsored by:	BBOX.io
Pull Request:	#539

(cherry picked from commit d36fbdb)
bsdjhb pushed a commit to bsdjhb/cheribsd that referenced this pull request Mar 22, 2023
This call only makes sense for ich8lan, and the shared code does it in
e1000_setup_init_funcs() above this deletion.

Obtained from:	DPDK
MFC after:	2 weeks
Sponsored by:	BBOX.io
Pull Request:	freebsd/freebsd-src#539
fichtner pushed a commit to opnsense/src that referenced this pull request May 9, 2023
This call only makes sense for ich8lan, and the shared code does it in
e1000_setup_init_funcs() above this deletion.

Obtained from:	DPDK
Sponsored by:	BBOX.io
Pull Request:	freebsd/freebsd-src#539

(cherry picked from commit d36fbdb)
@emaste emaste added the merged label Jun 12, 2023
laffer1 pushed a commit to MidnightBSD/src that referenced this pull request Jun 27, 2023
This call only makes sense for ich8lan, and the shared code does it in
e1000_setup_init_funcs() above this deletion.

Obtained from:	DPDK
Sponsored by:	BBOX.io
Pull Request:	freebsd/freebsd-src#539

(cherry picked from commit d36fbdb08ff567393a698aaf16f726275901ec96)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
4 participants