Hi.
I'm working on a small operating system, my problem is that my OS only works whit 16 bit code and not registers that are 32 bit (like eax, ebx...).
I made up a pretty good boot loader in 16 bit that loads my kernel.
I want my kernel to change from "Real mode" to "Protected mode". So I search for it and found this code:
OK so my problem here is that the assembler I'm using(NASM) gives my two error lines:
kernel.asm:59: error: invalid combination of opcode and operands
kernel.asm:61: error: invalid combination of opcode and operands
thanks in advance.
I'm working on a small operating system, my problem is that my OS only works whit 16 bit code and not registers that are 32 bit (like eax, ebx...).
I made up a pretty good boot loader in 16 bit that loads my kernel.
I want my kernel to change from "Real mode" to "Protected mode". So I search for it and found this code:
Code
mov ax, cr0 ; Moves the value
or ax, 1 ; changes bit 1
mov cr0, axkernel.asm:59: error: invalid combination of opcode and operands
kernel.asm:61: error: invalid combination of opcode and operands
thanks in advance.
