Page 2 of 2
Re: qemu keeps restarting after grub menu
Posted: Mon Aug 03, 2009 5:25 am
by leledumbo
It doesn't boot correctly. It executes random code, which happens to have you end up in main() and make it appear that it works. For the time being.
Hmm... OK. In the debug info (see previous post) Start is located at 0x10000c but it boots at 0x100000, I guess that's the problem. I should examine my linker script, I remember doing something to it a few months (or weeks) ago.
Re: qemu keeps restarting after grub menu
Posted: Mon Aug 03, 2009 9:23 am
by Firestryke31
What you might consider doing is changing "start" to "realStart" (or something similar) and then before the multiboot structure just have something like this:
Code: Select all
global start
start:
jmp realStart
;; Multiboot structure
;; realStart which was previously start
That way the code just jumps over the multiboot structure, and GRUB will still be able to find it.
Re: qemu keeps restarting after grub menu
Posted: Thu Aug 06, 2009 9:02 pm
by leledumbo
OK, it works when I rename the entry point from Start to _start. This was exactly what I've done, but perhaps I didn't recheck it after recompilation. Is this an ld limitation?