]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
xhci(4): Ensure the so-called data toggle gets properly reset.
authorHans Petter Selasky <hselasky@FreeBSD.org>
Thu, 21 Apr 2022 14:59:09 +0000 (16:59 +0200)
committerHans Petter Selasky <hselasky@FreeBSD.org>
Thu, 21 Apr 2022 15:01:13 +0000 (17:01 +0200)
commitcda31e734925346328fd2369585ab3f6767ec225
treec8fe05f2ff62a9c5754b111d9804f26ed717e9c3
parente87ec409fa9b21abf79895837fe375ab3d7e408a
xhci(4): Ensure the so-called data toggle gets properly reset.

Use the drop and enable endpoint context commands to force a reset of
the data toggle for USB 2.0 and USB 3.0 after:
 - clear endpoint halt command (when the driver wishes).
 - set config command (when the kernel or user-space wants).
 - set alternate setting command (only affected endpoints).

Some XHCI HW implementations may not allow the endpoint reset command when
the endpoint context is not in the halted state.

Reported by: Juniper and Gary Jennejohn
MFC after: 1 week
Sponsored by: NVIDIA Networking
sys/dev/usb/controller/xhci.c