From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=43107 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PsAwN-000406-W1 for qemu-devel@nongnu.org; Wed, 23 Feb 2011 04:23:24 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PsAwM-00023s-Tc for qemu-devel@nongnu.org; Wed, 23 Feb 2011 04:23:23 -0500 Received: from mx1.redhat.com ([209.132.183.28]:33473) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PsAwM-00023C-L3 for qemu-devel@nongnu.org; Wed, 23 Feb 2011 04:23:22 -0500 From: Juan Quintela In-Reply-To: (Yoshiaki Tamura's message of "Wed, 23 Feb 2011 17:35:07 +0900") References: <83ec39769be88d8e9916e2180830765c722eebaa.1298421307.git.quintela@redhat.com> Date: Wed, 23 Feb 2011 10:21:53 +0100 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Subject: [Qemu-devel] Re: [PATCH 22/22] migration: Make state definitions local Reply-To: quintela@redhat.com List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Yoshiaki Tamura Cc: qemu-devel@nongnu.org Yoshiaki Tamura wrote: > 2011/2/23 Juan Quintela : >> >> Signed-off-by: Juan Quintela >> --- >> =C2=A0migration.c | =C2=A0 =C2=A06 ++++++ >> =C2=A0migration.h | =C2=A0 =C2=A06 ------ >> =C2=A02 files changed, 6 insertions(+), 6 deletions(-) >> >> diff --git a/migration.c b/migration.c >> index 383ebaf..90fc2a0 100644 >> --- a/migration.c >> +++ b/migration.c >> @@ -31,6 +31,12 @@ >> =C2=A0 =C2=A0 do { } while (0) >> =C2=A0#endif >> >> +#define MIG_STATE_ERROR =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0-1 >> +#define MIG_STATE_NONE =C2=A0 =C2=A0 =C2=A0 =C2=A0 0 >> +#define MIG_STATE_CANCELLED =C2=A0 =C2=A01 >> +#define MIG_STATE_ACTIVE =C2=A0 =C2=A0 =C2=A0 2 >> +#define MIG_STATE_COMPLETED =C2=A0 =C2=A03 >> + >> =C2=A0static MigrationState current_migration =3D { >> =C2=A0 =C2=A0 .state =3D MIG_STATE_NONE, >> =C2=A0 =C2=A0 =C2=A0/* Migration speed throttling */ >> diff --git a/migration.h b/migration.h >> index 9457807..493fbe5 100644 >> --- a/migration.h >> +++ b/migration.h >> @@ -18,12 +18,6 @@ >> =C2=A0#include "qemu-common.h" >> =C2=A0#include "notify.h" >> >> -#define MIG_STATE_ERROR =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0-1 >> -#define MIG_STATE_NONE =C2=A0 =C2=A0 =C2=A0 =C2=A0 0 >> -#define MIG_STATE_CANCELLED =C2=A0 =C2=A01 >> -#define MIG_STATE_ACTIVE =C2=A0 =C2=A0 =C2=A0 2 >> -#define MIG_STATE_COMPLETED =C2=A0 =C2=A03 >> - > > Although you're right, I would prefer to keep it so that somebody > outside of migration may understand the status in the future if > there are no harms. my plan is to move MigrationState inside migration.c, and then decide what to export/not export. Next thing to do is move migration to its own thread. Before doing that, I need to know what parts are used/not used outside migration.c. Removing it now means that nothing gets to use it without needing a patch. Later, Juan..