All of lore.kernel.org
 help / color / mirror / Atom feed
From: Hannes Reinecke <hare@suse.de>
To: Paolo Bonzini <pbonzini@redhat.com>
Cc: Johannes Thumshirn <jthumshirn@suse.com>,
	qemu-devel@nongnu.org, Alexander Graf <agraf@suse.com>,
	Hannes Reinecke <hare@suse.de>
Subject: [Qemu-devel] [PATCH 0/3] SCSI ALUA support
Date: Mon, 16 Nov 2015 15:36:55 +0100	[thread overview]
Message-ID: <1447684618-17794-1-git-send-email-hare@suse.de> (raw)

Hi all,

here's a patchset to implement ALUA support for SCSI disks. With it
we can easily simulate a multipath setup:

-drive <drive>,if=none,id=disk1 \
-device scsi-disk,wwn=<wwn>,port_group=1,port_index=1,alua_state=0
-drive <drive>,if=none,id=disk2 \
-device scsi-disk,wwn=<wwn>,port_group=2,port_index=1,alua_state=2

What's a bit annoying is that one has to reference the underlying
block device _twice_, which means one has to stick with the 'raw'
format as anything more elaborate will cause data corruption on the guest
if both paths are active. Also the 'wwn' property is _actually_ a
property of the underlying block device, not the scsi disk.

This patchset implements 'implicit' ALUA mode only for the moment;
full explicit ALUA support involves quite a bit of logic in the qemu
backend.

As usual, comments and reviews are welcome.

Hannes Reinecke (3):
  scsi-disk: Add 'port_group' property
  scsi-disk: Add 'alua_state' property
  scsi-disk: Implement 'REPORT TARGET PORT GROUPS'

 hw/scsi/scsi-bus.c     |  15 ++++
 hw/scsi/scsi-disk.c    | 240 +++++++++++++++++++++++++++++++++++++++++++++++++
 include/block/scsi.h   |  13 +++
 include/hw/scsi/scsi.h |   6 ++
 4 files changed, 274 insertions(+)

-- 
1.8.4.5

             reply	other threads:[~2015-11-16 14:37 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-11-16 14:36 Hannes Reinecke [this message]
2015-11-16 14:36 ` [Qemu-devel] [PATCH 1/3] scsi-disk: Add 'port_group' property Hannes Reinecke
2015-11-16 14:36 ` [Qemu-devel] [PATCH 2/3] scsi-disk: Add 'alua_state' property Hannes Reinecke
2015-11-16 14:36 ` [Qemu-devel] [PATCH 3/3] scsi-disk: Implement 'REPORT TARGET PORT GROUPS' Hannes Reinecke
2015-11-25  7:55   ` Stefan Hajnoczi
2015-11-25  8:55     ` Hannes Reinecke

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=1447684618-17794-1-git-send-email-hare@suse.de \
    --to=hare@suse.de \
    --cc=agraf@suse.com \
    --cc=jthumshirn@suse.com \
    --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.