Switching from PMode to Real Mode

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
Matt

Switching from PMode to Real Mode

Post by Matt »

Could somebody give me the ASM code to switch from protected mode to real mode? All the stuff I could find in the internet about doing that makes no sense to me :-/
[glow=green,2,300]Thanks :D[/glow]
crazybuddha

Re:Switching from PMode to Real Mode

Post by crazybuddha »

mov eax,cr0
or al,1
mov cr0,eax
matt

Re:Switching from PMode to Real Mode

Post by matt »

crazybuddha wrote:
mov eax,cr0
or al,1
mov cr0,eax
frank

Re:Switching from PMode to Real Mode

Post by frank »

that is switching back .. (are you sure, you switched from realmode to pmode before?)

mov eax,cr0
or al,0
mov cr0,eax

and ofcourse do some otherstuff (don't know what, I don't have more than 1 mb of gig for nothing :P) -- search on the internet
Post Reply