[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 23/41] Rename buffered_ to migration_
From: |
Orit Wasserman |
Subject: |
Re: [Qemu-devel] [PATCH 23/41] Rename buffered_ to migration_ |
Date: |
Tue, 19 Feb 2013 17:24:56 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130110 Thunderbird/17.0.2 |
On 02/15/2013 07:46 PM, Paolo Bonzini wrote:
> From: Juan Quintela <address@hidden>
>
> This is consistent once that we have moved everything to migration.c
>
> Signed-off-by: Juan Quintela <address@hidden>
> ---
> migration.c | 32 ++++++++++++++++----------------
> 1 files changed, 16 insertions(+), 16 deletions(-)
>
> diff --git a/migration.c b/migration.c
> index 1f6fbdc..bfe6be1 100644
> --- a/migration.c
> +++ b/migration.c
> @@ -503,7 +503,7 @@ int64_t migrate_xbzrle_cache_size(void)
>
> /* migration thread support */
>
> -static int buffered_put_buffer(void *opaque, const uint8_t *buf,
> +static int migration_put_buffer(void *opaque, const uint8_t *buf,
> int64_t pos, int size)
> {
> MigrationState *s = opaque;
> @@ -540,7 +540,7 @@ static int buffered_put_buffer(void *opaque, const
> uint8_t *buf,
> return sent;
> }
>
> -static int buffered_close(void *opaque)
> +static int migration_close(void *opaque)
> {
> MigrationState *s = opaque;
>
> @@ -554,7 +554,7 @@ static int buffered_close(void *opaque)
> return migrate_fd_close(s);
> }
>
> -static int buffered_get_fd(void *opaque)
> +static int migration_get_fd(void *opaque)
> {
> MigrationState *s = opaque;
>
> @@ -567,7 +567,7 @@ static int buffered_get_fd(void *opaque)
> * 1: Time to stop
> * negative: There has been an error
> */
> -static int buffered_rate_limit(void *opaque)
> +static int migration_rate_limit(void *opaque)
> {
> MigrationState *s = opaque;
> int ret;
> @@ -584,7 +584,7 @@ static int buffered_rate_limit(void *opaque)
> return 0;
> }
>
> -static int64_t buffered_set_rate_limit(void *opaque, int64_t new_rate)
> +static int64_t migration_set_rate_limit(void *opaque, int64_t new_rate)
> {
> MigrationState *s = opaque;
> if (qemu_file_get_error(s->file)) {
> @@ -600,14 +600,14 @@ out:
> return s->xfer_limit;
> }
>
> -static int64_t buffered_get_rate_limit(void *opaque)
> +static int64_t migration_get_rate_limit(void *opaque)
> {
> MigrationState *s = opaque;
>
> return s->xfer_limit;
> }
>
> -static void *buffered_file_thread(void *opaque)
> +static void *migration_thread(void *opaque)
> {
> MigrationState *s = opaque;
> int64_t initial_time = qemu_get_clock_ms(rt_clock);
> @@ -684,13 +684,13 @@ static void *buffered_file_thread(void *opaque)
> return NULL;
> }
>
> -static const QEMUFileOps buffered_file_ops = {
> - .get_fd = buffered_get_fd,
> - .put_buffer = buffered_put_buffer,
> - .close = buffered_close,
> - .rate_limit = buffered_rate_limit,
> - .get_rate_limit = buffered_get_rate_limit,
> - .set_rate_limit = buffered_set_rate_limit,
> +static const QEMUFileOps migration_file_ops = {
> + .get_fd = migration_get_fd,
> + .put_buffer = migration_put_buffer,
> + .close = migration_close,
> + .rate_limit = migration_rate_limit,
> + .get_rate_limit = migration_get_rate_limit,
> + .set_rate_limit = migration_set_rate_limit,
> };
>
> void migrate_fd_connect(MigrationState *s)
> @@ -700,9 +700,9 @@ void migrate_fd_connect(MigrationState *s)
> s->xfer_limit = s->bandwidth_limit / XFER_LIMIT_RATIO;
>
> s->cleanup_bh = qemu_bh_new(migrate_fd_cleanup, s);
> - s->file = qemu_fopen_ops(s, &buffered_file_ops);
> + s->file = qemu_fopen_ops(s, &migration_file_ops);
>
> - qemu_thread_create(&s->thread, buffered_file_thread, s,
> + qemu_thread_create(&s->thread, migration_thread, s,
> QEMU_THREAD_JOINABLE);
> notifier_list_notify(&migration_state_notifiers, s);
> }
>
Reviewed-by: Orit Wasserman <address@hidden>
- Re: [Qemu-devel] [PATCH 08/41] qemu-file: temporarily expose qemu_file_set_error and qemu_fflush, (continued)
- [Qemu-devel] [PATCH 21/41] migration: run setup callbacks out of big lock, Paolo Bonzini, 2013/02/15
- [Qemu-devel] [PATCH 18/41] block-migration: add lock, Paolo Bonzini, 2013/02/15
- [Qemu-devel] [PATCH 23/41] Rename buffered_ to migration_, Paolo Bonzini, 2013/02/15
- [Qemu-devel] [PATCH 20/41] migration: run pending/iterate callbacks out of big lock, Paolo Bonzini, 2013/02/15
- Re: [Qemu-devel] [PATCH 20/41] migration: run pending/iterate callbacks out of big lock, Juan Quintela, 2013/02/22
- [Qemu-devel] [PATCH 22/41] migration: yay, buffering is gone, Paolo Bonzini, 2013/02/15
- [Qemu-devel] [PATCH 27/41] migration: remove useless qemu_file_get_error check, Paolo Bonzini, 2013/02/15