Because the address xxxx:yyyyyyyy is 32 bits in protected mode, I put a 48-bits address in a piece of memory and want to give indirect jmp
, here is what I wrote:
mov eax,s1
mov [address],eax
mov ax,SelectorCode32
mov [address+4],ax
jmp fword [address]
address:dd 0
dw 0
But the nasm shows that jmp fword [address]
is wrong, I've read some suggestions like this, but didn't help either, so what should I do?
JMP ptr16:32
form, but there's alsoJMP m16:32
. See your Intel or AMD manual. – Alexey Frunzejmp far [address]
should do it. Maybejmp far dword [address]
if it's not in 32-bit code. – Frank Kotler