From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:44940) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UjReI-00024x-W3 for qemu-devel@nongnu.org; Mon, 03 Jun 2013 06:06:01 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UjReF-00063G-H3 for qemu-devel@nongnu.org; Mon, 03 Jun 2013 06:05:58 -0400 Received: from mx1.redhat.com ([209.132.183.28]:21616) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UjReD-00062k-Vf for qemu-devel@nongnu.org; Mon, 03 Jun 2013 06:05:54 -0400 Received: from int-mx11.intmail.prod.int.phx2.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.24]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id r53A5r17017030 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Mon, 3 Jun 2013 06:05:53 -0400 From: Gerd Hoffmann Date: Mon, 3 Jun 2013 12:05:48 +0200 Message-Id: <1370253951-12323-5-git-send-email-kraxel@redhat.com> In-Reply-To: <1370253951-12323-1-git-send-email-kraxel@redhat.com> References: <1370253951-12323-1-git-send-email-kraxel@redhat.com> Subject: [Qemu-devel] [PATCH 4/7] xhci: add XHCISlot->addressed List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Gerd Hoffmann Preparing for live-migration support, post_load will need that. Signed-off-by: Gerd Hoffmann --- hw/usb/hcd-xhci.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/hw/usb/hcd-xhci.c b/hw/usb/hcd-xhci.c index 8813bdf..ac683ce 100644 --- a/hw/usb/hcd-xhci.c +++ b/hw/usb/hcd-xhci.c @@ -405,6 +405,7 @@ struct XHCIEPContext { typedef struct XHCISlot { bool enabled; + bool addressed; dma_addr_t ctx; USBPort *uport; XHCIEPContext * eps[31]; @@ -2041,6 +2042,7 @@ static TRBCCode xhci_disable_slot(XHCIState *xhci, unsigned int slotid) } xhci->slots[slotid-1].enabled = 0; + xhci->slots[slotid-1].addressed = 0; return CC_SUCCESS; } @@ -2167,6 +2169,7 @@ static TRBCCode xhci_address_slot(XHCIState *xhci, unsigned int slotid, xhci_dma_write_u32s(xhci, octx, slot_ctx, sizeof(slot_ctx)); xhci_dma_write_u32s(xhci, octx+32, ep0_ctx, sizeof(ep0_ctx)); + xhci->slots[slotid-1].addressed = 1; return res; } -- 1.7.9.7