# HG changeset patch
# User Jerone Young <[EMAIL PROTECTED]>
# Date 1193998622 18000
# Node ID 1a317a4b44a4553f43eeb1165e543396a198fac4
# Parent  ad3abdfa2584ffe4f316987df65ee2130f23551c
Make functions in libkvm.c nonstatic.

This patch makes the following functions nonstatic. These
functions are potentially reusable by other archs, but are
need by arch specific code in libkvm-x86.c.

These functions include:
        handle_halt
        handle_shutdown
        post_kvm_run
        pre_kvm_run
        handle_io_window
        handle_debug

Signed-off-by: Jerone Young <[EMAIL PROTECTED]>

diff --git a/libkvm/kvm-common.h b/libkvm/kvm-common.h
new file mode 100644
--- /dev/null
+++ b/libkvm/kvm-common.h
@@ -0,0 +1,20 @@
+/* This header is for functions & variables that will ONLY be
+ * used inside libkvm. 
+ * THESE ARE NOT EXPOSED TO THE USER AND ARE ONLY FOR USE 
+ * WITHIN LIBKVM.
+ */
+#ifndef KVM_COMMON_H
+#define KVM_COMMON_H
+
+void *kvm_create_userspace_phys_mem(kvm_context_t kvm, unsigned long 
phys_start,
+               unsigned long len, int log, int writable);
+
+int handle_halt(kvm_context_t kvm, int vcpu);
+int handle_shutdown(kvm_context_t kvm, int vcpu);
+void post_kvm_run(kvm_context_t kvm, int vcpu);
+int pre_kvm_run(kvm_context_t kvm, int vcpu);
+int handle_io_window(kvm_context_t kvm);
+int handle_debug(kvm_context_t kvm, int vcpu);
+int try_push_interrupts(kvm_context_t kvm);
+
+#endif
diff --git a/libkvm/libkvm.c b/libkvm/libkvm.c
--- a/libkvm/libkvm.c
+++ b/libkvm/libkvm.c
@@ -659,7 +659,7 @@ static int handle_io(kvm_context_t kvm, 
        return 0;
 }
 
-static int handle_debug(kvm_context_t kvm, int vcpu)
+int handle_debug(kvm_context_t kvm, int vcpu)
 {
        return kvm->callbacks->debug(kvm->opaque, vcpu);
 }
@@ -944,17 +944,17 @@ static int handle_mmio(kvm_context_t kvm
        return r;
 }
 
-static int handle_io_window(kvm_context_t kvm)
+int handle_io_window(kvm_context_t kvm)
 {
        return kvm->callbacks->io_window(kvm->opaque);
 }
 
-static int handle_halt(kvm_context_t kvm, int vcpu)
+int handle_halt(kvm_context_t kvm, int vcpu)
 {
        return kvm->callbacks->halt(kvm->opaque, vcpu);
 }
 
-static int handle_shutdown(kvm_context_t kvm, int vcpu)
+int handle_shutdown(kvm_context_t kvm, int vcpu)
 {
        return kvm->callbacks->shutdown(kvm->opaque, vcpu);
 }
@@ -964,12 +964,12 @@ int try_push_interrupts(kvm_context_t kv
        return kvm->callbacks->try_push_interrupts(kvm->opaque);
 }
 
-static void post_kvm_run(kvm_context_t kvm, int vcpu)
+void post_kvm_run(kvm_context_t kvm, int vcpu)
 {
        kvm->callbacks->post_kvm_run(kvm->opaque, vcpu);
 }
 
-static int pre_kvm_run(kvm_context_t kvm, int vcpu)
+int pre_kvm_run(kvm_context_t kvm, int vcpu)
 {
        return kvm->callbacks->pre_kvm_run(kvm->opaque, vcpu);
 }

-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel

Reply via email to