[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20080307090713.90A1C1B419C@basil.firstfloor.org>
Date: Fri, 7 Mar 2008 10:07:13 +0100 (CET)
From: Andi Kleen <andi@...stfloor.org>
To: avi@...ranet.com, linux-kernel@...r.kernel.org, linux-mm@...ck.org
Subject: [PATCH] [3/13] Make kvm bad_page symbol static
Avoids global namespace clash with later patch that exports page_alloc's
bad_page. bad_page is not used outside kvm_main.c, so making it static is fine.
Cc: avi@...ranet.com
Signed-off-by: Andi Kleen <ak@...e.de>
---
include/linux/kvm_host.h | 2 --
virt/kvm/kvm_main.c | 4 ++--
2 files changed, 2 insertions(+), 4 deletions(-)
Index: linux/include/linux/kvm_host.h
===================================================================
--- linux.orig/include/linux/kvm_host.h
+++ linux/include/linux/kvm_host.h
@@ -150,8 +150,6 @@ void kvm_exit(void);
static inline int is_error_hpa(hpa_t hpa) { return hpa >> HPA_MSB; }
struct page *gva_to_page(struct kvm_vcpu *vcpu, gva_t gva);
-extern struct page *bad_page;
-
int is_error_page(struct page *page);
int kvm_is_error_hva(unsigned long addr);
int kvm_set_memory_region(struct kvm *kvm,
Index: linux/virt/kvm/kvm_main.c
===================================================================
--- linux.orig/virt/kvm/kvm_main.c
+++ linux/virt/kvm/kvm_main.c
@@ -52,6 +52,8 @@ MODULE_LICENSE("GPL");
DEFINE_SPINLOCK(kvm_lock);
LIST_HEAD(vm_list);
+static struct page *bad_page;
+
static cpumask_t cpus_hardware_enabled;
struct kmem_cache *kvm_vcpu_cache;
@@ -1271,8 +1273,6 @@ static struct sys_device kvm_sysdev = {
.cls = &kvm_sysdev_class,
};
-struct page *bad_page;
-
static inline
struct kvm_vcpu *preempt_notifier_to_vcpu(struct preempt_notifier *pn)
{
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists