From: Anthony Liguori <anthony@codemonkey.ws>
To: Paolo Bonzini <pbonzini@redhat.com>
Cc: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH 00/16] SCSI sense and target request overhaul
Date: Fri, 12 Aug 2011 08:49:09 -0500 [thread overview]
Message-ID: <4E452F55.3010704@codemonkey.ws> (raw)
In-Reply-To: <1312361359-15445-1-git-send-email-pbonzini@redhat.com>
On 08/03/2011 03:49 AM, Paolo Bonzini wrote:
> This is a pretty important step in the modernization and improvement
> of the SCSI backends, and a prerequisite for pretty much everything
> that is on the table: migration, addressing, improved CD-ROM support,
> hotplug.
Applied all. Thanks.
It fuzzed a bit, it seems pretty trivial to me but wouldn't hurt to
double check. I tested SCSI quite a bit afterwards too.
Regards,
Anthony Liguori
>
> The series touches two main parts:
>
> 1) sense data. Autosense is made a first-class citizen of the
> subsystem. Sense data is communicated to the target primarily
> via autosense, and it is then the target that uses this information
> to reply to REQUEST SENSE commands. In addition, each LUN or
> target can be in a unit attention condition, which will be
> communicated via either autosense or REQUEST SENSE, or cleared
> automatically.
>
> 2) target requests. The common example of this is REPORT LUNS
> and commands sent to invalid LUNs. Handling of these commands
> previously had to be done for every SCSIDevice. This series splits
> request-related SCSIDevice callbacks out into a new SCSIReqOps
> structure, thus allowing the target (SCSIBus) to hijack those requests
> and reply to them without involving the SCSIDevice at all. The
> system is quite flexible, and is also used for invalid commands,
> REQUEST SENSE and commands sent while a unit attention
> condition is pending.
>
> Finally, other parts of the SCSIDevice code are moved to common
> code including general parsing of requests.
>
> The two parts are slightly intertwined. Sense data is handled by patches
> 2/3/4/12/13/14/15, and target requests are handled by patches 5 to 11.
> (patches 1 and 16 are somewhat unrelated). The reason for this is that
> the current device-specific handling of sense data conflicts heavily
> with the goal of handling some commands in a device-independent way.
> So, the series starts by moving sense handling to generic code, and
> comes back to generic handling of REQUEST SENSE and unit attention after
> implementing a few others device-independent requests.
>
> It conflicts somewhat with Markus's tray series, but not in a
> fatal way; the conflicts are trivial.
>
> Paolo Bonzini (16):
> scsi-disk: no need to call scsi_req_data on a short read
> vscsi: always use get_sense
> scsi: pass status when completing
> scsi: move sense handling to generic code
> scsi: introduce SCSIReqOps
> scsi: move request-related callbacks from SCSIDeviceInfo to SCSIReqOps
> scsi: pass cdb already to scsi_req_new
> scsi: introduce SCSICommand
> scsi: push lun field to SCSIDevice
> scsi: move request parsing to common code
> scsi: move handling of REPORT LUNS and invalid LUNs to common code
> scsi: move handling of REQUEST SENSE to common code
> scsi: add a bunch more common sense codes
> scsi: add support for unit attention conditions
> scsi: report unit attention on reset
> scsi: add special traces for common commands
>
> hw/esp.c | 4 +-
> hw/lsi53c895a.c | 4 +-
> hw/scsi-bus.c | 578 +++++++++++++++++++++++++++++++++++++++++++++--------
> hw/scsi-defs.h | 4 +
> hw/scsi-disk.c | 164 +++++-----------
> hw/scsi-generic.c | 156 ++++-----------
> hw/scsi.h | 72 +++++--
> hw/spapr_vscsi.c | 95 ++-------
> hw/usb-msd.c | 4 +-
> trace-events | 5 +
> 10 files changed, 668 insertions(+), 418 deletions(-)
>
next prev parent reply other threads:[~2011-08-12 13:49 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-08-03 8:49 [Qemu-devel] [PATCH 00/16] SCSI sense and target request overhaul Paolo Bonzini
2011-08-03 8:49 ` [Qemu-devel] [PATCH 01/16] scsi-disk: no need to call scsi_req_data on a short read Paolo Bonzini
2011-08-03 16:32 ` Christoph Hellwig
2011-08-04 13:35 ` Stefan Hajnoczi
2011-08-04 13:46 ` Kevin Wolf
2011-08-03 8:49 ` [Qemu-devel] [PATCH 02/16] vscsi: always use get_sense Paolo Bonzini
2011-08-03 16:32 ` Christoph Hellwig
2011-08-03 8:49 ` [Qemu-devel] [PATCH 03/16] scsi: pass status when completing Paolo Bonzini
2011-08-03 16:34 ` Christoph Hellwig
2011-08-03 8:49 ` [Qemu-devel] [PATCH 04/16] scsi: move sense handling to generic code Paolo Bonzini
2011-08-03 16:34 ` Christoph Hellwig
2011-08-03 8:49 ` [Qemu-devel] [PATCH 05/16] scsi: introduce SCSIReqOps Paolo Bonzini
2011-08-03 8:49 ` [Qemu-devel] [PATCH 06/16] scsi: move request-related callbacks from SCSIDeviceInfo to SCSIReqOps Paolo Bonzini
2011-08-03 8:49 ` [Qemu-devel] [PATCH 07/16] scsi: pass cdb already to scsi_req_new Paolo Bonzini
2011-08-03 8:49 ` [Qemu-devel] [PATCH 08/16] scsi: introduce SCSICommand Paolo Bonzini
2011-08-03 8:49 ` [Qemu-devel] [PATCH 09/16] scsi: push lun field to SCSIDevice Paolo Bonzini
2011-08-03 8:49 ` [Qemu-devel] [PATCH 10/16] scsi: move request parsing to common code Paolo Bonzini
2011-08-12 16:12 ` Peter Maydell
2011-08-12 17:05 ` Paolo Bonzini
2011-08-12 16:55 ` Peter Maydell
2011-08-12 17:11 ` Paolo Bonzini
2011-08-03 8:49 ` [Qemu-devel] [PATCH 11/16] scsi: move handling of REPORT LUNS and invalid LUNs " Paolo Bonzini
2011-08-03 8:49 ` [Qemu-devel] [PATCH 12/16] scsi: move handling of REQUEST SENSE " Paolo Bonzini
2011-08-03 8:49 ` [Qemu-devel] [PATCH 13/16] scsi: add a bunch more common sense codes Paolo Bonzini
2011-08-03 8:49 ` [Qemu-devel] [PATCH 14/16] scsi: add support for unit attention conditions Paolo Bonzini
2011-08-03 8:49 ` [Qemu-devel] [PATCH 15/16] scsi: report unit attention on reset Paolo Bonzini
2011-08-03 8:49 ` [Qemu-devel] [PATCH 16/16] scsi: add special traces for common commands Paolo Bonzini
2011-08-12 13:49 ` Anthony Liguori [this message]
2011-08-12 15:48 ` [Qemu-devel] [PATCH 00/16] SCSI sense and target request overhaul Paolo Bonzini
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4E452F55.3010704@codemonkey.ws \
--to=anthony@codemonkey.ws \
--cc=pbonzini@redhat.com \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.