Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F156956816
D27174.id79460.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
981 B
Referenced Files
None
Subscribers
None
D27174.id79460.diff
View Options
Index: head/sys/dev/usb/controller/xhci.c
===================================================================
--- head/sys/dev/usb/controller/xhci.c
+++ head/sys/dev/usb/controller/xhci.c
@@ -4020,6 +4020,9 @@
struct usb_endpoint *ep)
{
struct xhci_endpoint_ext *pepext;
+ struct xhci_softc *sc;
+ uint8_t index;
+ uint8_t epno;
DPRINTFN(2, "endpoint=%p, addr=%d, endpt=%d, mode=%d\n",
ep, udev->address, edesc->bEndpointAddress, udev->flags.usb_mode);
@@ -4036,6 +4039,18 @@
USB_BUS_LOCK(udev->bus);
pepext->trb_halted = 1;
pepext->trb_running = 0;
+
+ /*
+ * When doing an alternate setting, except for control
+ * endpoints, we need to re-configure the XHCI endpoint
+ * context:
+ */
+ if ((edesc->bEndpointAddress & UE_ADDR) != 0) {
+ sc = XHCI_BUS2SC(udev->bus);
+ index = udev->controller_slot_id;
+ epno = XHCI_EPNO2EPID(edesc->bEndpointAddress);
+ sc->sc_hw.devs[index].ep_configured &= ~(1U << epno);
+ }
USB_BUS_UNLOCK(udev->bus);
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Mon, May 18, 3:33 PM (11 h, 29 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
33218224
Default Alt Text
D27174.id79460.diff (981 B)
Attached To
Mode
D27174: Allow user to configure endpoints twice
Attached
Detach File
Event Timeline
Log In to Comment