VirtualBox

Changeset 96912 in vbox for trunk/src/VBox/ValidationKit


Ignore:
Timestamp:
Sep 28, 2022 9:03:23 AM (2 years ago)
Author:
vboxsync
Message:

ValKit/bs3-apic-1: Extended it with some TPR writes & read-back testing and checking the version. bugref:10092

Location:
trunk/src/VBox/ValidationKit/bootsectors
Files:
1 added
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/ValidationKit/bootsectors/Makefile.kmk

    r96407 r96912  
    249249        bs3kit/bs3-first-rm.asm \
    250250        bs3-apic-1.c \
     251        bs3-apic-1-32.c32
    251252
    252253
  • trunk/src/VBox/ValidationKit/bootsectors/bs3-apic-1.c

    r96407 r96912  
    4444
    4545
     46/*********************************************************************************************************************************
     47*   Internal Functions                                                                                                           *
     48*********************************************************************************************************************************/
     49BS3_DECL_CALLBACK(void)     ProtModeApicTests(void);
     50
     51
    4652BS3_DECL(void) Main_rm()
    4753{
     
    4955    Bs3TestInit("bs3-apic-1");
    5056    Bs3TestPrintf("g_uBs3CpuDetected=%#x\n", g_uBs3CpuDetected);
     57    Bs3TestSub("real-mode");
    5158
    5259    /*
     
    6673                      uApicBase,
    6774                      uApicBase & MSR_IA32_APICBASE_EN ? "enabled" : "disabled",
    68                       uApicBase & MSR_IA32_APICBASE_EXTD ? "bootstrap" : "slave",
     75                      uApicBase & MSR_IA32_APICBASE_BSP ? "bootstrap" : "slave",
    6976                      uApicBase & MSR_IA32_APICBASE_EXTD ? ", x2apic" : "",
    7077                      (uApicBase & X86_PAGE_4K_BASE_MASK) == MSR_IA32_APICBASE_ADDR ? ", !non-default address!" : "");
     
    8390        uApicBase2 = ASMRdMsr(MSR_IA32_APICBASE);
    8491        if (uApicBase2 == (uApicBase | MSR_IA32_APICBASE_EN))
     92        {
    8593            Bs3TestPrintf("Enabling worked.\n");
     94
     95            /*
     96             * Do the rest of the testing in protected mode since we cannot
     97             * (easily) access the APIC address from real mode.
     98             */
     99            Bs3SwitchTo32BitAndCallC_rm(ProtModeApicTests, 0);
     100        }
    86101        else
    87102            Bs3TestFailedF("Enabling the APIC did not work (%#RX64)", uApicBase2);
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