提交 853f0fdf 编写于 作者: O Osier Yang

cputune: Add data structures presenting cputune XML

Also related new functions' declaration, and expose the new introduced
functions in libvirt_private.syms.

v1 - v2:
  Don't expose "virAllocVar" in libvirt_private.syms
上级 6b364420
......@@ -1029,6 +1029,21 @@ void virDomainSnapshotObjListRemove(virDomainSnapshotObjListPtr snapshots,
int virDomainSnapshotHasChildren(virDomainSnapshotObjPtr snap,
virDomainSnapshotObjListPtr snapshots);
typedef struct _virDomainVcpupinDef virDomainVcpupinDef;
typedef virDomainVcpupinDef *virDomainVcpupinDefPtr;
struct _virDomainVcpupinDef {
int vcpuid;
char *cpumask;
};
int virDomainVcpupinIsDuplicate(virDomainVcpupinDefPtr *def,
int nvcpupin,
int vcpu);
virDomainVcpupinDefPtr virDomainVcpupinFindByVcpu(virDomainVcpupinDefPtr *def,
int nvcpupin,
int vcpu);
/* Guest VM main configuration */
typedef struct _virDomainDef virDomainDef;
typedef virDomainDef *virDomainDefPtr;
......@@ -1057,6 +1072,12 @@ struct _virDomainDef {
int cpumasklen;
char *cpumask;
struct {
unsigned long shares;
int nvcpupin;
virDomainVcpupinDefPtr *vcpupin;
} cputune;
/* These 3 are based on virDomainLifeCycleAction enum flags */
int onReboot;
int onPoweroff;
......@@ -1256,6 +1277,11 @@ int virDomainCpuSetParse(const char **str,
char *virDomainCpuSetFormat(char *cpuset,
int maxcpu);
int virDomainVcpupinAdd(virDomainDefPtr def,
unsigned char *cpumap,
int maplen,
int vcpu);
int virDomainDiskInsert(virDomainDefPtr def,
virDomainDiskDefPtr disk);
void virDomainDiskInsertPreAlloced(virDomainDefPtr def,
......
......@@ -320,6 +320,9 @@ virDomainTimerTickpolicyTypeFromString;
virDomainTimerTickpolicyTypeToString;
virDomainTimerTrackTypeFromString;
virDomainTimerTrackTypeToString;
virDomainVcpupinAdd;
virDomainVcpupinFindByVcpu;
virDomainVcpupinIsDuplicate;
virDomainVideoDefFree;
virDomainVideoDefaultRAM;
virDomainVideoDefaultType;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册