All of lore.kernel.org
 help / color / mirror / Atom feed
From: Peter Lieven <pl@dlhnet.de>
To: "qemu-devel@nongnu.org" <qemu-devel@nongnu.org>
Cc: Kevin Wolf <kwolf@redhat.com>,
	Paolo Bonzini <pbonzini@redhat.com>, Jeff Cody <jcody@redhat.com>,
	Anthony Liguori <anthony@codemonkey.ws>
Subject: [Qemu-devel] [PATCH 1/3] Revert "block: complete all IOs before .bdrv_truncate"
Date: Mon, 11 Mar 2013 11:03:28 +0100	[thread overview]
Message-ID: <513DABF0.7010906@dlhnet.de> (raw)

brdv_truncate() is also called from readv/writev commands on self-
growing file based storage. this will result in requests waiting
for theirselves to complete.

This reverts commit 9a665b2b8640e464f0a778216fc2dca8d02acf33.
---
  block.c |    4 ----
  1 file changed, 4 deletions(-)

diff --git a/block.c b/block.c
index 124a9eb..60c246a 100644
--- a/block.c
+++ b/block.c
@@ -2449,10 +2449,6 @@ int bdrv_truncate(BlockDriverState *bs, int64_t offset)
          return -EACCES;
      if (bdrv_in_use(bs))
          return -EBUSY;
-
-    /* There better not be any in-flight IOs when we truncate the device. */
-    bdrv_drain_all();
-
      ret = drv->bdrv_truncate(bs, offset);
      if (ret == 0) {
          ret = refresh_total_sectors(bs, offset >> BDRV_SECTOR_BITS);
-- 
1.7.9.5

             reply	other threads:[~2013-03-11 10:03 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-11 10:03 Peter Lieven [this message]
2013-03-19 13:10 ` [Qemu-devel] [PATCH 1/3] Revert "block: complete all IOs before .bdrv_truncate" Kevin Wolf

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=513DABF0.7010906@dlhnet.de \
    --to=pl@dlhnet.de \
    --cc=anthony@codemonkey.ws \
    --cc=jcody@redhat.com \
    --cc=kwolf@redhat.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.