NASM - The Netwide Assembler
NASM Forum => Programming with NASM => Topic started by: T145 on November 21, 2019, 03:50:49 AM
-
I've scoured the web trying to find any mention of enabling protected mode, to no avail. If anyone here happens to know I'd love to learn how!
-
Hi T145,
Welcome o the forum!
The net used to be full of this information. Can't find much now...
This is not a useful answer:
mov eax, cr0
or al, 1
mov cr0, eax
... now you're in protected mode. However... first you need to load a global descriptor table. This is an array of selectors. The format if these selectors must be for the convenience if the hardware - it sure isn't for the convenience if programmers!
I used to have examples up until about two years ago when my computer crashed with no recent backup. Older backup is on CD... and the new machine has no CD player. So I can't help you much.
I'll look more...
Best,
Frank
-
I assume that also utilizes %use altreg?
-
I don't think so, no.
Thanks for reminding me I'm supposed to be looking for an example.
Best,
Frank
not what I was looking for but try this:
http://www.osdever.net/tutorials/view/the-world-of-protected-mode