[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 02/14] usb-ehci: add missing usb_packet_init() call
From: |
Gerd Hoffmann |
Subject: |
[Qemu-devel] [PATCH 02/14] usb-ehci: add missing usb_packet_init() call |
Date: |
Tue, 24 Apr 2012 17:51:19 +0200 |
Signed-off-by: Gerd Hoffmann <address@hidden>
---
hw/usb/core.c | 1 +
hw/usb/hcd-ehci.c | 1 +
2 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/hw/usb/core.c b/hw/usb/core.c
index 9a14a53..0e02da7 100644
--- a/hw/usb/core.c
+++ b/hw/usb/core.c
@@ -501,6 +501,7 @@ void usb_packet_set_state(USBPacket *p, USBPacketState
state)
void usb_packet_setup(USBPacket *p, int pid, USBEndpoint *ep)
{
assert(!usb_packet_is_inflight(p));
+ assert(p->iov.iov != NULL);
p->pid = pid;
p->ep = ep;
p->result = 0;
diff --git a/hw/usb/hcd-ehci.c b/hw/usb/hcd-ehci.c
index 10a5b15..c6f21ac 100644
--- a/hw/usb/hcd-ehci.c
+++ b/hw/usb/hcd-ehci.c
@@ -664,6 +664,7 @@ static EHCIQueue *ehci_alloc_queue(EHCIState *ehci, int
async)
q = g_malloc0(sizeof(*q));
q->ehci = ehci;
+ usb_packet_init(&q->packet);
QTAILQ_INSERT_HEAD(head, q, next);
trace_usb_ehci_queue_action(q, "alloc");
return q;
--
1.7.1
- [Qemu-devel] [PULL 00/14] usb patch queue, Gerd Hoffmann, 2012/04/24
- [Qemu-devel] [PATCH 02/14] usb-ehci: add missing usb_packet_init() call,
Gerd Hoffmann <=
- [Qemu-devel] [PATCH 09/14] usb-redir: An interface count of 0 is a valid value, Gerd Hoffmann, 2012/04/24
- [Qemu-devel] [PATCH 05/14] usb-host: don't dereference invalid iovecs, Gerd Hoffmann, 2012/04/24
- [Qemu-devel] [PATCH 06/14] usb-host: fix zero-length packets, Gerd Hoffmann, 2012/04/24
- [Qemu-devel] [PATCH 04/14] usb-storage: fix request canceling, Gerd Hoffmann, 2012/04/24
- [Qemu-devel] [PATCH 03/14] usb-ehci: Ensure frindex writes leave a valid frindex value, Gerd Hoffmann, 2012/04/24
- [Qemu-devel] [PATCH 01/14] usb-ehci: remove hack, Gerd Hoffmann, 2012/04/24
- [Qemu-devel] [PATCH 13/14] usb-uhci: update irq line on reset, Gerd Hoffmann, 2012/04/24
- [Qemu-devel] [PATCH 10/14] usb-redir: Reset device address and speed on disconnect, Gerd Hoffmann, 2012/04/24
- [Qemu-devel] [PATCH 08/14] usb-xhci: fix bit test, Gerd Hoffmann, 2012/04/24
- [Qemu-devel] [PATCH 11/14] usb-redir: Not finding an async urb id is not an error, Gerd Hoffmann, 2012/04/24