VirtualBox

Changeset 66316 in vbox for trunk


Ignore:
Timestamp:
Mar 29, 2017 1:24:53 AM (8 years ago)
Author:
vboxsync
Message:

bs3kit: Real mode #GP handler (++) fix.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/ValidationKit/bootsectors/bs3kit/bs3-c16-TrapRmV86Generic.asm

    r64529 r66316  
    6363
    6464%macro Bs3TrapRmV86GenericEntryErrCd 1
    65         push    ax                      ; 1 byte:  Save AX                              (BP(+2) + 2)
    66         mov     ax, i | 0ff00h          ; 2 bytes: AL = trap/interrupt number; AH=indicate have error code.
    67         jmp     %1                      ; 3 bytes: Jump to handler code
    68         ALIGNCODE(8)
    69 %assign i i+1
     65        Bs3TrapRmV86GenericEntryNoErr %1    ; No error code pushed in real mode or V86 mode.
    7066%endmacro
    7167
     
    113109; Trap or interrupt with error code, faked if necessary.
    114110;
     111; early 386+ stack (movzx ebp, sp):
     112;       [bp + 000h]     ebp
     113;       [bp + 004h]     ax
     114;       [bp + 006h]     errcd                   [bp'+0] <--- bp at jmp to common code.
     115;       [bp + 008h]     cs                      [bp'+2]
     116;       [bp + 00ah]     ip                      [bp'+4]
     117;       [bp + 00ch]     flags                   [bp'+6]
     118;      ([bp + 00eh]     post-iret sp value)     [bp'+8]
     119;
    115120BS3_PROC_BEGIN _bs3TrapRmV86GenericTrapOrInt
    116121BS3_PROC_BEGIN bs3TrapRmV86GenericTrapOrInt
     
    160165        test    ah, 0ffh
    161166        jz      .no_error_code
    162 ;; @todo Do voodoo checks for 'int xx' or misguided hardware interrupts.
    163167        mov     dx, [bp + 6]
    164168        mov     [ss:bx + BS3TRAPFRAME.uErrCd], dx
     
    211215        test    ah, 0ffh
    212216        jz      .no_error_code
    213 ;; @todo Do voodoo checks for 'int xx' or misguided hardware interrupts.
    214217        mov     dx, [bp + 4]
    215218        mov     [ss:bx + BS3TRAPFRAME.uErrCd], dx
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette