Consensus is that code is clearer with the tests, even though they are
redundant.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
#endif
/* Is the region suitable for relocating the multiboot modules? */
- if ( !initial_images_start &&
+ if ( !initial_images_start && (s < e) &&
((e-s) >= (modules_length+modules_headroom)) )
{
initial_images_end = e;
}
}
- if ( !kexec_crash_area.start && ((e-s) >= kexec_crash_area.size) )
+ if ( !kexec_crash_area.start && (s < e) &&
+ ((e-s) >= kexec_crash_area.size) )
{
e = (e - kexec_crash_area.size) & PAGE_MASK;
kexec_crash_area.start = e;