aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/kvm/paging_tmpl.h
diff options
context:
space:
mode:
authorAvi Kivity <avi@qumranet.com>2007-05-31 08:46:04 -0400
committerAvi Kivity <avi@qumranet.com>2007-07-16 05:05:44 -0400
commite663ee64aefc57f7eff7325142206c4ea0200be8 (patch)
treea95c5a1015914ee4101c1770039ad1457e8767c3 /drivers/kvm/paging_tmpl.h
parent0d551bb698e1328f685ae3611c4a4a96f41bef97 (diff)
KVM: MMU: Make setting shadow ptes atomic on i386
Signed-off-by: Avi Kivity <avi@qumranet.com>
Diffstat (limited to 'drivers/kvm/paging_tmpl.h')
-rw-r--r--drivers/kvm/paging_tmpl.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/kvm/paging_tmpl.h b/drivers/kvm/paging_tmpl.h
index 397a4039eaad..fabc2c9093cd 100644
--- a/drivers/kvm/paging_tmpl.h
+++ b/drivers/kvm/paging_tmpl.h
@@ -234,7 +234,7 @@ static void FNAME(set_pte_common)(struct kvm_vcpu *vcpu,
234 spte |= gaddr; 234 spte |= gaddr;
235 spte |= PT_SHADOW_IO_MARK; 235 spte |= PT_SHADOW_IO_MARK;
236 spte &= ~PT_PRESENT_MASK; 236 spte &= ~PT_PRESENT_MASK;
237 *shadow_pte = spte; 237 set_shadow_pte(shadow_pte, spte);
238 return; 238 return;
239 } 239 }
240 240
@@ -280,7 +280,7 @@ unshadowed:
280 if (access_bits & PT_WRITABLE_MASK) 280 if (access_bits & PT_WRITABLE_MASK)
281 mark_page_dirty(vcpu->kvm, gaddr >> PAGE_SHIFT); 281 mark_page_dirty(vcpu->kvm, gaddr >> PAGE_SHIFT);
282 282
283 *shadow_pte = spte; 283 set_shadow_pte(shadow_pte, spte);
284 page_header_update_slot(vcpu->kvm, shadow_pte, gaddr); 284 page_header_update_slot(vcpu->kvm, shadow_pte, gaddr);
285 if (!was_rmapped) 285 if (!was_rmapped)
286 rmap_add(vcpu, shadow_pte); 286 rmap_add(vcpu, shadow_pte);