thread-r0drv-freebsd.c revision 7f9158d55774800c9b8f2d35fde872c7434fd281
da2e3ebdc1edfbc5028edf1354e7dd2fa69a7968chin * IPRT - Threads (Part 1), Ring-0 Driver, FreeBSD.
7c2fbfb345896881c631598ee3852ce9ce33fb07April Chin * Copyright (C) 2007-2009 Oracle Corporation
da2e3ebdc1edfbc5028edf1354e7dd2fa69a7968chin * This file is part of VirtualBox Open Source Edition (OSE), as
da2e3ebdc1edfbc5028edf1354e7dd2fa69a7968chin * available from http://www.virtualbox.org. This file is free software;
da2e3ebdc1edfbc5028edf1354e7dd2fa69a7968chin * you can redistribute it and/or modify it under the terms of the GNU
da2e3ebdc1edfbc5028edf1354e7dd2fa69a7968chin * General Public License (GPL) as published by the Free Software
da2e3ebdc1edfbc5028edf1354e7dd2fa69a7968chin * Foundation, in version 2 as it comes in the "COPYING" file of the
da2e3ebdc1edfbc5028edf1354e7dd2fa69a7968chin * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
da2e3ebdc1edfbc5028edf1354e7dd2fa69a7968chin * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
da2e3ebdc1edfbc5028edf1354e7dd2fa69a7968chin * The contents of this file may alternatively be used under the terms
da2e3ebdc1edfbc5028edf1354e7dd2fa69a7968chin * of the Common Development and Distribution License Version 1.0
da2e3ebdc1edfbc5028edf1354e7dd2fa69a7968chin * (CDDL) only, as it comes in the "COPYING.CDDL" file of the
da2e3ebdc1edfbc5028edf1354e7dd2fa69a7968chin * VirtualBox OSE distribution, in which case the provisions of the
da2e3ebdc1edfbc5028edf1354e7dd2fa69a7968chin * CDDL are applicable instead of those of the GPL.
#include "the-freebsd-kernel.h"
int rc;
int cTicks;
if (!cMillies)
return VINF_SUCCESS;
cTicks);
switch (rc)
return VINF_SUCCESS;
case EWOULDBLOCK:
return VERR_TIMEOUT;
case EINTR:
case ERESTART:
return VERR_INTERRUPTED;
return VERR_NO_TRANSLATION;
uio_yield();
return !ASMIntAreEnabled();