提交 8f36ec70 编写于 作者: G Gerd Hoffmann

xhci: fix guest-triggerable assert

Set xhci into error state instead of throwing a core dump.
Signed-off-by: NGerd Hoffmann <kraxel@redhat.com>
Message-id: 20180702162752.29233-1-kraxel@redhat.com
上级 8bb01b25
......@@ -1954,7 +1954,12 @@ static void xhci_kick_epctx(XHCIEPContext *epctx, unsigned int streamid)
for (i = 0; i < length; i++) {
TRBType type;
type = xhci_ring_fetch(xhci, ring, &xfer->trbs[i], NULL);
assert(type);
if (!type) {
xhci_die(xhci);
xhci_ep_free_xfer(xfer);
epctx->kick_active--;
return;
}
}
xfer->streamid = streamid;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册