On 08/03/13 11:37, Daniel Kiper wrote: > On Thu, Feb 21, 2013 at 05:48:10PM +0000, David Vrabel wrote: >> From: David Vrabel <david.vrabel at citrix.com> >> >> Add the code needed to handle and load kexec images into Xen memory or >> into the crash region. This is needed for the new KEXEC_CMD_load and >> KEXEC_CMD_unload hypercall sub-ops. >> >> Much of this code is derived from the Linux kernel. >> >> Signed-off-by: David Vrabel <david.vrabel at citrix.com> > > [...] > >> diff --git a/xen/common/kimage.c b/xen/common/kimage.c > > [...] > >> +static int kimage_load_segment(struct kexec_image *image, xen_kexec_segment_t *segment) >> +{ >> + int result = -ENOMEM; > > Somewhere should be a check that arhitecture of loaded image > is compatible with arhitecture on which we currently running. See machine_kexec_load() in patch 5. David