Mail Archives: djgpp/1998/02/07/01:31:18
At 12:04 2/4/1998 +0100, JAP wrote:
>Hi.
>I tried to call the int 21H under inline asm from gcc and i got the program
>fall. It caused an internal protection fault under win95.
That's true. I believe this is caused by the distinction between protected
mode and real mode interrupts.
>I want to know if it can be possible to call this interrupt or it's
>impossible under protected mode.
The easiest way is to do it from C and call the `__dpmi_int' function. This
corresponds to an INT 31h DPMI function in assembly, I think the libc docs
and the DPMI spec can tell you more if necessary.
>Another question is if these lines is correct:
>movw $0x7, %%ax;
>shl $8, %%ax;
>because I can't make anything with AH
Really? Doesn't this work?
movb $0x7, %%ah
>and I wonder I I can shift 8 bits to
>the left and then AH=7 and AL=0 after I make the shift.
Sure.
shlw $8, %%ax
Nate Eldredge
eldredge AT ap DOT net
- Raw text -