From 9af99d980e9ff6270f291b11a064087b33dd3ab8 Mon Sep 17 00:00:00 2001 From: Gerd Hoffmann Date: Thu, 26 Nov 2009 15:33:49 +0100 Subject: scsi: move request lists to QTAILQ. Changes: * Move from open-coded lists to QTAILQ macros. * Move the struct elements to the common data structures (SCSIDevice + SCSIRequest). * Drop free request pools. * Fix request cleanup in the destroy callback. Signed-off-by: Gerd Hoffmann Signed-off-by: Anthony Liguori --- hw/scsi-bus.c | 1 + 1 file changed, 1 insertion(+) (limited to 'hw/scsi-bus.c') diff --git a/hw/scsi-bus.c b/hw/scsi-bus.c index 641db81..801922b 100644 --- a/hw/scsi-bus.c +++ b/hw/scsi-bus.c @@ -50,6 +50,7 @@ static int scsi_qdev_init(DeviceState *qdev, DeviceInfo *base) bus->devs[dev->id] = dev; dev->info = info; + QTAILQ_INIT(&dev->requests); rc = dev->info->init(dev); if (rc != 0) { bus->devs[dev->id] = NULL; -- cgit v1.1