Page 2 of 2
Re: Home made MBR doesn't load windows
Posted: Tue Nov 11, 2014 2:28 pm
by madanra
I just tried my MBR, which only stores the pointer in ds:si, and it boots Windows 7 fine. So that's not the issue - at least, it's not the only issue.
Edit: I've tried various things to break my MBR now:
- Setting si and bp to point at junk
- Relocating the MBR to a non-standard place
- Setting the stack to just above the VBR so there's not much stack space
- Jumping to 0x07c0:0x0000 instead of 0x0000:0x7c00
- Changing the in-memory copy of the disk signature
None of which made any difference to Windows - it still booted fine. So oddly enough, it looks like it doesn't even look at the partition data you give it - maybe it re-reads in the MBR and looks for an active partition?
Changing dl to an incorrect value did result in a failed boot, but earlier than the problem Dren is having. So I'm stumped...
Re: Home made MBR doesn't load windows
Posted: Tue Nov 11, 2014 5:05 pm
by Dren
madanra wrote:I just tried my MBR, which only stores the pointer in ds:si, and it boots Windows 7 fine. So that's not the issue - at least, it's not the only issue.
Changing dl to an incorrect value did result in a failed boot, but earlier than the problem Dren is having. So I'm stumped...
This is a good news, can I ask you to assemble my mbr (using the code in my second post) and try to boot your windows 7 with it?
It is written for nasm
Re: Home made MBR doesn't load windows
Posted: Wed Nov 12, 2014 1:54 am
by madanra
Dren wrote:This is a good news, can I ask you to assemble my mbr (using the code in my second post) and try to boot your windows 7 with it?
It is written for nasm
Sure - I won't have a chance today, but should do tomorrow.
Re: Home made MBR doesn't load windows
Posted: Thu Nov 13, 2014 7:04 am
by Dren
madanra wrote:Sure - I won't have a chance today, but should do tomorrow.
No problem, thank you very much!
Re: Home made MBR doesn't load windows
Posted: Thu Nov 13, 2014 12:42 pm
by madanra
When I ran your MBR, it tried to do an LBA read with a 64-bit address, which VirtualBox doesn't support (see screenshot), because
is still a 16-bit push, not a 32-bit push, and nasm doesn't complain because 0 fits in 16 bits. I changed it to
and then it booted Windows 7 fine. Have you checked that your copy of Windows boots correctly when a normal MBR is used?
Re: Home made MBR doesn't load windows
Posted: Fri Nov 14, 2014 7:55 pm
by Dren
I was probably using a bad installation of windows, with original mbr after some seconds of boot it crashed with a blue screen (lol), but didn't show Windows Boot Manager, i could see windows boot logo (flag) and then the blue screen
Tomorrw i'll try with windows vista
Thank you very much for confirm that by mbr works with windows 7