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

[Xen-changelog] [xen stable-4.4] kexec: propagate ENOMEM result in error handling



commit 4a4a1d457bc9264b4399728348a2bb84c739e253
Author:     Matthew Daley <mattd@xxxxxxxxxxx>
AuthorDate: Fri Apr 4 10:45:31 2014 +0200
Commit:     Jan Beulich <jbeulich@xxxxxxxx>
CommitDate: Fri Apr 4 10:45:31 2014 +0200

    kexec: propagate ENOMEM result in error handling
    
    ...otherwise if kimage_alloc_control_page fails (presumably due to
    out-of-memory; see the invocation just before this one), the caller of
    do_kimage_alloc will think the call was successful.
    
    Signed-off-by: Matthew Daley <mattd@xxxxxxxxxxx>
    Reviewed-by: David Vrabel <david.vrabel@xxxxxxxxxx>
    master commit: 66c6349265d6536d0b77cd958ee3e5074e86233a
    master date: 2014-04-01 16:48:02 +0200
---
 xen/common/kimage.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/xen/common/kimage.c b/xen/common/kimage.c
index 91943f1..9b79a5e 100644
--- a/xen/common/kimage.c
+++ b/xen/common/kimage.c
@@ -182,6 +182,7 @@ static int do_kimage_alloc(struct kexec_image **rimage, 
paddr_t entry,
         goto out;
 
     /* Add an empty indirection page. */
+    result = -ENOMEM;
     image->entry_page = kimage_alloc_control_page(image, 0);
     if ( !image->entry_page )
         goto out;
--
generated by git-patchbot for /home/xen/git/xen.git#stable-4.4

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog


 


Rackspace

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