initterm-r0drv-linux.c revision 10f0e3bfdb61e7bae30a1a1d9c17659a908c3d37
5b281ba489ca18f0380d7efc7a5108b606cce449vboxsync * IPRT - Initialization & Termination, R0 Driver, Linux.
10f0e3bfdb61e7bae30a1a1d9c17659a908c3d37vboxsync * Copyright (C) 2006-2011 Oracle Corporation
2b80aa00cbee106b9ec709660eadb6f59f4ca121vboxsync * This file is part of VirtualBox Open Source Edition (OSE), as
2b80aa00cbee106b9ec709660eadb6f59f4ca121vboxsync * available from http://www.virtualbox.org. This file is free software;
2b80aa00cbee106b9ec709660eadb6f59f4ca121vboxsync * you can redistribute it and/or modify it under the terms of the GNU
a16eb14ad7a4b5ef91ddc22d3e8e92d930f736fcvboxsync * General Public License (GPL) as published by the Free Software
a16eb14ad7a4b5ef91ddc22d3e8e92d930f736fcvboxsync * Foundation, in version 2 as it comes in the "COPYING" file of the
a16eb14ad7a4b5ef91ddc22d3e8e92d930f736fcvboxsync * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
a16eb14ad7a4b5ef91ddc22d3e8e92d930f736fcvboxsync * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
a16eb14ad7a4b5ef91ddc22d3e8e92d930f736fcvboxsync * The contents of this file may alternatively be used under the terms
a16eb14ad7a4b5ef91ddc22d3e8e92d930f736fcvboxsync * of the Common Development and Distribution License Version 1.0
a16eb14ad7a4b5ef91ddc22d3e8e92d930f736fcvboxsync * (CDDL) only, as it comes in the "COPYING.CDDL" file of the
a16eb14ad7a4b5ef91ddc22d3e8e92d930f736fcvboxsync * VirtualBox OSE distribution, in which case the provisions of the
a16eb14ad7a4b5ef91ddc22d3e8e92d930f736fcvboxsync * CDDL are applicable instead of those of the GPL.
a16eb14ad7a4b5ef91ddc22d3e8e92d930f736fcvboxsync * You may elect to license modified versions of this file under the
a16eb14ad7a4b5ef91ddc22d3e8e92d930f736fcvboxsync * terms and conditions of either the GPL or the CDDL or both.
2b80aa00cbee106b9ec709660eadb6f59f4ca121vboxsync/*******************************************************************************
2b80aa00cbee106b9ec709660eadb6f59f4ca121vboxsync* Header Files *
2b80aa00cbee106b9ec709660eadb6f59f4ca121vboxsync*******************************************************************************/
10f0e3bfdb61e7bae30a1a1d9c17659a908c3d37vboxsync/*******************************************************************************
10f0e3bfdb61e7bae30a1a1d9c17659a908c3d37vboxsync* Global Variables *
10f0e3bfdb61e7bae30a1a1d9c17659a908c3d37vboxsync*******************************************************************************/
10f0e3bfdb61e7bae30a1a1d9c17659a908c3d37vboxsync/** The IPRT work queue. */
10f0e3bfdb61e7bae30a1a1d9c17659a908c3d37vboxsyncstatic struct workqueue_struct *g_prtR0LnxWorkQueue;
2b80aa00cbee106b9ec709660eadb6f59f4ca121vboxsync/*******************************************************************************
2b80aa00cbee106b9ec709660eadb6f59f4ca121vboxsync* Internal Functions *
2b80aa00cbee106b9ec709660eadb6f59f4ca121vboxsync*******************************************************************************/
10f0e3bfdb61e7bae30a1a1d9c17659a908c3d37vboxsync * Pushes an item onto the IPRT work queue.
10f0e3bfdb61e7bae30a1a1d9c17659a908c3d37vboxsync * @param pWork The work item.
10f0e3bfdb61e7bae30a1a1d9c17659a908c3d37vboxsync * @param pfnWorker The callback function. It will be called back
10f0e3bfdb61e7bae30a1a1d9c17659a908c3d37vboxsync * with @a pWork as argument.
10f0e3bfdb61e7bae30a1a1d9c17659a908c3d37vboxsyncDECLHIDDEN(void) rtR0LnxWorkqueuePush(RTR0LNXWORKQUEUEITEM *pWork, void (*pfnWorker)(RTR0LNXWORKQUEUEITEM *))
10f0e3bfdb61e7bae30a1a1d9c17659a908c3d37vboxsync * Flushes all items in the IPRT work queue.
10f0e3bfdb61e7bae30a1a1d9c17659a908c3d37vboxsync * @remarks This is mostly for 2.4.x compatability. Must not be called from
10f0e3bfdb61e7bae30a1a1d9c17659a908c3d37vboxsync * atomic contexts or with unncessary locks held.