VirtualBox

Ignore:
Timestamp:
Jan 20, 2007 1:22:45 AM (18 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
17673
Message:

A stab at generic timers (untested).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Runtime/include/internal/thread.h

    r1 r197  
    2525#include <iprt/types.h>
    2626#include <iprt/thread.h>
    27 #include <iprt/process.h>
    28 #include <iprt/critsect.h>
    29 #include <iprt/avl.h>
    30 
     27#ifdef IN_RING3
     28# include <iprt/process.h>
     29# include <iprt/critsect.h>
     30# include <iprt/avl.h>
     31#endif
    3132
    3233__BEGIN_DECLS
     34
    3335
    3436#ifdef IN_RING3
     
    212214void rtThreadUnblocked(PRTTHREADINT pThread, RTTHREADSTATE enmCurState);
    213215
    214 #endif /* IN_RING3 */
     216
     217#elif defined(IN_RING0)
     218
     219/**
     220 * Argument package for a ring-0 thread.
     221 */
     222typedef struct RTR0THREADARGS
     223{
     224    /** The thread function. */
     225    PFNRTTHREAD     pfnThread;
     226    /** The thread function argument. */
     227    void           *pvUser;
     228    /** The thread type. */
     229    RTTHREADTYPE    enmType;
     230} RTR0THREADARGS, *PRTR0THREADARGS;
     231
     232
     233
     234int rtThreadMain(PRTR0THREADARGS pArgs, RTNATIVETHREAD NativeThread);
     235
     236/**
     237 * Do the actual thread creation.
     238 *
     239 * @returns IPRT status code.
     240 *          On failure, no thread has been created.
     241 * @param   pArgs           The argument package.
     242 * @param   pNativeThread   Where to return the native thread handle.
     243 */
     244int rtThreadNativeCreate(PRTR0THREADARGS pArgs, PRTNATIVETHREAD pNativeThread);
     245
     246/**
     247 * Do the actual thread priority change.
     248 *
     249 * @returns IPRT status code.
     250 * @param   Thread      The thread which priority should be changed.
     251 *                      This is currently restricted to the current thread.
     252 * @param   enmType     The new thread priority type (valid).
     253 */
     254int rtThreadNativeSetPriority(RTTHREAD Thread, RTTHREADTYPE enmType);
     255
     256#endif /* !IN_RING0 */
    215257
    216258__END_DECLS
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