A20 Address line - XMS issue
Hello.
Quoted 1 line · Bart Oldeman
IIRC himem uses Big Real Mode for the 386, LOADALL for the 286
Yes, but 286 is a bit out of
the scope:)
Quoted 2 lines
and int15
if (BRM/LOADALL) fails.
It checks the PE bit of cr0 before trying BRM, and if it is set, it does int15/ah=0x87:
---
smsw ax shr ax, 1 ; Protected mode? jc MEM3_MoveBlock ; if so, use int 15h
---
However int15/87h executes in protected mode and requires a pointer to GDT as a parameter, so again, I have a very big doubts it can work in v86:
---
; MEM3_MoveBlock
; Set up GDT and call int 15h Move Block
[]
mov ah, 87h ; Block Move - Assumes protect int 15h ; mode code will allow interrupts
---
So again, whoever hooks int15, must either have a ring0 access to set up the GDTR for that GDT or, probably, it is also possible to just evaluate the necessary addresses from that GDT and do the transfer from within the ring3 (taking into an account also bases, access rights and all the other info from that GDT) but then who told that this can't work under cpu-emu?:)
Quoted 4 lines · Stas Sergeev
However int15/87h executes in protected
mode and requires a pointer to GDT as
a parameter, so again, I have a very big
doubts it can work in v86:
What I meant is that DOSEMU itself could do int15/87h. It would just have some virtualized raw extended memory where this function copies to/from.
The GDT that ES:SI points to would just be used as a block of information, rather than as a real GDT.
int15/87 now simply does:
else { /* AH = 0x87 */
x_printf("XMS int 15 block move failed AX=0x%04x\n", (u_short)REG(eax));
LWORD(eax) &= 0xFF;
HI(ax) = 3; /* say A20 gate failed */
CARRY;
}Bart