From a5da98ef1f85a78d935a8ba048487eb650b7eb07 Mon Sep 17 00:00:00 2001 From: Ian Moffett Date: Wed, 8 Jan 2025 21:58:29 -0500 Subject: kernel: xhci: Ensure command ring is zeroed Signed-off-by: Ian Moffett --- sys/dev/usb/xhci.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'sys') diff --git a/sys/dev/usb/xhci.c b/sys/dev/usb/xhci.c index 0f386cb..ad99f72 100644 --- a/sys/dev/usb/xhci.c +++ b/sys/dev/usb/xhci.c @@ -277,6 +277,8 @@ xhci_alloc_cmdring(struct xhci_hc *hc) size = XHCI_TRB_SIZE * XHCI_CMDRING_LEN; hc->cmdring = dynalloc_memalign(size, 0x1000); + + memset(hc->cmdring, 0, size); __assert(hc->cmdring != NULL); return VIRT_TO_PHYS(hc->cmdring); } -- cgit v1.2.3