diff options
author | David S. Miller <davem@davemloft.net> | 2010-01-23 03:31:06 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-01-23 03:31:06 -0500 |
commit | 51c24aaacaea90c8e87f1dec75a2ac7622b593f8 (patch) | |
tree | 9f54936c87764bef75e97395cb56b7d1e0df24c6 /arch/ia64/kvm | |
parent | 4276e47e2d1c85a2477caf0d22b91c4f2377fba8 (diff) | |
parent | 6be325719b3e54624397e413efd4b33a997e55a3 (diff) |
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
Diffstat (limited to 'arch/ia64/kvm')
-rw-r--r-- | arch/ia64/kvm/vcpu.h | 9 | ||||
-rw-r--r-- | arch/ia64/kvm/vmm.c | 4 | ||||
-rw-r--r-- | arch/ia64/kvm/vtlb.c | 2 |
3 files changed, 9 insertions, 6 deletions
diff --git a/arch/ia64/kvm/vcpu.h b/arch/ia64/kvm/vcpu.h index 360724d3ae69..988911b4cc7a 100644 --- a/arch/ia64/kvm/vcpu.h +++ b/arch/ia64/kvm/vcpu.h | |||
@@ -388,6 +388,9 @@ static inline u64 __gpfn_is_io(u64 gpfn) | |||
388 | #define _vmm_raw_spin_lock(x) do {}while(0) | 388 | #define _vmm_raw_spin_lock(x) do {}while(0) |
389 | #define _vmm_raw_spin_unlock(x) do {}while(0) | 389 | #define _vmm_raw_spin_unlock(x) do {}while(0) |
390 | #else | 390 | #else |
391 | typedef struct { | ||
392 | volatile unsigned int lock; | ||
393 | } vmm_spinlock_t; | ||
391 | #define _vmm_raw_spin_lock(x) \ | 394 | #define _vmm_raw_spin_lock(x) \ |
392 | do { \ | 395 | do { \ |
393 | __u32 *ia64_spinlock_ptr = (__u32 *) (x); \ | 396 | __u32 *ia64_spinlock_ptr = (__u32 *) (x); \ |
@@ -405,12 +408,12 @@ static inline u64 __gpfn_is_io(u64 gpfn) | |||
405 | 408 | ||
406 | #define _vmm_raw_spin_unlock(x) \ | 409 | #define _vmm_raw_spin_unlock(x) \ |
407 | do { barrier(); \ | 410 | do { barrier(); \ |
408 | ((spinlock_t *)x)->raw_lock.lock = 0; } \ | 411 | ((vmm_spinlock_t *)x)->lock = 0; } \ |
409 | while (0) | 412 | while (0) |
410 | #endif | 413 | #endif |
411 | 414 | ||
412 | void vmm_spin_lock(spinlock_t *lock); | 415 | void vmm_spin_lock(vmm_spinlock_t *lock); |
413 | void vmm_spin_unlock(spinlock_t *lock); | 416 | void vmm_spin_unlock(vmm_spinlock_t *lock); |
414 | enum { | 417 | enum { |
415 | I_TLB = 1, | 418 | I_TLB = 1, |
416 | D_TLB = 2 | 419 | D_TLB = 2 |
diff --git a/arch/ia64/kvm/vmm.c b/arch/ia64/kvm/vmm.c index f4b4c899bb6c..7a62f75778c5 100644 --- a/arch/ia64/kvm/vmm.c +++ b/arch/ia64/kvm/vmm.c | |||
@@ -60,12 +60,12 @@ static void __exit kvm_vmm_exit(void) | |||
60 | return ; | 60 | return ; |
61 | } | 61 | } |
62 | 62 | ||
63 | void vmm_spin_lock(spinlock_t *lock) | 63 | void vmm_spin_lock(vmm_spinlock_t *lock) |
64 | { | 64 | { |
65 | _vmm_raw_spin_lock(lock); | 65 | _vmm_raw_spin_lock(lock); |
66 | } | 66 | } |
67 | 67 | ||
68 | void vmm_spin_unlock(spinlock_t *lock) | 68 | void vmm_spin_unlock(vmm_spinlock_t *lock) |
69 | { | 69 | { |
70 | _vmm_raw_spin_unlock(lock); | 70 | _vmm_raw_spin_unlock(lock); |
71 | } | 71 | } |
diff --git a/arch/ia64/kvm/vtlb.c b/arch/ia64/kvm/vtlb.c index 20b3852f7a6e..4332f7ee5203 100644 --- a/arch/ia64/kvm/vtlb.c +++ b/arch/ia64/kvm/vtlb.c | |||
@@ -182,7 +182,7 @@ void mark_pages_dirty(struct kvm_vcpu *v, u64 pte, u64 ps) | |||
182 | { | 182 | { |
183 | u64 i, dirty_pages = 1; | 183 | u64 i, dirty_pages = 1; |
184 | u64 base_gfn = (pte&_PAGE_PPN_MASK) >> PAGE_SHIFT; | 184 | u64 base_gfn = (pte&_PAGE_PPN_MASK) >> PAGE_SHIFT; |
185 | spinlock_t *lock = __kvm_va(v->arch.dirty_log_lock_pa); | 185 | vmm_spinlock_t *lock = __kvm_va(v->arch.dirty_log_lock_pa); |
186 | void *dirty_bitmap = (void *)KVM_MEM_DIRTY_LOG_BASE; | 186 | void *dirty_bitmap = (void *)KVM_MEM_DIRTY_LOG_BASE; |
187 | 187 | ||
188 | dirty_pages <<= ps <= PAGE_SHIFT ? 0 : ps - PAGE_SHIFT; | 188 | dirty_pages <<= ps <= PAGE_SHIFT ? 0 : ps - PAGE_SHIFT; |