VirtualBox

Changeset 27800 in vbox


Ignore:
Timestamp:
Mar 29, 2010 7:56:26 PM (15 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
59459
Message:

iprt: applying sparc patch (selectively).

Location:
trunk/src/VBox/Runtime
Files:
7 edited

Legend:

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

    r27743 r27800  
    368368        generic/RTLogWriteStdOut-generic.cpp \
    369369        generic/RTLogWriteUser-generic.cpp \
    370         generic/RTMpGetDescription-generic.cpp \
    371370        generic/RTTimerLRCreate-generic.cpp \
    372371        generic/mempool-generic.cpp \
     
    396395 RuntimeR3_SOURCES += common/time/timesupref.cpp
    397396#endif
     397
     398RuntimeR3_SOURCES.x86 += \
     399        generic/RTMpGetDescription-generic-stub.cpp
     400RuntimeR3_SOURCES.amd64 += \
     401        generic/RTMpGetDescription-generic-stub.cpp
     402RuntimeR3_SOURCES.sparc32 += \
     403        generic/RTMpGetDescription-generic.cpp
     404RuntimeR3_SOURCES.sparc64 += \
     405        generic/RTMpGetDescription-generic.cpp
    398406
    399407ifdef IPRT_WITH_LZJB
     
    744752        r3/solaris/alloc-solaris.cpp \
    745753        r3/solaris/mp-solaris.cpp \
    746         r3/solaris/RTSystemQueryDmiString-solaris.cpp \
    747754        r3/solaris/rtProcInitExePath-solaris.cpp
     755RuntimeR3_SOURCES.solaris.amd64 = \
     756        r3/solaris/RTSystemQueryDmiString-solaris.cpp
     757RuntimeR3_SOURCES.solaris.x86 = \
     758        r3/solaris/RTSystemQueryDmiString-solaris.cpp
     759RuntimeR3_SOURCES.solaris.sparc32 = \
     760        generic/RTSystemQueryDmiString-generic.cpp
     761RuntimeR3_SOURCES.solaris.sparc64 = \
     762        generic/RTSystemQueryDmiString-generic.cpp
    748763
    749764## PORTME: Porters add their selection of platform specific files for Ring-3 here.
     
    962977#
    963978VBoxRT_TEMPLATE                = VBoxR3Dll
    964 VBoxRT_SDKS                    = VBOX_OPENSSL VBOX_LIBXML2 VBOX_LIBCURL VBOX_BOOST
     979VBoxRT_SDKS                    = VBOX_OPENSSL VBOX_LIBXML2 VBOX_BOOST
     980ifdef VBOX_WITH_LIBCURL
     981VBoxRT_SDKS                   += VBOX_LIBCURL
     982endif
    965983VBoxRT_SDKS.win                = WINPSDK W2K3DDK VBOX_NTDLL
    966984if1of ($(KBUILD_TARGET)$(VBOX_WITH_HARDENING), darwin win)
     
    973991        $(filter-out common/checksum/crc32.cpp, $(RuntimeR3_SOURCES))
    974992VBoxRT_SOURCES                += \
    975         common/misc/s3.cpp \
    976993        r3/xml.cpp \
    977994        common/checksum/RTSha1Digest.cpp \
     
    9841001        common/checksum/sha512.cpp \
    9851002        common/checksum/sha512str.cpp
     1003ifdef VBOX_WITH_LIBCURL
     1004 VBoxRT_SOURCES               += common/misc/s3.cpp
     1005endif
    9861006VBoxRT_SOURCES.$(KBUILD_TARGET) = $(RuntimeR3_SOURCES.$(KBUILD_TARGET))
    9871007VBoxRT_SOURCES.$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH) = $(RuntimeR3_SOURCES.$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH))
     
    10271047        rt
    10281048VBoxRT_LIBS.solaris            = \
    1029         kstat smbios
     1049        kstat
     1050ifn1of ($(KBUILD_TARGET_ARCH),sparc32 sparc64)
     1051 # SMBIOS not available on Solaris SPARC.
     1052 VBoxRT_LIBS.solaris += smbios
     1053endif
    10301054VBoxRT_LIBS.win                = \
    10311055        $(PATH_SDK_W2K3DDK_LIB)/vccomsup.lib \
  • trunk/src/VBox/Runtime/common/checksum/md5.cpp

    r22092 r27800  
    5757
    5858#include <iprt/string.h>                 /* for memcpy() */
     59#if defined(RT_BIG_ENDIAN)
     60# include <iprt/asm.h>                   /* RT_LE2H_U32 uses ASMByteSwapU32. */
     61#endif
    5962
    6063
     
    196199    uint32_t t;
    197200    do {
    198         t = *buf
     201        t = *buf;
    199202        t = RT_LE2H_U32(t);
    200203        *buf = t;
  • trunk/src/VBox/Runtime/common/log/log.cpp

    r25899 r27800  
    293293            RTLogGroupSettings(pLogger, pszGroupSettings);
    294294
     295#if defined(RT_ARCH_X86) && (!defined(LOG_USE_C99) || !defined(RT_WITHOUT_EXEC_ALLOC))
    295296        /*
    296297         * Emit wrapper code.
    297298         */
    298 #if defined(LOG_USE_C99) && defined(RT_WITHOUT_EXEC_ALLOC)
    299         pu8Code = (uint8_t *)RTMemAlloc(64);
    300 #else
    301299        pu8Code = (uint8_t *)RTMemExecAlloc(64);
    302 #endif
    303300        if (pu8Code)
    304301        {
    305302            pLogger->pfnLogger = *(PFNRTLOGGER*)&pu8Code;
    306 #if defined(RT_ARCH_AMD64) || (defined(LOG_USE_C99) && defined(RT_WITHOUT_EXEC_ALLOC))
    307             /* this wrapper will not be used on AMD64, we will be requiring C99 compilers there. */
    308             *pu8Code++ = 0xcc;
    309 #else
    310303            *pu8Code++ = 0x68;          /* push imm32 */
    311304            *(void **)pu8Code = pLogger;
     
    319312            *pu8Code++ = 0x04;
    320313            *pu8Code++ = 0xc3;          /* ret near */
    321 #endif
    322314            AssertMsg((uintptr_t)pu8Code - (uintptr_t)pLogger->pfnLogger <= 64,
    323315                      ("Wrapper assembly is too big! %d bytes\n", (uintptr_t)pu8Code - (uintptr_t)pLogger->pfnLogger));
    324 
    325 
     316            rc = VINF_SUCCESS;
     317        }
     318        else
     319        {
     320# ifdef RT_OS_LINUX
     321            if (pszErrorMsg) /* Most probably SELinux causing trouble since the larger RTMemAlloc succeeded. */
     322                RTStrPrintf(pszErrorMsg, cchErrorMsg, "mmap(PROT_WRITE | PROT_EXEC) failed -- SELinux?");
     323# endif
     324            rc = VERR_NO_MEMORY;
     325        }
     326        if (RT_SUCCESS(rc))
     327#endif /* X86 wrapper code*/
     328        {
    326329#ifdef IN_RING3 /* files and env.vars. are only accessible when in R3 at the present time. */
    327330            /*
     
    435438            RTMemExecFree(*(void **)&pLogger->pfnLogger);
    436439#endif
    437         }
    438         else
    439         {
    440 #ifdef RT_OS_LINUX
    441             /*
    442              * RTMemAlloc() succeeded but RTMemExecAlloc() failed -- most probably an SELinux problem.
    443              */
    444             if (pszErrorMsg)
    445                 RTStrPrintf(pszErrorMsg, cchErrorMsg, "mmap(PROT_WRITE | PROT_EXEC) failed -- SELinux?");
    446 #endif /* RT_OS_LINUX */
    447             rc = VERR_NO_MEMORY;
    448440        }
    449441        RTMemFree(pLogger);
  • trunk/src/VBox/Runtime/common/misc/getopt.cpp

    r26694 r27800  
    460460     * Make sure the union is completely cleared out, whatever happens below.
    461461     */
    462     pValueUnion->u64 = 0;
     462    pValueUnion->u64.value = 0;
    463463    pValueUnion->pDef = NULL;
    464464
     
    730730     * Make sure the union is completely cleared out, whatever happens below.
    731731     */
    732     pValueUnion->u64 = 0;
     732    pValueUnion->u64.value = 0;
    733733    pValueUnion->pDef = NULL;
    734734
  • trunk/src/VBox/Runtime/common/misc/req.cpp

    r26562 r27800  
    821821            } u;
    822822            u.pfn = pReq->u.Internal.pfn;
    823 #ifdef RT_ARCH_AMD64
     823#ifndef RT_ARCH_X86
    824824            switch (pReq->u.Internal.cArgs)
    825825            {
     
    842842                    break;
    843843            }
    844 #else /* x86: */
     844#else /* RT_ARCH_X86 */
    845845            size_t cbArgs = pReq->u.Internal.cArgs * sizeof(uintptr_t);
    846846# ifdef __GNUC__
     
    879879            }
    880880# endif
    881 #endif /* x86 */
     881#endif /* RT_ARCH_X86 */
    882882            if ((pReq->fFlags & (RTREQFLAGS_RETURN_MASK)) == RTREQFLAGS_VOID)
    883883                rcRet = VINF_SUCCESS;
  • trunk/src/VBox/Runtime/generic/RTMpCpuId-generic.cpp

    r21337 r27800  
    4141RTDECL(RTCPUID) RTMpCpuId(void)
    4242{
    43 #if defined(RT_ARCH_X86) || defined(RT_ARCH_AMD64)
     43#if defined(RT_ARCH_X86) || defined(RT_ARCH_AMD64) || defined(RT_ARCH_SPARC) || defined(RT_ARCH_SPARC64)
    4444    return ASMGetApicId();
    4545#else
  • trunk/src/VBox/Runtime/testcase/Makefile.kmk

    r27576 r27800  
    7272        tstInlineAsm \
    7373        tstLdr \
    74         tstLdr-2 \
    75         tstLdr-3 \
    76         tstLdr-4 \
    7774        tstLdrLoad \
    7875        tstRTList \
     
    8683        tstMove \
    8784        tstMp-1 \
    88         tstNoCrt-1 \
    8985        tstOnce \
    9086        tstRTPath \
     
    9692        tstRTFsQueries \
    9793        tstR0ThreadPreemptionDriver \
    98         tstRTS3 \
    9994        tstSemEvent \
    10095        tstSemMutex \
     
    141136PROGRAMS.darwin += \
    142137        tstDarwinSched
    143 SYSMODS += \
    144         tstLdrObjR0 \
    145         tstRTR0MemUserKernel \
    146         tstR0ThreadPreemption
    147 ifdef VBOX_WITH_RAW_MODE
    148  SYSMODS += tstLdrObj
     138ifdef VBOX_WITH_LIBCURL
     139 PROGRAMS += \
     140        tstRTS3
     141endif
     142ifn1of ($(KBUILD_TARGET_ARCH), sparc32 sparc64)
     143 PROGRAMS += \
     144        tstLdr-2 \
     145        tstLdr-3 \
     146        tstLdr-4 \
     147        tstNoCrt-1
     148 SYSMODS += \
     149        tstLdrObjR0 \
     150        tstRTR0MemUserKernel \
     151        tstR0ThreadPreemption
     152 ifdef VBOX_WITH_RAW_MODE
     153  SYSMODS += tstLdrObj
     154 endif
    149155endif
    150156if1of ($(VBOX_LDR_FMT)), lx pe)
    151 LIBRARIES += \
    152         tstLdr-4Imp
     157 LIBRARIES += \
     158        tstLdr-4Imp
    153159endif
    154160
Note: See TracChangeset for help on using the changeset viewer.

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