]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
KVM: VMX: Replace memset(<addr>, 0, PAGESIZE) with clear_page(<addr>)
authorShani Moideen <shani.moideen@wipro.com>
Mon, 11 Jun 2007 04:01:33 +0000 (09:31 +0530)
committerAvi Kivity <avi@qumranet.com>
Mon, 16 Jul 2007 09:05:47 +0000 (12:05 +0300)
Signed-off-by: Shani Moideen <shani.moideen@wipro.com>
Signed-off-by: Avi Kivity <avi@qumranet.com>
drivers/kvm/vmx.c

index b969db1e08304373bf6746eb565cfc283c9c58a7..b909b5455675f7eea7c87e310937a909f7652d96 100644 (file)
@@ -1180,16 +1180,16 @@ static int init_rmode_tss(struct kvm* kvm)
        }
 
        page = kmap_atomic(p1, KM_USER0);
-       memset(page, 0, PAGE_SIZE);
+       clear_page(page);
        *(u16*)(page + 0x66) = TSS_BASE_SIZE + TSS_REDIRECTION_SIZE;
        kunmap_atomic(page, KM_USER0);
 
        page = kmap_atomic(p2, KM_USER0);
-       memset(page, 0, PAGE_SIZE);
+       clear_page(page);
        kunmap_atomic(page, KM_USER0);
 
        page = kmap_atomic(p3, KM_USER0);
-       memset(page, 0, PAGE_SIZE);
+       clear_page(page);
        *(page + RMODE_TSS_SIZE - 2 * PAGE_SIZE - 1) = ~0;
        kunmap_atomic(page, KM_USER0);