2018-02-21 13:18:03 +00:00
|
|
|
/*
|
|
|
|
* qemu_migration_params.h: QEMU migration parameters handling
|
|
|
|
*
|
|
|
|
* Copyright (C) 2006-2018 Red Hat, Inc.
|
|
|
|
*
|
|
|
|
* This library is free software; you can redistribute it and/or
|
|
|
|
* modify it under the terms of the GNU Lesser General Public
|
|
|
|
* License as published by the Free Software Foundation; either
|
|
|
|
* version 2.1 of the License, or (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This library is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
|
* Lesser General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU Lesser General Public
|
|
|
|
* License along with this library. If not, see
|
|
|
|
* <http://www.gnu.org/licenses/>.
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef __QEMU_MIGRATION_PARAMS_H__
|
|
|
|
# define __QEMU_MIGRATION_PARAMS_H__
|
|
|
|
|
|
|
|
# include "internal.h"
|
|
|
|
|
|
|
|
# include "qemu_monitor.h"
|
|
|
|
# include "qemu_conf.h"
|
|
|
|
|
|
|
|
|
2018-02-21 16:40:45 +00:00
|
|
|
typedef struct _qemuMigrationCompression qemuMigrationCompression;
|
|
|
|
typedef qemuMigrationCompression *qemuMigrationCompressionPtr;
|
|
|
|
struct _qemuMigrationCompression {
|
|
|
|
unsigned long long methods;
|
|
|
|
|
|
|
|
bool level_set;
|
|
|
|
int level;
|
|
|
|
|
|
|
|
bool threads_set;
|
|
|
|
int threads;
|
|
|
|
|
|
|
|
bool dthreads_set;
|
|
|
|
int dthreads;
|
|
|
|
|
|
|
|
bool xbzrle_cache_set;
|
|
|
|
unsigned long long xbzrle_cache;
|
|
|
|
};
|
|
|
|
|
|
|
|
|
2018-02-21 16:22:29 +00:00
|
|
|
typedef struct _qemuMigrationParams qemuMigrationParams;
|
|
|
|
typedef qemuMigrationParams *qemuMigrationParamsPtr;
|
|
|
|
|
|
|
|
|
|
|
|
qemuMigrationParamsPtr
|
2018-02-21 15:59:10 +00:00
|
|
|
qemuMigrationParamsNew(void);
|
|
|
|
|
2018-02-21 16:22:29 +00:00
|
|
|
qemuMigrationParamsPtr
|
2018-02-21 13:18:03 +00:00
|
|
|
qemuMigrationParamsFromFlags(virTypedParameterPtr params,
|
|
|
|
int nparams,
|
|
|
|
unsigned long flags);
|
|
|
|
|
|
|
|
void
|
2018-02-21 16:22:29 +00:00
|
|
|
qemuMigrationParamsFree(qemuMigrationParamsPtr migParams);
|
2018-02-21 13:18:03 +00:00
|
|
|
|
|
|
|
int
|
2018-02-28 13:44:12 +00:00
|
|
|
qemuMigrationParamsApply(virQEMUDriverPtr driver,
|
|
|
|
virDomainObjPtr vm,
|
|
|
|
int asyncJob,
|
|
|
|
qemuMigrationParamsPtr migParams);
|
2018-02-21 13:18:03 +00:00
|
|
|
|
2018-02-26 14:47:33 +00:00
|
|
|
int
|
|
|
|
qemuMigrationParamsSetCapability(virDomainObjPtr vm,
|
|
|
|
qemuMonitorMigrationCaps capability,
|
|
|
|
bool state,
|
|
|
|
qemuMigrationParamsPtr migParams);
|
|
|
|
|
|
|
|
int
|
|
|
|
qemuMigrationParamsSetPostCopy(virDomainObjPtr vm,
|
|
|
|
bool state,
|
|
|
|
qemuMigrationParamsPtr migParams);
|
|
|
|
|
2018-02-21 13:18:03 +00:00
|
|
|
int
|
2018-02-28 09:45:07 +00:00
|
|
|
qemuMigrationParamsEnableTLS(virQEMUDriverPtr driver,
|
|
|
|
virDomainObjPtr vm,
|
|
|
|
bool tlsListen,
|
|
|
|
int asyncJob,
|
|
|
|
char **tlsAlias,
|
|
|
|
char **secAlias,
|
2018-02-28 11:57:19 +00:00
|
|
|
const char *hostname,
|
2018-02-28 09:45:07 +00:00
|
|
|
qemuMigrationParamsPtr migParams);
|
2018-02-21 13:18:03 +00:00
|
|
|
|
|
|
|
int
|
2018-02-28 08:35:53 +00:00
|
|
|
qemuMigrationParamsDisableTLS(virDomainObjPtr vm,
|
|
|
|
qemuMigrationParamsPtr migParams);
|
2018-02-21 13:18:03 +00:00
|
|
|
|
|
|
|
int
|
2018-03-01 10:28:05 +00:00
|
|
|
qemuMigrationParamsSetCompression(virDomainObjPtr vm,
|
2018-02-21 13:18:03 +00:00
|
|
|
qemuMigrationCompressionPtr compression,
|
2018-02-21 16:22:29 +00:00
|
|
|
qemuMigrationParamsPtr migParams);
|
2018-02-21 13:18:03 +00:00
|
|
|
|
2018-02-27 14:45:52 +00:00
|
|
|
int
|
|
|
|
qemuMigrationParamsCheck(virQEMUDriverPtr driver,
|
|
|
|
virDomainObjPtr vm,
|
2018-03-07 09:45:18 +00:00
|
|
|
int asyncJob,
|
|
|
|
qemuMigrationParamsPtr migParams);
|
2018-02-27 14:45:52 +00:00
|
|
|
|
2018-02-21 13:18:03 +00:00
|
|
|
void
|
|
|
|
qemuMigrationParamsReset(virQEMUDriverPtr driver,
|
|
|
|
virDomainObjPtr vm,
|
2018-02-27 16:09:17 +00:00
|
|
|
int asyncJob,
|
|
|
|
qemuMigrationParamsPtr origParams);
|
2018-02-21 13:18:03 +00:00
|
|
|
|
2018-02-20 15:40:21 +00:00
|
|
|
int
|
|
|
|
qemuMigrationCapsCheck(virQEMUDriverPtr driver,
|
|
|
|
virDomainObjPtr vm,
|
|
|
|
int asyncJob);
|
|
|
|
|
2018-04-06 13:22:51 +00:00
|
|
|
bool
|
|
|
|
qemuMigrationCapsGet(virDomainObjPtr vm,
|
|
|
|
qemuMonitorMigrationCaps cap);
|
|
|
|
|
2018-02-21 13:18:03 +00:00
|
|
|
#endif /* __QEMU_MIGRATION_PARAMS_H__ */
|