VirtualBox

Changeset 54449 in vbox


Ignore:
Timestamp:
Feb 24, 2015 2:54:42 PM (10 years ago)
Author:
vboxsync
Message:

Runtime/testcase: rename tstR0Preemption to tstRTR0Preemption to match the rest of the testcases.

Location:
trunk/src/VBox/Runtime/testcase
Files:
1 edited
3 moved

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Runtime/testcase/Makefile.kmk

    r54398 r54449  
    178178        tstRTR0SemMutexDriverHardened \
    179179        tstRTR0TimerDriverHardened \
    180         tstR0ThreadPreemptionDriverHardened \
     180        tstRTR0ThreadPreemptionDriverHardened \
    181181        tstRTR0ThreadDriverHardened
    182182  DLLS     += \
     
    184184        tstRTR0SemMutexDriver \
    185185        tstRTR0TimerDriver \
    186         tstR0ThreadPreemptionDriver \
     186        tstRTR0ThreadPreemptionDriver \
    187187        tstRTR0ThreadDriver
    188188 else
     
    191191        tstRTR0SemMutexDriver \
    192192        tstRTR0TimerDriver \
    193         tstR0ThreadPreemptionDriver \
     193        tstRTR0ThreadPreemptionDriver \
    194194        tstRTR0ThreadDriver
    195195 endif
     
    199199        tstRTR0SemMutex \
    200200        tstRTR0Timer \
    201         tstR0ThreadPreemption \
     201        tstRTR0ThreadPreemption \
    202202        tstRTR0Thread
    203203 ifdef VBOX_WITH_RAW_MODE
     
    762762
    763763
    764 tstR0ThreadPreemption_TEMPLATE = VBoxR0
    765 tstR0ThreadPreemption_INST = $(INST_TESTCASE)
    766 tstR0ThreadPreemption_DEFS = IN_RT_R0
    767 tstR0ThreadPreemption_SYSSUFF = .r0
    768 tstR0ThreadPreemption_SOURCES = tstR0ThreadPreemption.cpp
    769 tstR0ThreadPreemption_LIBS = $(PATH_STAGE_LIB)/RuntimeR0$(VBOX_SUFF_LIB)
     764tstRTR0ThreadPreemption_TEMPLATE = VBoxR0
     765tstRTR0ThreadPreemption_INST = $(INST_TESTCASE)
     766tstRTR0ThreadPreemption_DEFS = IN_RT_R0
     767tstRTR0ThreadPreemption_SYSSUFF = .r0
     768tstRTR0ThreadPreemption_SOURCES = tstRTR0ThreadPreemption.cpp
     769tstRTR0ThreadPreemption_LIBS = $(PATH_STAGE_LIB)/RuntimeR0$(VBOX_SUFF_LIB)
    770770if1of ($(VBOX_LDR_FMT), pe lx)
    771  tstR0ThreadPreemption_LIBS += $(PATH_STAGE_LIB)/SUPR0$(VBOX_SUFF_LIB)
     771 tstRTR0ThreadPreemption_LIBS += $(PATH_STAGE_LIB)/SUPR0$(VBOX_SUFF_LIB)
    772772endif
    773773if defined(VBOX_WITH_HARDENING) && "$(KBUILD_TARGET)" == "win"
    774  tstR0ThreadPreemptionDriverHardened_TEMPLATE = VBoxR3HardenedTstExe
    775  tstR0ThreadPreemptionDriverHardened_NAME = tstR0ThreadPreemptionDriver
    776  tstR0ThreadPreemptionDriverHardened_DEFS = PROGRAM_NAME_STR=\"tstR0ThreadPreemptionDriver\"
    777  tstR0ThreadPreemptionDriverHardened_SOURCES = ../../HostDrivers/Support/SUPR3HardenedMainTemplate.cpp
    778  tstR0ThreadPreemptionDriver_TEMPLATE = VBoxR3TstDll
     774 tstRTR0ThreadPreemptionDriverHardened_TEMPLATE = VBoxR3HardenedTstExe
     775 tstRTR0ThreadPreemptionDriverHardened_NAME = tstRTR0ThreadPreemptionDriver
     776 tstRTR0ThreadPreemptionDriverHardened_DEFS = PROGRAM_NAME_STR=\"tstRTR0ThreadPreemptionDriver\"
     777 tstRTR0ThreadPreemptionDriverHardened_SOURCES = ../../HostDrivers/Support/SUPR3HardenedMainTemplate.cpp
     778 tstRTR0ThreadPreemptionDriver_TEMPLATE = VBoxR3TstDll
    779779else
    780  tstR0ThreadPreemptionDriver_TEMPLATE = VBOXR3TSTEXE
    781 endif
    782 tstR0ThreadPreemptionDriver_SOURCES = tstR0ThreadPreemptionDriver.cpp
     780 tstRTR0ThreadPreemptionDriver_TEMPLATE = VBOXR3TSTEXE
     781endif
     782tstRTR0ThreadPreemptionDriver_SOURCES = tstRTR0ThreadPreemptionDriver.cpp
    783783
    784784
  • trunk/src/VBox/Runtime/testcase/tstRTR0ThreadPreemption.cpp

    r54436 r54449  
    55
    66/*
    7  * Copyright (C) 2009-2013 Oracle Corporation
     7 * Copyright (C) 2009-2015 Oracle Corporation
    88 *
    99 * This file is part of VirtualBox Open Source Edition (OSE), as
     
    3636#include <iprt/string.h>
    3737#include <VBox/sup.h>
    38 #include "tstR0ThreadPreemption.h"
     38#include "tstRTR0ThreadPreemption.h"
    3939
    4040
     
    181181    switch (uOperation)
    182182    {
    183         case TSTR0THREADPREMEPTION_SANITY_OK:
    184             break;
    185 
    186         case TSTR0THREADPREMEPTION_SANITY_FAILURE:
     183        case TSTRTR0THREADPREEMPTION_SANITY_OK:
     184            break;
     185
     186        case TSTRTR0THREADPREEMPTION_SANITY_FAILURE:
    187187            RTStrPrintf(pszErr, cchErr, "!42failure42%1024s", "");
    188188            break;
    189189
    190         case TSTR0THREADPREMEPTION_BASIC:
     190        case TSTRTR0THREADPREEMPTION_BASIC:
    191191        {
    192192            if (!ASMIntAreEnabled())
     
    207207        }
    208208
    209         case TSTR0THREADPREMEPTION_IS_TRUSTY:
     209        case TSTRTR0THREADPREEMPTION_IS_TRUSTY:
    210210            if (!RTThreadPreemptIsPendingTrusty())
    211211                RTStrPrintf(pszErr, cchErr, "!Untrusty");
    212212            break;
    213213
    214         case TSTR0THREADPREMEPTION_IS_PENDING:
     214        case TSTRTR0THREADPREEMPTION_IS_PENDING:
    215215        {
    216216            RTTHREADPREEMPTSTATE State = RTTHREADPREEMPTSTATE_INITIALIZER;
     
    259259        }
    260260
    261         case TSTR0THREADPREMEPTION_NESTED:
     261        case TSTRTR0THREADPREEMPTION_NESTED:
    262262        {
    263263            bool const fDefault = RTThreadPreemptIsEnabled(NIL_RTTHREAD);
     
    294294        }
    295295
    296         case TSTR0THREADPREEMPTION_CTXHOOKS:
     296        case TSTRTR0THREADPREEMPTION_CTXHOOKS:
    297297        {
    298298            if (!RTThreadPreemptIsEnabled(NIL_RTTHREAD))
  • trunk/src/VBox/Runtime/testcase/tstRTR0ThreadPreemption.h

    r54436 r54449  
    55
    66/*
    7  * Copyright (C) 2009-2013 Oracle Corporation
     7 * Copyright (C) 2009-2015 Oracle Corporation
    88 *
    99 * This file is part of VirtualBox Open Source Edition (OSE), as
     
    2727#ifdef IN_RING0
    2828RT_C_DECLS_BEGIN
    29 DECLEXPORT(int) TSTR0ThreadPreemptionSrvReqHandler(PSUPDRVSESSION pSession, uint32_t uOperation,
    30                                                    uint64_t u64Arg, PSUPR0SERVICEREQHDR pReqHdr);
     29DECLEXPORT(int) TSTRTR0ThreadPreemptionSrvReqHandler(PSUPDRVSESSION pSession, uint32_t uOperation,
     30                                                     uint64_t u64Arg, PSUPR0SERVICEREQHDR pReqHdr);
    3131RT_C_DECLS_END
    3232#endif
    3333
    34 typedef enum TSTR0THREADPREMEPTION
     34typedef enum TSTRTR0THREADPREEMPTION
    3535{
    36     TSTR0THREADPREMEPTION_SANITY_OK = 1,
    37     TSTR0THREADPREMEPTION_SANITY_FAILURE,
    38     TSTR0THREADPREMEPTION_BASIC,
    39     TSTR0THREADPREMEPTION_IS_TRUSTY,
    40     TSTR0THREADPREMEPTION_IS_PENDING,
    41     TSTR0THREADPREMEPTION_NESTED,
    42     TSTR0THREADPREEMPTION_CTXHOOKS
    43 } TSTR0THREADPREMEPTION;
     36    TSTRTR0THREADPREEMPTION_SANITY_OK = 1,
     37    TSTRTR0THREADPREEMPTION_SANITY_FAILURE,
     38    TSTRTR0THREADPREEMPTION_BASIC,
     39    TSTRTR0THREADPREEMPTION_IS_TRUSTY,
     40    TSTRTR0THREADPREEMPTION_IS_PENDING,
     41    TSTRTR0THREADPREEMPTION_NESTED,
     42    TSTRTR0THREADPREEMPTION_CTXHOOKS
     43} TSTRTR0THREADPREEMPTION;
    4444
  • trunk/src/VBox/Runtime/testcase/tstRTR0ThreadPreemptionDriver.cpp

    r54436 r54449  
    55
    66/*
    7  * Copyright (C) 2009-2013 Oracle Corporation
     7 * Copyright (C) 2009-2015 Oracle Corporation
    88 *
    99 * This file is part of VirtualBox Open Source Edition (OSE), as
     
    4242#ifdef VBOX
    4343# include <VBox/sup.h>
    44 # include "tstR0ThreadPreemption.h"
     44# include "tstRTR0ThreadPreemption.h"
    4545#endif
    4646
     
    8888     */
    8989    RTTEST hTest;
    90     int rc = RTTestInitAndCreate("tstR0ThreadPreemption", &hTest);
     90    int rc = RTTestInitAndCreate("tstRTR0ThreadPreemption", &hTest);
    9191    if (rc)
    9292        return rc;
     
    104104    rc = RTPathExecDir(szPath, sizeof(szPath));
    105105    if (RT_SUCCESS(rc))
    106         rc = RTPathAppend(szPath, sizeof(szPath), "tstR0ThreadPreemption.r0");
     106        rc = RTPathAppend(szPath, sizeof(szPath), "tstRTR0ThreadPreemption.r0");
    107107    if (RT_FAILURE(rc))
    108108    {
     
    112112
    113113    void *pvImageBase;
    114     rc = SUPR3LoadServiceModule(szPath, "tstR0ThreadPreemption",
    115                                 "TSTR0ThreadPreemptionSrvReqHandler",
     114    rc = SUPR3LoadServiceModule(szPath, "tstRTR0ThreadPreemption",
     115                                "TSTRTR0ThreadPreemptionSrvReqHandler",
    116116                                &pvImageBase);
    117117    if (RT_FAILURE(rc))
     
    135135    Req.Hdr.cbReq = sizeof(Req);
    136136    Req.szMsg[0] = '\0';
    137     RTTESTI_CHECK_RC(rc = SUPR3CallR0Service("tstR0ThreadPreemption", sizeof("tstR0ThreadPreemption") - 1,
    138                                              TSTR0THREADPREMEPTION_SANITY_OK, 0, &Req.Hdr), VINF_SUCCESS);
     137    RTTESTI_CHECK_RC(rc = SUPR3CallR0Service("tstRTR0ThreadPreemption", sizeof("tstRTR0ThreadPreemption") - 1,
     138                                             TSTRTR0THREADPREEMPTION_SANITY_OK, 0, &Req.Hdr), VINF_SUCCESS);
    139139    if (RT_FAILURE(rc))
    140140        return RTTestSummaryAndDestroy(hTest);
     
    146146    Req.Hdr.cbReq = sizeof(Req);
    147147    Req.szMsg[0] = '\0';
    148     RTTESTI_CHECK_RC(rc = SUPR3CallR0Service("tstR0ThreadPreemption", sizeof("tstR0ThreadPreemption") - 1,
    149                                              TSTR0THREADPREMEPTION_SANITY_FAILURE, 0, &Req.Hdr), VINF_SUCCESS);
     148    RTTESTI_CHECK_RC(rc = SUPR3CallR0Service("tstRTR0ThreadPreemption", sizeof("tstRTR0ThreadPreemption") - 1,
     149                                             TSTRTR0THREADPREEMPTION_SANITY_FAILURE, 0, &Req.Hdr), VINF_SUCCESS);
    150150    if (RT_FAILURE(rc))
    151151        return RTTestSummaryAndDestroy(hTest);
     
    161161    Req.Hdr.cbReq = sizeof(Req);
    162162    Req.szMsg[0] = '\0';
    163     RTTESTI_CHECK_RC(rc = SUPR3CallR0Service("tstR0ThreadPreemption", sizeof("tstR0ThreadPreemption") - 1,
    164                                              TSTR0THREADPREMEPTION_BASIC, 0, &Req.Hdr), VINF_SUCCESS);
     163    RTTESTI_CHECK_RC(rc = SUPR3CallR0Service("tstRTR0ThreadPreemption", sizeof("tstRTR0ThreadPreemption") - 1,
     164                                             TSTRTR0THREADPREEMPTION_BASIC, 0, &Req.Hdr), VINF_SUCCESS);
    165165    if (RT_FAILURE(rc))
    166166        return RTTestSummaryAndDestroy(hTest);
     
    180180    Req.Hdr.cbReq = sizeof(Req);
    181181    Req.szMsg[0] = '\0';
    182     RTTESTI_CHECK_RC(rc = SUPR3CallR0Service("tstR0ThreadPreemption", sizeof("tstR0ThreadPreemption") - 1,
    183                                              TSTR0THREADPREMEPTION_IS_TRUSTY, 0, &Req.Hdr), VINF_SUCCESS);
     182    RTTESTI_CHECK_RC(rc = SUPR3CallR0Service("tstRTR0ThreadPreemption", sizeof("tstRTR0ThreadPreemption") - 1,
     183                                             TSTRTR0THREADPREEMPTION_IS_TRUSTY, 0, &Req.Hdr), VINF_SUCCESS);
    184184    if (RT_FAILURE(rc))
    185185        return RTTestSummaryAndDestroy(hTest);
     
    212212        Req.Hdr.cbReq = sizeof(Req);
    213213        Req.szMsg[0] = '\0';
    214         RTTESTI_CHECK_RC(rc = SUPR3CallR0Service("tstR0ThreadPreemption", sizeof("tstR0ThreadPreemption") - 1,
    215                                                  TSTR0THREADPREMEPTION_IS_PENDING, 0, &Req.Hdr), VINF_SUCCESS);
     214        RTTESTI_CHECK_RC(rc = SUPR3CallR0Service("tstRTR0ThreadPreemption", sizeof("tstRTR0ThreadPreemption") - 1,
     215                                                 TSTRTR0THREADPREEMPTION_IS_PENDING, 0, &Req.Hdr), VINF_SUCCESS);
    216216        if (    strcmp(Req.szMsg, "!cLoops=1\n")
    217217            ||  i >= 64)
     
    241241    Req.Hdr.cbReq = sizeof(Req);
    242242    Req.szMsg[0] = '\0';
    243     RTTESTI_CHECK_RC(rc = SUPR3CallR0Service("tstR0ThreadPreemption", sizeof("tstR0ThreadPreemption") - 1,
    244                                              TSTR0THREADPREMEPTION_NESTED, 0, &Req.Hdr), VINF_SUCCESS);
     243    RTTESTI_CHECK_RC(rc = SUPR3CallR0Service("tstRTR0ThreadPreemption", sizeof("tstRTR0ThreadPreemption") - 1,
     244                                             TSTRTR0THREADPREEMPTION_NESTED, 0, &Req.Hdr), VINF_SUCCESS);
    245245    if (Req.szMsg[0] == '!')
    246246        RTTestIFailed("%s", &Req.szMsg[1]);
     
    261261        Req.Hdr.cbReq = sizeof(Req);
    262262        Req.szMsg[0] = '\0';
    263         RTTESTI_CHECK_RC(rc = SUPR3CallR0Service("tstR0ThreadPreemption", sizeof("tstR0ThreadPreemption") - 1,
    264                                                  TSTR0THREADPREEMPTION_CTXHOOKS, 0, &Req.Hdr), VINF_SUCCESS);
     263        RTTESTI_CHECK_RC(rc = SUPR3CallR0Service("tstRTR0ThreadPreemption", sizeof("tstRTR0ThreadPreemption") - 1,
     264                                                 TSTRTR0THREADPREEMPTION_CTXHOOKS, 0, &Req.Hdr), VINF_SUCCESS);
    265265        if (RT_FAILURE(rc))
    266266            return RTTestSummaryAndDestroy(hTest);
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