trying 0x80 syscall interrupt, but getting gpf instead
Posted: Mon Aug 17, 2020 2:19 am
I have my interrupt table set up, ready to try
I am doing this in kernel mode ... basically, it is just doing syscall without doing it from user space...
when I do it, I got gpf, here is the transcript/
Code: Select all
asm("int $0x80;")
when I do it, I got gpf, here is the transcript/
Code: Select all
(0).[1244325120] [0x0000000000100170] 0008:0000000000100170 (unk. ctxt): mov eax, 0x00000000 ; b800000000
Next at t=1244325121
(0) [0x0000000000100175] 0008:0000000000100175 (unk. ctxt): int 0x80 ; cd80
<bochs:8>
(0).[1244325121] [0x0000000000100175] 0008:0000000000100175 (unk. ctxt): int 0x80 ; cd80
CPU 0: Interrupt 0x80 occured (error_code=0x0000)
(0).[1244325122] [0x0000000000000000] 0008:0000000000000000 (unk. ctxt): push ebx ; 53
(0).[1244325123] [0x0000000000000001] 0008:0000000000000001 (unk. ctxt): inc dword ptr ds:[eax] ; ff00
(0).[1244325124] [0x0000000000000003] 0008:0000000000000003 (unk. ctxt): lock push ebx ; f053
CPU 0: Exception 0x06 - (#UD) undefined opcode occured (error_code=0x0000)
CPU 0: Interrupt 0x06 occured (error_code=0x0000)
(0).[1244325125] [0x00000000001013b0] 0008:00000000001013b0 (unk. ctxt): cli ; fa
(0).[1244325126] [0x00000000001013b1] 0008:00000000001013b1 (unk. ctxt): push 0x00000000 ; 6a00
(0).[1244325127] [0x00000000001013b3] 0008:00000000001013b3 (unk. ctxt): push 0x00000006