[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH v2 19/41] savevm/QEMUFile: drop qemu_stdio_fd
From: |
Isaku Yamahata |
Subject: |
[Qemu-devel] [PATCH v2 19/41] savevm/QEMUFile: drop qemu_stdio_fd |
Date: |
Mon, 4 Jun 2012 18:57:21 +0900 |
Now qemu_file_fd() replaces qemu_stdio_fd().
Signed-off-by: Isaku Yamahata <address@hidden>
---
migration-exec.c | 4 ++--
migration-fd.c | 2 +-
qemu-file.h | 1 -
savevm.c | 12 ------------
4 files changed, 3 insertions(+), 16 deletions(-)
diff --git a/migration-exec.c b/migration-exec.c
index 6c97db9..95e9779 100644
--- a/migration-exec.c
+++ b/migration-exec.c
@@ -98,7 +98,7 @@ static void exec_accept_incoming_migration(void *opaque)
QEMUFile *f = opaque;
process_incoming_migration(f);
- qemu_set_fd_handler2(qemu_stdio_fd(f), NULL, NULL, NULL, NULL);
+ qemu_set_fd_handler2(qemu_file_fd(f), NULL, NULL, NULL, NULL);
qemu_fclose(f);
}
@@ -113,7 +113,7 @@ int exec_start_incoming_migration(const char *command)
return -errno;
}
- qemu_set_fd_handler2(qemu_stdio_fd(f), NULL,
+ qemu_set_fd_handler2(qemu_file_fd(f), NULL,
exec_accept_incoming_migration, NULL, f);
return 0;
diff --git a/migration-fd.c b/migration-fd.c
index 50138ed..d9c13fe 100644
--- a/migration-fd.c
+++ b/migration-fd.c
@@ -104,7 +104,7 @@ static void fd_accept_incoming_migration(void *opaque)
QEMUFile *f = opaque;
process_incoming_migration(f);
- qemu_set_fd_handler2(qemu_stdio_fd(f), NULL, NULL, NULL, NULL);
+ qemu_set_fd_handler2(qemu_file_fd(f), NULL, NULL, NULL, NULL);
qemu_fclose(f);
}
diff --git a/qemu-file.h b/qemu-file.h
index 98a8023..1a12e7d 100644
--- a/qemu-file.h
+++ b/qemu-file.h
@@ -70,7 +70,6 @@ QEMUFile *qemu_fdopen(int fd, const char *mode);
QEMUFile *qemu_fopen_socket(int fd);
QEMUFile *qemu_popen(FILE *popen_file, const char *mode);
QEMUFile *qemu_popen_cmd(const char *command, const char *mode);
-int qemu_stdio_fd(QEMUFile *f);
int qemu_file_fd(QEMUFile *f);
void qemu_fflush(QEMUFile *f);
void qemu_buffered_file_drain(QEMUFile *f);
diff --git a/savevm.c b/savevm.c
index cba1a69..ec9f5d0 100644
--- a/savevm.c
+++ b/savevm.c
@@ -293,18 +293,6 @@ QEMUFile *qemu_popen_cmd(const char *command, const char
*mode)
return qemu_popen(popen_file, mode);
}
-/* TODO: replace this with qemu_file_fd() */
-int qemu_stdio_fd(QEMUFile *f)
-{
- QEMUFileStdio *p;
- int fd;
-
- p = (QEMUFileStdio *)f->opaque;
- fd = fileno(p->stdio_file);
-
- return fd;
-}
-
QEMUFile *qemu_fdopen(int fd, const char *mode)
{
QEMUFileStdio *s;
--
1.7.1.1
- [Qemu-devel] [PATCH v2 22/41] savevm/QEMUFile: introduce qemu_fopen_fd, (continued)
- [Qemu-devel] [PATCH v2 22/41] savevm/QEMUFile: introduce qemu_fopen_fd, Isaku Yamahata, 2012/06/04
- [Qemu-devel] [PATCH v2 09/41] arch_init: introduce helper function to find ram block with id string, Isaku Yamahata, 2012/06/04
- [Qemu-devel] [PATCH v2 02/41] arch_init: export RAM_SAVE_xxx flags for postcopy, Isaku Yamahata, 2012/06/04
- [Qemu-devel] [PATCH v2 13/41] exec.c: factor out qemu_get_ram_ptr(), Isaku Yamahata, 2012/06/04
- [Qemu-devel] [PATCH v2 21/41] savevm: rename QEMUFileSocket to QEMUFileFD, socket_close to fd_close, Isaku Yamahata, 2012/06/04
- [Qemu-devel] [PATCH v2 11/41] arch_init: factor out counting transferred bytes, Isaku Yamahata, 2012/06/04
- [Qemu-devel] [PATCH v2 27/41] buffered_file: Introduce QEMUFileNonblock for nonblock write, Isaku Yamahata, 2012/06/04
- [Qemu-devel] [PATCH v2 07/41] arch_init/ram_save_live: factor out ram_save_limit, Isaku Yamahata, 2012/06/04
- [Qemu-devel] [PATCH v2 23/41] migration.c: remove redundant line in migrate_init(), Isaku Yamahata, 2012/06/04
- [Qemu-devel] [PATCH v2 29/41] umem.h: import Linux umem.h, Isaku Yamahata, 2012/06/04
- [Qemu-devel] [PATCH v2 19/41] savevm/QEMUFile: drop qemu_stdio_fd,
Isaku Yamahata <=
- [Qemu-devel] [PATCH v2 32/41] savevm: add new section that is used by postcopy, Isaku Yamahata, 2012/06/04
- [Qemu-devel] [PATCH v2 15/41] savevm: export qemu_peek_buffer, qemu_peek_byte, qemu_file_skip, Isaku Yamahata, 2012/06/04
- [Qemu-devel] [PATCH v2 25/41] migration: factor out parameters into MigrationParams, Isaku Yamahata, 2012/06/04
- [Qemu-devel] [PATCH v2 30/41] update-linux-headers.sh: teach umem.h to update-linux-headers.sh, Isaku Yamahata, 2012/06/04
- [Qemu-devel] [PATCH v2 38/41] postcopy/outgoing: add forward, backward option to specify the size of prefault, Isaku Yamahata, 2012/06/04
- [Qemu-devel] [PATCH v2 10/41] arch_init: simplify a bit by ram_find_block(), Isaku Yamahata, 2012/06/04
- [Qemu-devel] [PATCH v2 34/41] postcopy outgoing: add -p and -n option to migrate command, Isaku Yamahata, 2012/06/04
- [Qemu-devel] [PATCH v2 39/41] postcopy/outgoing: implement prefault, Isaku Yamahata, 2012/06/04
- [Qemu-devel] [PATCH v2 26/41] buffered_file: factor out buffer management logic, Isaku Yamahata, 2012/06/04
- [Qemu-devel] [PATCH v2 14/41] exec.c: export last_ram_offset(), Isaku Yamahata, 2012/06/04