qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
To: Paolo Bonzini <pbonzini@redhat.com>
Cc: Stefan Hajnoczi <stefanha@gmail.com>,
	zwanp@cn.ibm.com, linuxram@us.ibm.com, qemu-devel@nongnu.org,
	virtualization@lists.linux-foundation.org,
	Cong Meng <mc@linux.vnet.ibm.com>
Subject: Re: [Qemu-devel] [PATCH 1/2 v1] blkdrv: Add queue limits parameters for sg block drive
Date: Wed, 22 Aug 2012 14:13:48 +0100	[thread overview]
Message-ID: <20120822131348.GA3512@stefanha-thinkpad.localdomain> (raw)
In-Reply-To: <5034CBF8.3050602@redhat.com>

On Wed, Aug 22, 2012 at 02:09:28PM +0200, Paolo Bonzini wrote:
> Il 22/08/2012 13:04, Cong Meng ha scritto:
> >>
> >> Cong, what is the limit that the host HBA enforces (and what is the
> >> HBA)?  What commands see a problem?  Is it fixed by using scsi-block
> >> instead of scsi-generic (if you can use scsi-block at all, i.e. it's not
> >> a tape or similar device)?
> >>
> > I don't see real problem caused by the the queue limits actually. It's a
> > bug which Stefan told me.
> 
> I'd rather avoid patching the specification if not to solve real (rather
> than known-but-theoretical) problems.

Benjamin Herrenschmidt reported this in problem in 2010:

http://lists.gnu.org/archive/html/qemu-devel/2010-12/msg01741.html

"This is a real problem in practice. IE. the USB CD-ROM on this POWER7
blade limits transfers to 0x1e000 bytes for example and the Linux "sr"
driver on the guest is going to try to give me bigger requests than that
if I don't start limiting them, which will cause all sort of errors."

It cannot be fixed for emulated SCSI HBAs in general but it can for
virtio-scsi.

I/O requests will be failed with EIO if they exceed block queue limits.
Take a look at block/blk-core.c:generic_make_request_checks() and
blk_rq_check_limits().

Cong: Have you checked the block queue limits on your test machine and
exceeded them to see what happens?

Stefan

  reply	other threads:[~2012-08-22 13:14 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-08-21  8:23 [Qemu-devel] [PATCH 1/2 v1] blkdrv: Add queue limits parameters for sg block drive Cong Meng
2012-08-21  8:23 ` [Qemu-devel] [PATCH 2/2 v1] virtio-scsi: set per-LUN queue limits for sg devices Cong Meng
2012-08-21  9:56   ` Stefan Hajnoczi
2012-08-21  8:48 ` [Qemu-devel] [PATCH 1/2 v1] blkdrv: Add queue limits parameters for sg block drive Paolo Bonzini
2012-08-21  9:41   ` Cong Meng
2012-08-21  9:52     ` Stefan Hajnoczi
2012-08-21 10:14       ` Paolo Bonzini
2012-08-22 11:04         ` Cong Meng
2012-08-22 12:09           ` Paolo Bonzini
2012-08-22 13:13             ` Stefan Hajnoczi [this message]
2012-08-22 14:13               ` Paolo Bonzini
2012-08-23  9:31                 ` Cong Meng
2012-08-23 10:03                   ` Paolo Bonzini
2012-08-23 10:08                     ` Stefan Hajnoczi
2012-08-23 10:52                       ` Paolo Bonzini
2012-08-23 12:08                         ` Stefan Hajnoczi
2012-08-24  0:45                       ` Nicholas A. Bellinger
2012-08-24  7:56                         ` Paolo Bonzini
2012-08-24 10:43                           ` Hannes Reinecke
2012-08-24  9:05                             ` Stefan Hajnoczi
2012-08-24  9:14                             ` Paolo Bonzini
2012-08-21  9:49 ` Stefan Hajnoczi
2012-08-21 18:31 ` Blue Swirl
2012-08-22  8:25   ` Stefan Hajnoczi

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=20120822131348.GA3512@stefanha-thinkpad.localdomain \
    --to=stefanha@linux.vnet.ibm.com \
    --cc=linuxram@us.ibm.com \
    --cc=mc@linux.vnet.ibm.com \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=stefanha@gmail.com \
    --cc=virtualization@lists.linux-foundation.org \
    --cc=zwanp@cn.ibm.com \
    /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;
as well as URLs for NNTP newsgroup(s).