Looks good & since we've previously agreed this was a good fix I'll
apply it now.
Dan.
On Fri, Feb 16, 2007 at 02:58:19PM +0000, Richard W.M. Jones wrote:
From 8f04c42e183fc0e339fdef993ec10833a056e791 Mon Sep 17 00:00:00
2001
From: Richard Jones <rjones(a)redhat.com>
Date: Fri, 16 Feb 2007 14:55:18 +0000
Subject: [PATCH] Remove init from virDriver structure.
init was never called, and only xen_internal tried to use it.
---
src/driver.h | 3 ---
src/proxy_internal.c | 1 -
src/qemu_internal.c | 1 -
src/test.c | 1 -
src/xen_internal.c | 5 ++---
src/xend_internal.c | 1 -
src/xm_internal.c | 1 -
src/xs_internal.c | 1 -
8 files changed, 2 insertions(+), 12 deletions(-)
diff --git a/src/driver.h b/src/driver.h
index c467ad0..7d79b11 100644
--- a/src/driver.h
+++ b/src/driver.h
@@ -33,8 +33,6 @@ typedef enum {
} virDrvOpenFlag;
typedef int
- (*virDrvInit) (void);
-typedef int
(*virDrvOpen) (virConnectPtr conn,
const char *name,
int flags);
@@ -150,7 +148,6 @@ struct _virDriver {
int no; /* the number virDrvNo */
const char * name; /* the name of the driver */
unsigned long ver; /* the version of the backend */
- virDrvInit init;
virDrvOpen open;
virDrvClose close;
virDrvGetType type;
diff --git a/src/proxy_internal.c b/src/proxy_internal.c
index 1e6e453..c7c325b 100644
--- a/src/proxy_internal.c
+++ b/src/proxy_internal.c
@@ -46,7 +46,6 @@ static virDriver xenProxyDriver = {
VIR_DRV_XEN_PROXY,
"XenProxy",
0,
- NULL, /* init */
xenProxyOpen, /* open */
xenProxyClose, /* close */
NULL, /* type */
diff --git a/src/qemu_internal.c b/src/qemu_internal.c
index a65b073..3fcf10f 100644
--- a/src/qemu_internal.c
+++ b/src/qemu_internal.c
@@ -1097,7 +1097,6 @@ static virDriver qemuDriver = {
VIR_DRV_QEMU,
"QEMU",
LIBVIR_VERSION_NUMBER,
- NULL, /* init */
qemuOpen, /* open */
qemuClose, /* close */
NULL, /* type */
diff --git a/src/test.c b/src/test.c
index 4025f99..5052cbd 100644
--- a/src/test.c
+++ b/src/test.c
@@ -90,7 +90,6 @@ static virDriver testDriver = {
VIR_DRV_TEST,
"Test",
LIBVIR_VERSION_NUMBER,
- NULL, /* init */
testOpen, /* open */
testClose, /* close */
NULL, /* type */
diff --git a/src/xen_internal.c b/src/xen_internal.c
index f885c66..32c550e 100644
--- a/src/xen_internal.c
+++ b/src/xen_internal.c
@@ -411,7 +411,6 @@ typedef struct xen_op_v2_dom xen_op_v2_dom;
static const char * xenHypervisorGetType(virConnectPtr conn);
static unsigned long xenHypervisorGetMaxMemory(virDomainPtr domain);
#endif
-static int xenHypervisorInit(void);
#ifndef PROXY
static virDriver xenHypervisorDriver = {
@@ -420,7 +419,6 @@ static virDriver xenHypervisorDriver = {
(DOM0_INTERFACE_VERSION >> 24) * 1000000 +
((DOM0_INTERFACE_VERSION >> 16) & 0xFF) * 1000 +
(DOM0_INTERFACE_VERSION & 0xFFFF),
- xenHypervisorInit, /* init */
xenHypervisorOpen, /* open */
xenHypervisorClose, /* close */
xenHypervisorGetType, /* type */
@@ -1127,7 +1125,8 @@ virXen_getvcpusinfo(int handle, int id, unsigned int vcpu,
virVcpuInfoPtr ipt,
* Initialize the hypervisor layer. Try to detect the kind of interface
* used i.e. pre or post changeset 10277
*/
-int xenHypervisorInit(void)
+int
+xenHypervisorInit(void)
{
int fd, ret, cmd;
hypercall_t hc;
diff --git a/src/xend_internal.c b/src/xend_internal.c
index 2ec32a8..d78cbba 100644
--- a/src/xend_internal.c
+++ b/src/xend_internal.c
@@ -62,7 +62,6 @@ static virDriver xenDaemonDriver = {
(DOM0_INTERFACE_VERSION >> 24) * 1000000 +
((DOM0_INTERFACE_VERSION >> 16) & 0xFF) * 1000 +
(DOM0_INTERFACE_VERSION & 0xFFFF),
- NULL, /* init */
xenDaemonOpen, /* open */
xenDaemonClose, /* close */
xenDaemonGetType, /* type */
diff --git a/src/xm_internal.c b/src/xm_internal.c
index ccc24b1..2e1d88e 100644
--- a/src/xm_internal.c
+++ b/src/xm_internal.c
@@ -69,7 +69,6 @@ static virDriver xenXMDriver = {
(DOM0_INTERFACE_VERSION >> 24) * 1000000 +
((DOM0_INTERFACE_VERSION >> 16) & 0xFF) * 1000 +
(DOM0_INTERFACE_VERSION & 0xFFFF),
- NULL, /* init */
xenXMOpen, /* open */
xenXMClose, /* close */
xenXMGetType, /* type */
diff --git a/src/xs_internal.c b/src/xs_internal.c
index 9dca5b2..bf7e36e 100644
--- a/src/xs_internal.c
+++ b/src/xs_internal.c
@@ -40,7 +40,6 @@ static virDriver xenStoreDriver = {
(DOM0_INTERFACE_VERSION >> 24) * 1000000 +
((DOM0_INTERFACE_VERSION >> 16) & 0xFF) * 1000 +
(DOM0_INTERFACE_VERSION & 0xFFFF),
- NULL, /* init */
xenStoreOpen, /* open */
xenStoreClose, /* close */
NULL, /* type */
--
1.4.4.2
--
Libvir-list mailing list
Libvir-list(a)redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
--
|=- Red Hat, Engineering, Emerging Technologies, Boston. +1 978 392 2496 -=|
|=- Perl modules:
http://search.cpan.org/~danberr/ -=|
|=- Projects:
http://freshmeat.net/~danielpb/ -=|
|=- GnuPG: 7D3B9505 F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505 -=|