Commit 3dcf6367 authored by David Vrabel's avatar David Vrabel

xen/balloon: cancel ballooning if adding new memory failed

If the balloon driver is adding additional memory regions to the
balloon and add_memory() fails it will likely continuously fail so
cancel the balloon operation.
Signed-off-by: default avatarDavid Vrabel <david.vrabel@citrix.com>
Reviewed-by: default avatarDaniel Kiper <daniel.kiper@oracle.com>
parent 61a734d3
...@@ -230,8 +230,8 @@ static enum bp_state reserve_additional_memory(long credit) ...@@ -230,8 +230,8 @@ static enum bp_state reserve_additional_memory(long credit)
rc = add_memory(nid, hotplug_start_paddr, balloon_hotplug << PAGE_SHIFT); rc = add_memory(nid, hotplug_start_paddr, balloon_hotplug << PAGE_SHIFT);
if (rc) { if (rc) {
pr_info("%s: add_memory() failed: %i\n", __func__, rc); pr_warn("Cannot add additional memory (%i)\n", rc);
return BP_EAGAIN; return BP_ECANCELED;
} }
balloon_hotplug -= credit; balloon_hotplug -= credit;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment