Patchwork [18/35] migration: Inline qemu_fopen_ops_buffered into migrate_fd_connect

login
register
mail settings
Submitter Juan Quintela
Date Dec. 11, 2012, 12:46 p.m.
Message ID <1355230031-28233-19-git-send-email-quintela@redhat.com>
Download mbox | patch
Permalink /patch/205213/
State New
Headers show

Comments

Juan Quintela - Dec. 11, 2012, 12:46 p.m.
Signed-off-by: Juan Quintela <quintela@redhat.com>
---
 migration.c | 9 ++-------
 migration.h | 2 --
 2 files changed, 2 insertions(+), 9 deletions(-)

Patch

diff --git a/migration.c b/migration.c
index 34ba6ab..371ff0c 100644
--- a/migration.c
+++ b/migration.c
@@ -366,12 +366,6 @@  bool migration_has_failed(MigrationState *s)
             s->state == MIG_STATE_ERROR);
 }

-void migrate_fd_connect(MigrationState *s)
-{
-    s->state = MIG_STATE_ACTIVE;
-    qemu_fopen_ops_buffered(s);
-}
-
 static MigrationState *migrate_init(const MigrationParams *params)
 {
     MigrationState *s = migrate_get_current();
@@ -801,10 +795,11 @@  static const QEMUFileOps buffered_file_ops = {
     .set_rate_limit = buffered_set_rate_limit,
 };

-void qemu_fopen_ops_buffered(MigrationState *migration_state)
+void migrate_fd_connect(MigrationState *migration_state)
 {
     QEMUFileBuffered *s;

+    migration_state->state = MIG_STATE_ACTIVE;
     s = g_malloc0(sizeof(*s));

     s->migration_state = migration_state;
diff --git a/migration.h b/migration.h
index e95d37a..63da641 100644
--- a/migration.h
+++ b/migration.h
@@ -126,6 +126,4 @@  int migrate_use_xbzrle(void);
 int64_t migrate_xbzrle_cache_size(void);

 int64_t xbzrle_cache_resize(int64_t new_size);
-
-void qemu_fopen_ops_buffered(MigrationState *migration_state);
 #endif