mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-22 13:45:38 +00:00
Support for inactive domain management
This commit is contained in:
parent
dc28f35f11
commit
f991089ce4
10
ChangeLog
10
ChangeLog
@ -1,3 +1,13 @@
|
||||
Thu Nov 16 13:09:42 EST 2006 Daniel Berrange <berrange@redhat.com>
|
||||
|
||||
* src/Makefile.am: Added new xm_internal.c source file
|
||||
* src/libvirt.c: Call the xenXMRegister() method to activate
|
||||
the XM backend
|
||||
* src/driver.h: Added a unique id for XM driver backend
|
||||
* src/internal.h: Increase number of drivers allowed
|
||||
* src/xm_internal.h, src/xm_internal.c: New driver for
|
||||
managing inactive domains from /etc/xen config files
|
||||
|
||||
Thu Nov 16 18:18:12 CET 2006 Daniel Veillard <veillard@redhat.com>
|
||||
|
||||
* include/libvirt/libvirt.h include/libvirt/libvirt.h.in
|
||||
|
@ -27,7 +27,8 @@ libvirt_la_SOURCES = \
|
||||
virterror.c \
|
||||
driver.h \
|
||||
proxy_internal.c proxy_internal.h \
|
||||
conf.c conf.h
|
||||
conf.c conf.h \
|
||||
xm_internal.c xm_internal.h
|
||||
|
||||
bin_PROGRAMS = virsh
|
||||
|
||||
|
@ -21,7 +21,8 @@ typedef enum {
|
||||
VIR_DRV_XEN_STORE = 2,
|
||||
VIR_DRV_XEN_DAEMON = 3,
|
||||
VIR_DRV_TEST = 4,
|
||||
VIR_DRV_XEN_PROXY = 5
|
||||
VIR_DRV_XEN_PROXY = 5,
|
||||
VIR_DRV_XEN_XM = 6
|
||||
} virDrvNo;
|
||||
|
||||
|
||||
|
@ -84,7 +84,7 @@ extern "C" {
|
||||
#define VIR_IS_DOMAIN(obj) ((obj) && (obj)->magic==VIR_DOMAIN_MAGIC)
|
||||
#define VIR_IS_CONNECTED_DOMAIN(obj) (VIR_IS_DOMAIN(obj) && VIR_IS_CONNECT((obj)->conn))
|
||||
|
||||
#define MAX_DRIVERS 5
|
||||
#define MAX_DRIVERS 10
|
||||
|
||||
/*
|
||||
* Flags for Xen connections
|
||||
|
@ -28,6 +28,7 @@
|
||||
#include "xen_internal.h"
|
||||
#include "xend_internal.h"
|
||||
#include "xs_internal.h"
|
||||
#include "xm_internal.h"
|
||||
#include "proxy_internal.h"
|
||||
#include "xml.h"
|
||||
#include "test.h"
|
||||
@ -76,6 +77,7 @@ virInitialize(void)
|
||||
xenProxyRegister();
|
||||
xenDaemonRegister();
|
||||
xenStoreRegister();
|
||||
xenXMRegister();
|
||||
testRegister();
|
||||
return(0);
|
||||
}
|
||||
|
1377
src/xm_internal.c
Normal file
1377
src/xm_internal.c
Normal file
File diff suppressed because it is too large
Load Diff
47
src/xm_internal.h
Normal file
47
src/xm_internal.h
Normal file
@ -0,0 +1,47 @@
|
||||
/*
|
||||
* xm_internal.h: helper routines for dealing with inactive domains
|
||||
*
|
||||
* Copyright (C) 2006
|
||||
*
|
||||
* Daniel Berrange <berrange@redhat.com>
|
||||
*
|
||||
* This file is subject to the terms and conditions of the GNU Lesser General
|
||||
* Public License. See the file COPYING.LIB in the main directory of this
|
||||
* archive for more details.
|
||||
*/
|
||||
|
||||
#ifndef _LIBVIRT_XM_INTERNAL_H_
|
||||
#define _LIBVIRT_XM_INTERNAL_H_
|
||||
|
||||
#include "libvirt/libvirt.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
void xenXMRegister(void);
|
||||
int xenXMOpen(virConnectPtr conn, const char *name, int flags);
|
||||
int xenXMClose(virConnectPtr conn);
|
||||
const char *xenXMGetType(virConnectPtr conn);
|
||||
int xenXMDomainGetInfo(virDomainPtr domain, virDomainInfoPtr info);
|
||||
char *xenXMDomainDumpXML(virDomainPtr domain, int flags);
|
||||
int xenXMDomainSetMemory(virDomainPtr domain, unsigned long memory);
|
||||
int xenXMDomainSetMaxMemory(virDomainPtr domain, unsigned long memory);
|
||||
unsigned long xenXMDomainGetMaxMemory(virDomainPtr domain);
|
||||
int xenXMDomainSetVcpus(virDomainPtr domain, unsigned int vcpus);
|
||||
virDomainPtr xenXMDomainLookupByName(virConnectPtr conn, const char *domname);
|
||||
virDomainPtr xenXMDomainLookupByUUID(virConnectPtr conn,
|
||||
const unsigned char *uuid);
|
||||
|
||||
int xenXMListDefinedDomains(virConnectPtr conn, const char **names, int maxnames);
|
||||
int xenXMNumOfDefinedDomains(virConnectPtr conn);
|
||||
|
||||
int xenXMDomainCreate(virDomainPtr domain);
|
||||
virDomainPtr xenXMDomainDefineXML(virConnectPtr con, const char *xml);
|
||||
int xenXMDomainUndefine(virDomainPtr domain);
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
#endif
|
Loading…
Reference in New Issue
Block a user