mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: James Bottomley <James.Bottomley@HansenPartnership.com>
To: "K. Y. Srinivasan" <kys@microsoft.com>
Cc: gregkh@suse.de, linux-kernel@vger.kernel.org,
	devel@linuxdriverproject.org, virtualization@lists.osdl.org,
	linux-scsi@vger.kernel.org, ohering@suse.com, hch@infradead.org
Subject: Re: [PATCH 1/1] Staging: hv: storvsc: Move the storage driver out of the staging area
Date: Thu, 17 Nov 2011 12:26:33 -0600	[thread overview]
Message-ID: <1321554393.3041.77.camel@dabdike.int.hansenpartnership.com> (raw)
In-Reply-To: <1320776028-29568-1-git-send-email-kys@microsoft.com>

On Tue, 2011-11-08 at 10:13 -0800, K. Y. Srinivasan wrote:
> The storage driver (storvsc_drv.c) handles all block storage devices
> assigned to Linux guests hosted on Hyper-V. This driver has been in the
> staging tree for a while and this patch moves it out of the staging area.
> As per Greg's recommendation, this patch makes no changes to the staging/hv
> directory. Once the driver moves out of staging, we will cleanup the
> staging/hv directory.
> 
> This patch includes all the patches that I have sent against the staging/hv
> tree to address the comments I have gotten to date on this storage driver.

First comment is that it would have been easier to see the individual
patches for comment before you committed them.

The way you did mempool isn't entirely right: the problem is that to
prevent a memory to I/O deadlock we need to ensure forward progress on
the drain device.  Just having 64 commands available to the host doesn't
necessarily achieve this because LUN1 could consume them all and starve
LUN0 which is the drain device leading to the deadlock, so the mempool
really needs to be per device using slave_alloc.

+static int storvsc_device_alloc(struct scsi_device *sdevice)
+{
+	/*
+	 * This enables luns to be located sparsely. Otherwise, we may not
+	 * discovered them.
+	 */
+	sdevice->sdev_bflags |= BLIST_SPARSELUN | BLIST_LARGELUN;
+	return 0;
+}

Looks bogus ... this should happen automatically for SCSI-3 devices ...
unless your hypervisor has some strange (and wrong) identification?  I
really think you want to use SCSI-3 because it will do report LUN
scanning, which consumes far fewer resources.

I still think you need to disable clustering and junk the bvec merge
function.  Your object seems to be to accumulate in page size multiples
(and not aggregate over this) ... that's what clustering is designed to
do.

James



  reply	other threads:[~2011-11-17 18:26 UTC|newest]

Thread overview: 45+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-11-08 18:13 K. Y. Srinivasan
2011-11-17 18:26 ` James Bottomley [this message]
2011-11-18  4:53   ` KY Srinivasan
2011-11-18 17:00     ` James Bottomley
2011-11-18 23:28       ` KY Srinivasan
2011-11-30 13:46   ` KY Srinivasan
2011-12-01 13:43 K. Y. Srinivasan
2011-12-07 16:16 K. Y. Srinivasan
2011-12-08 10:37 ` Rolf Eike Beer
2012-01-12 21:15 K. Y. Srinivasan
2012-01-14 16:42 ` Christoph Hellwig
2012-01-14 20:31   ` KY Srinivasan
2012-01-16 15:29     ` Christoph Hellwig
2012-01-16 22:47       ` KY Srinivasan
2012-01-16 22:55       ` KY Srinivasan
2012-01-25 15:29       ` KY Srinivasan
2012-01-25 15:43         ` Christoph Hellwig
2012-01-25 15:51           ` Greg KH
2012-01-25 15:59             ` James Bottomley
2012-01-25 17:03               ` Greg KH
2012-01-25 17:12                 ` James Bottomley
2012-01-25 17:13                   ` KY Srinivasan
2012-01-25 19:22                   ` KY Srinivasan
2012-01-25 21:13                     ` KY Srinivasan
2012-01-26 14:11                   ` KY Srinivasan
2012-01-25 18:29 K. Y. Srinivasan
2012-01-26 16:07 ` James Bottomley
2012-01-26 17:17 ` Rolf Eike Beer
2012-01-26 17:24   ` KY Srinivasan
2012-02-09 20:04 K. Y. Srinivasan
2012-02-09 20:04 ` Greg KH
2012-02-09 20:18   ` James Bottomley
2012-02-09 20:21     ` KY Srinivasan
2012-02-09 20:40       ` James Bottomley
2012-02-09 20:24     ` Greg KH
2012-02-09 20:43       ` KY Srinivasan
2012-02-09 20:45         ` James Bottomley
2012-02-09 20:51           ` KY Srinivasan
2012-02-09 22:13           ` KY Srinivasan
2012-02-10 11:12           ` KY Srinivasan
2012-02-09 22:14 K. Y. Srinivasan
2012-02-10 18:02 ` Greg KH
2012-02-13 18:59   ` KY Srinivasan
2012-02-13 19:28   ` James Bottomley
2012-02-13 19:31     ` KY Srinivasan

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=1321554393.3041.77.camel@dabdike.int.hansenpartnership.com \
    --to=james.bottomley@hansenpartnership.com \
    --cc=devel@linuxdriverproject.org \
    --cc=gregkh@suse.de \
    --cc=hch@infradead.org \
    --cc=kys@microsoft.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=ohering@suse.com \
    --cc=virtualization@lists.osdl.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®