From: Boris Ostrovsky Date: Thu, 14 Sep 2017 16:01:38 +0000 (+0200) Subject: x86/mm: initialize ol1e in create_grant_pv_mapping() for older compilers X-Git-Tag: archive/raspbian/4.11.1-1+rpi1~1^2~66^2~1419 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=7c9283ea1f2af5c495709c34991df64841d78e7c;p=xen.git x86/mm: initialize ol1e in create_grant_pv_mapping() for older compilers On gcc 4.4.4: mm.c: In function ‘create_grant_pv_mapping’: mm.c:3839: error: ‘ol1e.l1’ may be used uninitialized in this function While ol1e would not be used uninitialized (because rc needs to be properly set) we have to accommodate these older compliers. Signed-off-by: Boris Ostrovsky Reviewed-by: Jan Beulich --- diff --git a/xen/arch/x86/mm.c b/xen/arch/x86/mm.c index 5208e73734..14dae66664 100644 --- a/xen/arch/x86/mm.c +++ b/xen/arch/x86/mm.c @@ -3836,7 +3836,7 @@ int create_grant_pv_mapping(uint64_t addr, unsigned long frame, { struct vcpu *curr = current; struct domain *currd = curr->domain; - l1_pgentry_t nl1e, ol1e, *pl1e; + l1_pgentry_t nl1e, ol1e = { }, *pl1e; struct page_info *page; mfn_t gl1mfn; int rc = GNTST_general_error;