Follow-up Comment #12, bug #46817 (project grub):

I think it's a bug in BIOS. I tried to allocate 20MB buffer after
grub_machine_init() and now GRUB2 works. So I zero-filled part of this buffer
to get the exact address which can't be clobbered. That address is 0x9c251da8
which is declared as available by BIOS. I have dumped 160 bytes after that
address and disassembled it, it's x86-64 code.

My memory map from Linux's dmesg (Result from GRUB's lsmmap matches with
this.):
[    0.000000] BIOS-e820: [mem 0x0000000000000000-0x000000000009d7ff] usable
[    0.000000] BIOS-e820: [mem 0x000000000009d800-0x000000000009ffff]
reserved
[    0.000000] BIOS-e820: [mem 0x00000000000e0000-0x00000000000fffff]
reserved
[    0.000000] BIOS-e820: [mem 0x0000000000100000-0x000000009ce3efff] usable
[    0.000000] BIOS-e820: [mem 0x000000009ce3f000-0x000000009cebefff]
reserved
[    0.000000] BIOS-e820: [mem 0x000000009cebf000-0x000000009cfbefff] ACPI
NVS
[    0.000000] BIOS-e820: [mem 0x000000009cfbf000-0x000000009cffefff] ACPI
data
[    0.000000] BIOS-e820: [mem 0x000000009cfff000-0x000000009cffffff] usable
[    0.000000] BIOS-e820: [mem 0x000000009d000000-0x000000009f9fffff]
reserved
[    0.000000] BIOS-e820: [mem 0x00000000e0000000-0x00000000efffffff]
reserved
[    0.000000] BIOS-e820: [mem 0x00000000feb00000-0x00000000feb03fff]
reserved
[    0.000000] BIOS-e820: [mem 0x00000000fec00000-0x00000000fec00fff]
reserved
[    0.000000] BIOS-e820: [mem 0x00000000fed10000-0x00000000fed19fff]
reserved
[    0.000000] BIOS-e820: [mem 0x00000000fed1c000-0x00000000fed1ffff]
reserved
[    0.000000] BIOS-e820: [mem 0x00000000fee00000-0x00000000fee00fff]
reserved
[    0.000000] BIOS-e820: [mem 0x00000000ffd80000-0x00000000ffffffff]
reserved
[    0.000000] BIOS-e820: [mem 0x0000000100000000-0x000000035fdfffff] usable


    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?46817>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/


_______________________________________________
Bug-grub mailing list
Bug-grub@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-grub

Reply via email to