On Sun, Dec 04, 2022 at 08:25:09PM +0800, Jeremy Szu wrote: > The current i386 initrd be limited under 1G memory and it works in most > compressed initrd. (also initrd_addr_max case reported by kernel) > > addr = (addr_max - aligned_size) & ~0xFFF; > > Above line to calculate the reasonable address to store the initrd. > > However, if initrd size is greater than 1G (or initrd_addr_max), then it > will get overflow, especially in x86_64 arch. > > Therefore, add a check point to prevent it overflow as well as having a > debug log for complex story of initrd addresses. > > Signed-off-by: Jeremy Szu <jeremy....@canonical.com>
Reviewed-by: Daniel Kiper <daniel.ki...@oracle.com> Daniel _______________________________________________ Grub-devel mailing list Grub-devel@gnu.org https://lists.gnu.org/mailman/listinfo/grub-devel