Re: [Qemu-devel] [PATCH] scsi-generic: Remove bogus double complete

2011-05-03 Thread Paolo Bonzini
On 04/05/2011 04:00 PM, Kevin Wolf wrote: I have a hard time each time I try to understand this SCSI stuff without reading a lot of code and specs. What I would have expected is this: if (len == 0) { scsi_command_complete(r, 0); } else { r->req.bus->complete(r->req.bus, SCSI_REASON_DAT

Re: [Qemu-devel] [PATCH] scsi-generic: Remove bogus double complete

2011-04-05 Thread Kevin Wolf
Am 05.04.2011 07:07, schrieb David Gibson: > From: Ben Herrenschmidt > > scsi-generic scsi_read_complete() should not -both- call the client > complete callback with SCSI_REASON_DATA -and- call > scsi_command_complete(). The former will cause the client to queue a > new read or write request, wh

[Qemu-devel] [PATCH] scsi-generic: Remove bogus double complete

2011-04-04 Thread David Gibson
From: Ben Herrenschmidt scsi-generic scsi_read_complete() should not -both- call the client complete callback with SCSI_REASON_DATA -and- call scsi_command_complete(). The former will cause the client to queue a new read or write request, while the later will free the request data structure, thu