qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [patch] fix scsi-generic


From: adq
Subject: [Qemu-devel] [patch] fix scsi-generic
Date: Sat, 7 Aug 2010 01:55:16 +0100

Hi, I've been tracking down why scsi generic devices (using SG_IO)
don't work any more. After adding debug, I can see that it actually
submits the scsi CDB in hw/scsi-generic.c/execute_command(), but that
the hw/scsi-generic.c/scsi_read_complete() callback is never called.

This is because these are done with ioctls, and the posix async ioctl
code is, I think, broken right now. Some more debugging, led me to
posix-aio-compat.c/posix_aio_process_queue():

            if (acb->async_context_id != async_context_id) {

The async_context_ids don't match, so the request is never handled.
This is because the acb->async_context_id field is not initialised in
posix-aio-compat.c/paio_ioctl() (compare with
posix-aio-compat.c/paio_submit()). The attached patch adds the missing
line in.

This seems to fix the problem. Of course, /now/ I'm getting other
weird problems (as I'm trying to see if I can get slysoft anydvd
working in a KVM winXP vm), but they need further investigation and
likely other fixes.

Please forgive me if I'm mistaken in this, I've only just started
looking at the qemu code.

Attachment: posix-aio-ioctl-async-context-id.patch
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]