Implement an int19 hook (from Japheth's JEMFBHLP.ASM).
git-svn-id: https://svn.code.sf.net/p/freedos/svn/kernel/trunk@1326 6ac86273-5f31-0410-b378-82cca8765d1b
This commit is contained in:
parent
dc840d98f4
commit
eeef2f7efd
@ -189,6 +189,25 @@ reloc_call_int6_handler:
|
||||
mov si,invalid_opcode_message
|
||||
jmp short zero_message_loop
|
||||
|
||||
global reloc_call_int19_handler
|
||||
reloc_call_int19_handler:
|
||||
; from Japheth's public domain code (JEMFBHLP.ASM)
|
||||
; restores int 10,13,15,19,1b and then calls the original int 19.
|
||||
cld
|
||||
xor ax,ax
|
||||
mov es,ax
|
||||
mov al,70h
|
||||
mov ds,ax
|
||||
mov si,100h
|
||||
mov cx,5
|
||||
nextitem: lodsb
|
||||
mov di,ax
|
||||
shl di,2
|
||||
movsw
|
||||
movsw
|
||||
loop nextitem
|
||||
int 19h
|
||||
|
||||
;
|
||||
; Terminate the current process
|
||||
;
|
||||
|
@ -200,6 +200,7 @@ VOID ASMCFUNC FAR int21_entry(iregs UserRegs);
|
||||
VOID ASMCFUNC int21_service(iregs far * r);
|
||||
VOID ASMCFUNC FAR int0_handler(void);
|
||||
VOID ASMCFUNC FAR int6_handler(void);
|
||||
VOID ASMCFUNC FAR int19_handler(void);
|
||||
VOID ASMCFUNC FAR empty_handler(void);
|
||||
VOID ASMCFUNC FAR int20_handler(void);
|
||||
VOID ASMCFUNC FAR int21_handler(void);
|
||||
|
@ -844,6 +844,11 @@ _int0_handler: jmp 0:reloc_call_int0_handler
|
||||
_int6_handler: jmp 0:reloc_call_int6_handler
|
||||
call near forceEnableA20
|
||||
|
||||
global _int19_handler
|
||||
extern reloc_call_int19_handler
|
||||
_int19_handler: jmp 0:reloc_call_int19_handler
|
||||
call near forceEnableA20
|
||||
|
||||
global _cpm_entry
|
||||
extern reloc_call_cpm_entry
|
||||
_cpm_entry: jmp 0:reloc_call_cpm_entry
|
||||
|
@ -239,6 +239,7 @@ STATIC void setup_int_vectors(void)
|
||||
{ 0x1, FP_OFF(empty_handler) }, /* single step */
|
||||
{ 0x3, FP_OFF(empty_handler) }, /* debug breakpoint */
|
||||
{ 0x6, FP_OFF(int6_handler) }, /* invalid opcode */
|
||||
{ 0x19, FP_OFF(int19_handler) },
|
||||
{ 0x20, FP_OFF(int20_handler) },
|
||||
{ 0x21, FP_OFF(int21_handler) },
|
||||
{ 0x22, FP_OFF(int22_handler) },
|
||||
|
Loading…
Reference in New Issue
Block a user