From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:60029) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YNQFS-00011L-R0 for qemu-devel@nongnu.org; Mon, 16 Feb 2015 13:18:23 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YNQFR-0001MX-Vm for qemu-devel@nongnu.org; Mon, 16 Feb 2015 13:18:22 -0500 Received: from mail-wg0-x231.google.com ([2a00:1450:400c:c00::231]:49121) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YNQFR-0001MP-Q3 for qemu-devel@nongnu.org; Mon, 16 Feb 2015 13:18:21 -0500 Received: by mail-wg0-f49.google.com with SMTP id l18so30931322wgh.8 for ; Mon, 16 Feb 2015 10:18:21 -0800 (PST) Sender: Paolo Bonzini From: Paolo Bonzini Date: Mon, 16 Feb 2015 19:17:47 +0100 Message-Id: <1424110682-14334-7-git-send-email-pbonzini@redhat.com> In-Reply-To: <1424110682-14334-1-git-send-email-pbonzini@redhat.com> References: <1424110682-14334-1-git-send-email-pbonzini@redhat.com> Subject: [Qemu-devel] [PULL 06/21] vhost-scsi: set the bootable value of channel/target/lun List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Gonglei , Bo Su From: Gonglei At present, the target is valued boot_tpgt, In addition, channel and lun both are 0 for bootable vhost-scsi device. Signed-off-by: Gonglei Signed-off-by: Bo Su Acked-by: Michael S. Tsirkin Signed-off-by: Paolo Bonzini --- hw/scsi/vhost-scsi.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/hw/scsi/vhost-scsi.c b/hw/scsi/vhost-scsi.c index dc9076e..e30ff84 100644 --- a/hw/scsi/vhost-scsi.c +++ b/hw/scsi/vhost-scsi.c @@ -251,6 +251,12 @@ static void vhost_scsi_realize(DeviceState *dev, Error **errp) return; } + /* At present, channel and lun both are 0 for bootable vhost-scsi disk */ + s->channel = 0; + s->lun = 0; + /* Note: we can also get the minimum tpgt from kernel */ + s->target = vs->conf.boot_tpgt; + error_setg(&s->migration_blocker, "vhost-scsi does not support migration"); migrate_add_blocker(s->migration_blocker); -- 2.3.0