VirtualBox

source: vbox/trunk/src/VBox/Main/include/VMMDev.h@ 31733

Last change on this file since 31733 was 29250, checked in by vboxsync, 15 years ago

iprt/asm*.h: split out asm-math.h, don't include asm-*.h from asm.h, don't include asm.h from sup.h. Fixed a couple file headers.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 2.1 KB
Line 
1/** @file
2 * VirtualBox Driver interface to VMM device
3 */
4
5/*
6 * Copyright (C) 2006-2007 Oracle Corporation
7 *
8 * This file is part of VirtualBox Open Source Edition (OSE), as
9 * available from http://www.virtualbox.org. This file is free software;
10 * you can redistribute it and/or modify it under the terms of the GNU
11 * General Public License (GPL) as published by the Free Software
12 * Foundation, in version 2 as it comes in the "COPYING" file of the
13 * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
14 * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
15 */
16
17#ifndef ____H_VMMDEV
18#define ____H_VMMDEV
19
20#include "VirtualBoxBase.h"
21#include <VBox/pdmdrv.h>
22#include <iprt/asm.h>
23
24class Console;
25
26class VMMDev
27{
28public:
29 VMMDev(Console *console);
30 virtual ~VMMDev();
31 static const PDMDRVREG DrvReg;
32 /** Pointer to the associated VMMDev driver. */
33 struct DRVMAINVMMDEV *mpDrv;
34
35 bool fSharedFolderActive;
36 bool isShFlActive()
37 {
38 return fSharedFolderActive;
39 }
40
41 Console *getParent()
42 {
43 return mParent;
44 }
45
46 int WaitCredentialsJudgement (uint32_t u32Timeout, uint32_t *pu32GuestFlags);
47 int SetCredentialsJudgementResult (uint32_t u32Flags);
48
49 PPDMIVMMDEVPORT getVMMDevPort();
50
51 int hgcmLoadService (const char *pszServiceLibrary, const char *pszServiceName);
52 int hgcmHostCall (const char *pszServiceName, uint32_t u32Function, uint32_t cParms, PVBOXHGCMSVCPARM paParms);
53 void hgcmShutdown (void);
54
55 bool hgcmIsActive (void) { return ASMAtomicReadBool(&m_fHGCMActive); }
56
57private:
58 static DECLCALLBACK(void *) drvQueryInterface(PPDMIBASE pInterface, const char *pszIID);
59 static DECLCALLBACK(int) drvConstruct(PPDMDRVINS pDrvIns, PCFGMNODE pCfg, uint32_t fFlags);
60 static DECLCALLBACK(void) drvDestruct(PPDMDRVINS pDrvIns);
61 static DECLCALLBACK(void) drvReset(PPDMDRVINS pDrvIns);
62
63 Console * const mParent;
64
65 RTSEMEVENT mCredentialsEvent;
66 uint32_t mu32CredentialsFlags;
67
68#ifdef VBOX_WITH_HGCM
69 bool volatile m_fHGCMActive;
70#endif /* VBOX_WITH_HGCM */
71};
72
73#endif // !____H_VMMDEV
74/* vi: set tabstop=4 shiftwidth=4 expandtab: */
Note: See TracBrowser for help on using the repository browser.

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