[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [xen master] xen/arm: domain: Remove redundant memset for v->arch.saved_context



commit e469908d48d0d6f2c57336a7391c2eb81ff21bba
Author:     Baodong Chen <chenbaodong@xxxxxxxxxx>
AuthorDate: Mon Jun 10 13:15:47 2019 +0800
Commit:     Julien Grall <julien.grall@xxxxxxx>
CommitDate: Tue Jun 11 14:15:28 2019 +0100

    xen/arm: domain: Remove redundant memset for v->arch.saved_context
    
    arch.saved_context is already zeroed in alloc_vcpu_struct() by
    clear_page(). So there are no need to memset it again in
    arch_vcpu_create().
    
    Signed-off-by: Baodong Chen <chenbaodong@xxxxxxxxxx>
    [julien: Rework the commit message]
    Reviewed-by: Julien Grall <julien.grall@xxxxxxx>
---
 xen/arch/arm/domain.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/xen/arch/arm/domain.c b/xen/arch/arm/domain.c
index ff330b35e6..ad1b106bd7 100644
--- a/xen/arch/arm/domain.c
+++ b/xen/arch/arm/domain.c
@@ -557,7 +557,6 @@ int arch_vcpu_create(struct vcpu *v)
                                            - sizeof(struct cpu_info));
     memset(v->arch.cpu_info, 0, sizeof(*v->arch.cpu_info));
 
-    memset(&v->arch.saved_context, 0, sizeof(v->arch.saved_context));
     v->arch.saved_context.sp = (register_t)v->arch.cpu_info;
     v->arch.saved_context.pc = (register_t)continue_new_vcpu;
 
--
generated by git-patchbot for /home/xen/git/xen.git#master

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/xen-changelog

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.