VirtualBox

Changeset 20793 in vbox for trunk/src/VBox/Runtime/r0drv


Ignore:
Timestamp:
Jun 22, 2009 5:05:03 PM (16 years ago)
Author:
vboxsync
Message:

semevent*-r0drv-solaris.c(+spinlock-r0drv-solaris.c+the-solaris-kernel.h): Protect the CV with a spinlock to make it possible to signal the sem with preemption disabled.

Location:
trunk/src/VBox/Runtime/r0drv/solaris
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Runtime/r0drv/solaris/semevent-r0drv-solaris.c

    r8245 r20793  
    3333*******************************************************************************/
    3434#include "the-solaris-kernel.h"
    35 #include <time.h>
    3635
    3736#include <iprt/semaphore.h>
     
    7978        pEventInt->cWaking = 0;
    8079        pEventInt->fSignaled = 0;
    81         mutex_init(&pEventInt->Mtx, "IPRT Event Semaphore", MUTEX_DRIVER, NULL);
     80        mutex_init(&pEventInt->Mtx, "IPRT Event Semaphore", MUTEX_DRIVER, (void *)ipltospl(DISP_LEVEL));
    8281        cv_init(&pEventInt->Cnd, "IPRT CV", CV_DRIVER, NULL);
    8382        *pEventSem = pEventInt;
  • trunk/src/VBox/Runtime/r0drv/solaris/semeventmulti-r0drv-solaris.c

    r19332 r20793  
    7979        pThis->cWaking = 0;
    8080        pThis->fSignaled = 0;
    81         mutex_init(&pThis->Mtx, "IPRT Multiple Release Event Semaphore", MUTEX_DRIVER, NULL);
     81        mutex_init(&pThis->Mtx, "IPRT Multiple Release Event Semaphore", MUTEX_DRIVER, (void *)ipltospl(DISP_LEVEL));
    8282        cv_init(&pThis->Cnd, "IPRT CV", CV_DRIVER, NULL);
    8383        *pEventMultiSem = pThis;
  • trunk/src/VBox/Runtime/r0drv/solaris/spinlock-r0drv-solaris.c

    r13248 r20793  
    3333*******************************************************************************/
    3434#include "the-solaris-kernel.h"
    35 #include <sys/spl.h>
    3635
    3736#include <iprt/spinlock.h>
  • trunk/src/VBox/Runtime/r0drv/solaris/the-solaris-kernel.h

    r20374 r20793  
    5656#include <sys/ddi.h>
    5757#include <sys/sunddi.h>
     58#include <sys/spl.h>
    5859
    5960#undef u /* /usr/include/sys/user.h:249:1 is where this is defined to (curproc->p_user). very cool. */
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