VirtualBox

Ignore:
Timestamp:
Mar 11, 2016 7:12:05 PM (9 years ago)
Author:
vboxsync
Message:

bs3kit: v8086, long, fixes, updates.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/ValidationKit/bootsectors/bs3kit/bs3-mode-EnteredMode.asm

    r59975 r60000  
    2727%include "bs3kit-template-header.mac"
    2828
     29%if TMPL_BITS == 16
     30BS3_EXTERN_DATA16 g_uBs3CpuDetected
     31%endif
    2932BS3_EXTERN_DATA16 g_bBs3CurrentMode
    3033TMPL_BEGIN_TEXT
     
    152155
    153156        ;
    154         ; Load ds and es.
    155         ;
    156 %ifdef TMPL_CMN_V86
     157        ; Load ds and es; clear fs and gs.
     158        ;
     159%if BS3_MODE_IS_RM_OR_V86(TMPL_MODE)
    157160        mov     ax, BS3_SEL_DATA16
    158161%else
     
    166169        push    ax
    167170        push    ax
    168 %endif
     171
     172        cmp     byte [BS3_DATA16_WRT(g_uBs3CpuDetected)], BS3CPU_80286
     173        jbe     .skip_fs_gs
     174%endif
     175        xor     ax, ax
     176        mov     fs, ax
     177        mov     gs, ax
     178.skip_fs_gs:
    169179
    170180        ;
     
    246256%endif
    247257        pop     xAX
     258%ifdef BS3_STRICT
     259        cmp     xBP, xSP
     260        je      .return_stack_ok
     261        int3
     262.return_stack_ok:
     263%endif
    248264        leave
    249265        ret
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