qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Wenchao Xia <xiawenc@linux.vnet.ibm.com>
To: qemu-devel@nongnu.org
Cc: kwolf@redhat.com, pbonzini@redhat.com,
	Wenchao Xia <xiawenc@linux.vnet.ibm.com>,
	stefanha@redhat.com
Subject: [Qemu-devel] [RFC PATCH 3/3] block: add parameter bds queue in bdrv_invalidate_cache_all()
Date: Tue, 27 Aug 2013 15:49:25 +0800	[thread overview]
Message-ID: <1377589765-30215-4-git-send-email-xiawenc@linux.vnet.ibm.com> (raw)
In-Reply-To: <1377589765-30215-1-git-send-email-xiawenc@linux.vnet.ibm.com>

Signed-off-by: Wenchao Xia <xiawenc@linux.vnet.ibm.com>
---
 block.c               |    4 ++--
 include/block/block.h |    2 +-
 migration.c           |    2 +-
 3 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/block.c b/block.c
index bf35b90..e4dd84e 100644
--- a/block.c
+++ b/block.c
@@ -4175,11 +4175,11 @@ void bdrv_invalidate_cache(BlockDriverState *bs)
     }
 }
 
-void bdrv_invalidate_cache_all(void)
+void bdrv_invalidate_cache_all(BlockDrvierStateQueue *q)
 {
     BlockDriverState *bs;
 
-    QTAILQ_FOREACH(bs, &bdrv_states, list) {
+    QTAILQ_FOREACH(bs, q, list) {
         bdrv_invalidate_cache(bs);
     }
 }
diff --git a/include/block/block.h b/include/block/block.h
index 323a732..3762fe1 100644
--- a/include/block/block.h
+++ b/include/block/block.h
@@ -267,7 +267,7 @@ BlockDriverAIOCB *bdrv_aio_ioctl(BlockDriverState *bs,
 
 /* Invalidate any cached metadata used by image formats */
 void bdrv_invalidate_cache(BlockDriverState *bs);
-void bdrv_invalidate_cache_all(void);
+void bdrv_invalidate_cache_all(BlockDrvierStateQueue *q);
 
 void bdrv_clear_incoming_migration_all(void);
 
diff --git a/migration.c b/migration.c
index 200d404..3153f20 100644
--- a/migration.c
+++ b/migration.c
@@ -113,7 +113,7 @@ static void process_incoming_migration_co(void *opaque)
 
     bdrv_clear_incoming_migration_all();
     /* Make sure all file formats flush their mutable metadata */
-    bdrv_invalidate_cache_all();
+    bdrv_invalidate_cache_all(qemu_get_bds_queue());
 
     if (autostart) {
         vm_start();
-- 
1.7.1

  parent reply	other threads:[~2013-08-27  7:52 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-08-27  7:49 [Qemu-devel] [RFC PATCH 0/3] move global bdrv_states out of block.c Wenchao Xia
2013-08-27  7:49 ` [Qemu-devel] [RFC PATCH 1/3] block: add typedef for BlockDriverState queue Wenchao Xia
2013-08-27  7:49 ` [Qemu-devel] [RFC PATCH 2/3] block: add function qemu_get_bds_queue Wenchao Xia
2013-08-27  7:49 ` Wenchao Xia [this message]
2013-09-18 14:03 ` [Qemu-devel] [RFC PATCH 0/3] move global bdrv_states out of block.c Stefan Hajnoczi
2013-09-20  6:24   ` Wenchao Xia

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=1377589765-30215-4-git-send-email-xiawenc@linux.vnet.ibm.com \
    --to=xiawenc@linux.vnet.ibm.com \
    --cc=kwolf@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=stefanha@redhat.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).