ConsoleImpl2.cpp revision 0b7e860321d9c3303714ee5d27315add187d8a1a
e0e0c19eefceaf5d4ec40f9466b58a771f50e799vboxsync * VBox Console COM Class implementation
e0e0c19eefceaf5d4ec40f9466b58a771f50e799vboxsync * @remark We've split out the code that the 64-bit VC++ v8 compiler
e0e0c19eefceaf5d4ec40f9466b58a771f50e799vboxsync * finds problematic to optimize so we can disable optimizations
c58f1213e628a545081c70e26c6b67a841cff880vboxsync * and later, perhaps, find a real solution for it.
e0e0c19eefceaf5d4ec40f9466b58a771f50e799vboxsync * Copyright (C) 2006-2007 innotek GmbH
e0e0c19eefceaf5d4ec40f9466b58a771f50e799vboxsync * This file is part of VirtualBox Open Source Edition (OSE), as
e0e0c19eefceaf5d4ec40f9466b58a771f50e799vboxsync * available from http://www.virtualbox.org. This file is free software;
e0e0c19eefceaf5d4ec40f9466b58a771f50e799vboxsync * you can redistribute it and/or modify it under the terms of the GNU
e0e0c19eefceaf5d4ec40f9466b58a771f50e799vboxsync * General Public License (GPL) as published by the Free Software
e0e0c19eefceaf5d4ec40f9466b58a771f50e799vboxsync * Foundation, in version 2 as it comes in the "COPYING" file of the
e0e0c19eefceaf5d4ec40f9466b58a771f50e799vboxsync * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
772269936494ffaddd0750ba9e28e805ba81398cvboxsync * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync/*******************************************************************************
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync* Header Files *
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync*******************************************************************************/
e0e0c19eefceaf5d4ec40f9466b58a771f50e799vboxsync// generated header
e0e0c19eefceaf5d4ec40f9466b58a771f50e799vboxsync * VC++ 8 / amd64 has some serious trouble with this function.
e0e0c19eefceaf5d4ec40f9466b58a771f50e799vboxsync * As a temporary measure, we'll drop global optimizations.
aae15a3015041f7ed6043344bf4939736254acf6vboxsync * Construct the VM configuration tree (CFGM).
ba44972d4fba964e9794fb07b869741c42aa7d35vboxsync * This is a callback for VMR3Create() call. It is called from CFGMR3Init()
ba44972d4fba964e9794fb07b869741c42aa7d35vboxsync * in the emulation thread (EMT). Any per thread COM/XPCOM initialization
ba44972d4fba964e9794fb07b869741c42aa7d35vboxsync * is done here.
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync * @param pVM VM handle.
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync * @param pvConsole Pointer to the VMPowerUpTask object.
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync * @return VBox status code.
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync * @note Locks the Console object for writing.
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsyncDECLCALLBACK(int) Console::configConstructor(PVM pVM, void *pvConsole)
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync /* Note: hardcoded assumption about number of slots; see rom bios */
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync /* initialize COM */
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync LogFlow (("Console::configConstructor(): CoInitializeEx()=%08X\n", hrc));
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync ComObjPtr <Console> pConsole = static_cast <Console *> (pvConsole);
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync AssertComRCReturn (autoCaller.rc(), VERR_ACCESS_DENIED);
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync /* lock the console because we widely use internal fields and methods */
10ca321f3be6e9e0ad484f4684cab6532bea20e2vboxsync#define STR_CONV() do { rc = RTUtf16ToUtf8(str, &psz); RC_CHECK(); } while (0)
10ca321f3be6e9e0ad484f4684cab6532bea20e2vboxsync#define STR_FREE() do { if (str) { SysFreeString(str); str = NULL; } if (psz) { RTStrFree(psz); psz = NULL; } } while (0)
10ca321f3be6e9e0ad484f4684cab6532bea20e2vboxsync#define RC_CHECK() do { if (VBOX_FAILURE(rc)) { AssertMsgFailed(("rc=%Vrc\n", rc)); STR_FREE(); return rc; } } while (0)
10ca321f3be6e9e0ad484f4684cab6532bea20e2vboxsync#define H() do { if (FAILED(hrc)) { AssertMsgFailed(("hrc=%#x\n", hrc)); STR_FREE(); return VERR_GENERAL_FAILURE; } } while (0)
67927207a2d6bb545eb655ef14cdb090b1957120vboxsync * Get necessary objects and frequently used parameters.
384478d3896257fbce9ceb8c01e74040b969e6d7vboxsync hrc = pMachine->COMGETTER(Parent)(virtualBox.asOutParam()); H();
384478d3896257fbce9ceb8c01e74040b969e6d7vboxsync hrc = virtualBox->COMGETTER(Host)(host.asOutParam()); H();
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync hrc = virtualBox->COMGETTER(SystemProperties)(systemProperties.asOutParam()); H();
e0e0c19eefceaf5d4ec40f9466b58a771f50e799vboxsync hrc = pMachine->COMGETTER(BIOSSettings)(biosSettings.asOutParam()); H();
e0e0c19eefceaf5d4ec40f9466b58a771f50e799vboxsync hrc = pMachine->COMGETTER(Id)(uuid.asOutParam()); H();
67927207a2d6bb545eb655ef14cdb090b1957120vboxsync hrc = pMachine->COMGETTER(MemorySize)(&cRamMBs); H();
67927207a2d6bb545eb655ef14cdb090b1957120vboxsync * Get root node first.
67927207a2d6bb545eb655ef14cdb090b1957120vboxsync * This is the only node in the tree.
04b02ffb8824a60fd37777bc1f7d2f35104a274cvboxsync * Set the root level values.
384478d3896257fbce9ceb8c01e74040b969e6d7vboxsync rc = CFGMR3InsertString(pRoot, "Name", psz); RC_CHECK();
384478d3896257fbce9ceb8c01e74040b969e6d7vboxsync rc = CFGMR3InsertBytes(pRoot, "UUID", pUuid, sizeof(*pUuid)); RC_CHECK();
384478d3896257fbce9ceb8c01e74040b969e6d7vboxsync rc = CFGMR3InsertInteger(pRoot, "RamSize", cRamMBs * _1M); RC_CHECK();
384478d3896257fbce9ceb8c01e74040b969e6d7vboxsync rc = CFGMR3InsertInteger(pRoot, "TimerMillies", 10); RC_CHECK();
67927207a2d6bb545eb655ef14cdb090b1957120vboxsync rc = CFGMR3InsertInteger(pRoot, "RawR3Enabled", 1); /* boolean */ RC_CHECK();
67927207a2d6bb545eb655ef14cdb090b1957120vboxsync rc = CFGMR3InsertInteger(pRoot, "RawR0Enabled", 1); /* boolean */ RC_CHECK();
67927207a2d6bb545eb655ef14cdb090b1957120vboxsync /** @todo Config: RawR0, PATMEnabled and CASMEnabled needs attention later. */
762fe54a6432c5fed423102dcd8f072a9e5e9cb9vboxsync rc = CFGMR3InsertInteger(pRoot, "PATMEnabled", 1); /* boolean */ RC_CHECK();
67927207a2d6bb545eb655ef14cdb090b1957120vboxsync rc = CFGMR3InsertInteger(pRoot, "CSAMEnabled", 1); /* boolean */ RC_CHECK();
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync /* hardware virtualization extensions */
f9dd063f9fc5484ce7c1dffbd47b6ca9913a51b7vboxsync hrc = pMachine->COMGETTER(HWVirtExEnabled)(&hwVirtExEnabled); H();
b9b1a758d233ec99707a143ebb72e26724e8b709vboxsync /* check the default value */
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync hrc = systemProperties->COMGETTER(HWVirtExEnabled)(&fHWVirtExEnabled); H();
de4b88070eed3a77d1e5b285a6373124450f8fccvboxsync fHWVirtExEnabled = (hwVirtExEnabled == TSBool_True);
de4b88070eed3a77d1e5b285a6373124450f8fccvboxsync#ifndef RT_OS_DARWIN /** @todo Implement HWVirtExt on darwin. See #1865. */
769108208fb3edf0f765132bc7104f93399db77avboxsync rc = CFGMR3InsertNode(pRoot, "HWVirtExt", &pHWVirtExt); RC_CHECK();
384478d3896257fbce9ceb8c01e74040b969e6d7vboxsync rc = CFGMR3InsertInteger(pHWVirtExt, "Enabled", 1); RC_CHECK();
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync hrc = biosSettings->COMGETTER(IOAPICEnabled)(&fIOAPIC); H();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync hrc = biosSettings->COMGETTER(PXEDebugEnabled)(&fPXEDebug); H();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync * Virtual IDE controller type.
81578c6df6541d965dcfe32dd0e0decb64a42284vboxsync hrc = biosSettings->COMGETTER(IDEControllerType)(&controllerType); H();
ba44972d4fba964e9794fb07b869741c42aa7d35vboxsync AssertMsgFailed(("Invalid IDE controller type '%d'", controllerType));
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync * PDM config.
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync * Load drivers in VBoxC.[so|dll]
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pRoot, "PDM", &pPDM); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pPDM, "Drivers", &pDrivers); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pDrivers, "VBoxC", &pMod); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync // VBoxC is located in the components subdirectory
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = RTPathAppPrivateArch(szPathVBoxC, RTPATH_MAX - sizeof("/components/VBoxC")); AssertRC(rc);
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertString(pMod, "Path", szPathVBoxC); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertString(pMod, "Path", "VBoxC"); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync PCFGMNODE pCfg = NULL; /* /Devices/Dev/.../Config/ */
aae15a3015041f7ed6043344bf4939736254acf6vboxsync PCFGMNODE pLunL0 = NULL; /* /Devices/Dev/0/LUN#0/ */
aae15a3015041f7ed6043344bf4939736254acf6vboxsync PCFGMNODE pLunL1 = NULL; /* /Devices/Dev/0/LUN#0/AttachedDriver/ */
aae15a3015041f7ed6043344bf4939736254acf6vboxsync PCFGMNODE pLunL2 = NULL; /* /Devices/Dev/0/LUN#0/AttachedDriver/Config/ */
aae15a3015041f7ed6043344bf4939736254acf6vboxsync PCFGMNODE pIdeInst = NULL; /* /Devices/piix3ide/0/ */
aae15a3015041f7ed6043344bf4939736254acf6vboxsync PCFGMNODE pBiosCfg = NULL; /* /Devices/pcbios/0/Config/ */
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pRoot, "Devices", &pDevices); RC_CHECK();
ca551aca153d6df494985b5281c573ba2e3eb474vboxsync rc = CFGMR3InsertNode(pDevices, "pcarch", &pDev); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pDev, "0", &pInst); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertInteger(pInst, "Trusted", 1); /* boolean */ RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pInst, "Config", &pCfg); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pDevices, "pcbios", &pDev); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pDev, "0", &pInst); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertInteger(pInst, "Trusted", 1); /* boolean */ RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pInst, "Config", &pBiosCfg); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertInteger(pBiosCfg, "RamSize", cRamMBs * _1M); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertString(pBiosCfg, "HardDiskDevice", "piix3ide"); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertString(pBiosCfg, "FloppyDevice", "i82078"); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertInteger(pBiosCfg, "IOAPIC", fIOAPIC); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertInteger(pBiosCfg, "PXEDebug", fPXEDebug); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertBytes(pBiosCfg, "UUID", pUuid, sizeof(*pUuid)); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync for (ULONG pos = 1; pos <= SchemaDefs::MaxBootPosition; pos ++)
aae15a3015041f7ed6043344bf4939736254acf6vboxsync hrc = pMachine->GetBootOrder(pos, &bootDevice); H();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync szParamName[sizeof (szParamName) - 2] = ((char (pos - 1)) + '0');
d55a27219d1a4cf241ff0cc0f8ac3a97b40e1ad3vboxsync AssertMsgFailed(("Invalid bootDevice=%d\n", bootDevice));
67927207a2d6bb545eb655ef14cdb090b1957120vboxsync rc = CFGMR3InsertString(pBiosCfg, szParamName, pszBootDevice); RC_CHECK();
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync * The time offset
f9dd063f9fc5484ce7c1dffbd47b6ca9913a51b7vboxsync hrc = biosSettings->COMGETTER(TimeOffset)(&timeOffset); H();
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync rc = CFGMR3InsertNode(pRoot, "TM", &pTMNode); RC_CHECK();
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync rc = CFGMR3InsertInteger(pTMNode, "UTCOffset", timeOffset * 1000000); RC_CHECK();
b40c3fa94b8a873f7f2eca1558e0de367a276687vboxsync hrc = biosSettings->COMGETTER(ACPIEnabled)(&fACPI); H();
e0e0c19eefceaf5d4ec40f9466b58a771f50e799vboxsync rc = CFGMR3InsertNode(pDevices, "acpi", &pDev); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pDev, "0", &pInst); RC_CHECK();
6a0a658a7d69e5730cdf36b4f717fea42fee6b4cvboxsync rc = CFGMR3InsertInteger(pInst, "Trusted", 1); /* boolean */ RC_CHECK();
6a0a658a7d69e5730cdf36b4f717fea42fee6b4cvboxsync rc = CFGMR3InsertNode(pInst, "Config", &pCfg); RC_CHECK();
e0e0c19eefceaf5d4ec40f9466b58a771f50e799vboxsync rc = CFGMR3InsertInteger(pCfg, "RamSize", cRamMBs * _1M); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertInteger(pCfg, "IOAPIC", fIOAPIC); RC_CHECK();
6a0a658a7d69e5730cdf36b4f717fea42fee6b4cvboxsync rc = CFGMR3InsertInteger(pInst, "PCIDeviceNo", 7); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertInteger(pInst, "PCIFunctionNo", 0); RC_CHECK();
6a0a658a7d69e5730cdf36b4f717fea42fee6b4cvboxsync rc = CFGMR3InsertNode(pInst, "LUN#0", &pLunL0); RC_CHECK();
e0e0c19eefceaf5d4ec40f9466b58a771f50e799vboxsync rc = CFGMR3InsertString(pLunL0, "Driver", "ACPIHost"); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pLunL0, "Config", &pCfg); RC_CHECK();
6a0a658a7d69e5730cdf36b4f717fea42fee6b4cvboxsync rc = CFGMR3InsertNode(pDevices, "8237A", &pDev); RC_CHECK();
e0e0c19eefceaf5d4ec40f9466b58a771f50e799vboxsync rc = CFGMR3InsertNode(pDev, "0", &pInst); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertInteger(pInst, "Trusted", 1); /* boolean */ RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pDevices, "pci", &pDev); /* piix3 */ RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pDev, "0", &pInst); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertInteger(pInst, "Trusted", 1); /* boolean */ RC_CHECK();
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync rc = CFGMR3InsertNode(pInst, "Config", &pCfg); RC_CHECK();
f9dd063f9fc5484ce7c1dffbd47b6ca9913a51b7vboxsync rc = CFGMR3InsertInteger(pCfg, "IOAPIC", fIOAPIC); RC_CHECK();
ba44972d4fba964e9794fb07b869741c42aa7d35vboxsync * PS/2 keyboard & mouse.
ba44972d4fba964e9794fb07b869741c42aa7d35vboxsync rc = CFGMR3InsertNode(pDevices, "pckbd", &pDev); RC_CHECK();
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync rc = CFGMR3InsertNode(pDev, "0", &pInst); RC_CHECK();
e0e0c19eefceaf5d4ec40f9466b58a771f50e799vboxsync rc = CFGMR3InsertInteger(pInst, "Trusted", 1); /* boolean */ RC_CHECK();
e0e0c19eefceaf5d4ec40f9466b58a771f50e799vboxsync rc = CFGMR3InsertNode(pInst, "Config", &pCfg); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pInst, "LUN#0", &pLunL0); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertString(pLunL0, "Driver", "KeyboardQueue"); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pLunL0, "Config", &pCfg); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertInteger(pCfg, "QueueSize", 64); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pLunL0, "AttachedDriver", &pLunL1); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertString(pLunL1, "Driver", "MainKeyboard"); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pLunL1, "Config", &pCfg); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertInteger(pCfg, "Object", (uintptr_t)pKeyboard); RC_CHECK();
d10b60270f0c0eeb87f45002a010cff8ba2126b1vboxsync rc = CFGMR3InsertNode(pInst, "LUN#1", &pLunL0); RC_CHECK();
d10b60270f0c0eeb87f45002a010cff8ba2126b1vboxsync rc = CFGMR3InsertString(pLunL0, "Driver", "MouseQueue"); RC_CHECK();
d10b60270f0c0eeb87f45002a010cff8ba2126b1vboxsync rc = CFGMR3InsertNode(pLunL0, "Config", &pCfg); RC_CHECK();
d10b60270f0c0eeb87f45002a010cff8ba2126b1vboxsync rc = CFGMR3InsertInteger(pCfg, "QueueSize", 128); RC_CHECK();
99f34065aa871a12e9afacbaf27bd9dc9ff8d0bbvboxsync rc = CFGMR3InsertNode(pLunL0, "AttachedDriver", &pLunL1); RC_CHECK();
762fe54a6432c5fed423102dcd8f072a9e5e9cb9vboxsync rc = CFGMR3InsertString(pLunL1, "Driver", "MainMouse"); RC_CHECK();
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync rc = CFGMR3InsertNode(pLunL1, "Config", &pCfg); RC_CHECK();
67927207a2d6bb545eb655ef14cdb090b1957120vboxsync rc = CFGMR3InsertInteger(pCfg, "Object", (uintptr_t)pMouse); RC_CHECK();
67927207a2d6bb545eb655ef14cdb090b1957120vboxsync * i82078 Floppy drive controller
762fe54a6432c5fed423102dcd8f072a9e5e9cb9vboxsync hrc = pMachine->COMGETTER(FloppyDrive)(floppyDrive.asOutParam()); H();
67927207a2d6bb545eb655ef14cdb090b1957120vboxsync hrc = floppyDrive->COMGETTER(Enabled)(&fFloppyEnabled); H();
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync rc = CFGMR3InsertNode(pDevices, "i82078", &pDev); RC_CHECK();
e0e0c19eefceaf5d4ec40f9466b58a771f50e799vboxsync rc = CFGMR3InsertNode(pDev, "0", &pInst); RC_CHECK();
f9dd063f9fc5484ce7c1dffbd47b6ca9913a51b7vboxsync rc = CFGMR3InsertInteger(pInst, "Trusted", 1); RC_CHECK();
e0e0c19eefceaf5d4ec40f9466b58a771f50e799vboxsync rc = CFGMR3InsertNode(pInst, "Config", &pCfg); RC_CHECK();
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync rc = CFGMR3InsertInteger(pCfg, "IRQ", 6); RC_CHECK();
f9dd063f9fc5484ce7c1dffbd47b6ca9913a51b7vboxsync rc = CFGMR3InsertInteger(pCfg, "DMA", 2); RC_CHECK();
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync rc = CFGMR3InsertInteger(pCfg, "MemMapped", 0 ); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertInteger(pCfg, "IOBase", 0x3f0); RC_CHECK();
6a0a658a7d69e5730cdf36b4f717fea42fee6b4cvboxsync /* Attach the status driver */
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pInst, "LUN#999", &pLunL0); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertString(pLunL0, "Driver", "MainStatus"); RC_CHECK();
6a0a658a7d69e5730cdf36b4f717fea42fee6b4cvboxsync rc = CFGMR3InsertNode(pLunL0, "Config", &pCfg); RC_CHECK();
6a0a658a7d69e5730cdf36b4f717fea42fee6b4cvboxsync rc = CFGMR3InsertInteger(pCfg, "papLeds", (uintptr_t)&pConsole->mapFDLeds[0]); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertInteger(pCfg, "First", 0); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertInteger(pCfg, "Last", 0); RC_CHECK();
6a0a658a7d69e5730cdf36b4f717fea42fee6b4cvboxsync rc = CFGMR3InsertNode(pInst, "LUN#0", &pLunL0); RC_CHECK();
6a0a658a7d69e5730cdf36b4f717fea42fee6b4cvboxsync hrc = floppyDrive->GetImage(floppyImage.asOutParam()); H();
6a0a658a7d69e5730cdf36b4f717fea42fee6b4cvboxsync rc = CFGMR3InsertString(pLunL0, "Driver", "Block"); RC_CHECK();
6a0a658a7d69e5730cdf36b4f717fea42fee6b4cvboxsync rc = CFGMR3InsertNode(pLunL0, "Config", &pCfg); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertString(pCfg, "Type", "Floppy 1.44"); RC_CHECK();
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync rc = CFGMR3InsertInteger(pCfg, "Mountable", 1); RC_CHECK();
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync rc = CFGMR3InsertNode(pLunL0, "AttachedDriver", &pLunL1); RC_CHECK();
e0e0c19eefceaf5d4ec40f9466b58a771f50e799vboxsync rc = CFGMR3InsertString(pLunL1, "Driver", "RawImage"); RC_CHECK();
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync rc = CFGMR3InsertNode(pLunL1, "Config", &pCfg); RC_CHECK();
e5d3b7a3187d8f891f55aa8fcb5ad3dee90b1e68vboxsync rc = CFGMR3InsertString(pCfg, "Path", psz); RC_CHECK();
8f0a8248a277021da955c40eaef0c6799bf082cdvboxsync hrc = floppyDrive->GetHostDrive(hostFloppyDrive.asOutParam()); H();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync pConsole->meFloppyState = DriveState_HostDriveCaptured;
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertString(pLunL0, "Driver", "HostFloppy"); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pLunL0, "Config", &pCfg); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertString(pCfg, "Path", psz); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertString(pLunL0, "Driver", "Block"); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pLunL0, "Config", &pCfg); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertString(pCfg, "Type", "Floppy 1.44"); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertInteger(pCfg, "Mountable", 1); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync * i8254 Programmable Interval Timer And Dummy Speaker
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pDevices, "i8254", &pDev); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pDev, "0", &pInst); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pInst, "Config", &pCfg); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertInteger(pInst, "Trusted", 1); /* boolean */ RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync * i8259 Programmable Interrupt Controller.
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pDevices, "i8259", &pDev); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pDev, "0", &pInst); RC_CHECK();
ca551aca153d6df494985b5281c573ba2e3eb474vboxsync rc = CFGMR3InsertInteger(pInst, "Trusted", 1); /* boolean */ RC_CHECK();
6e7c344fc7cdb580356704e8201207b394d367bbvboxsync rc = CFGMR3InsertNode(pInst, "Config", &pCfg); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync * Advanced Programmable Interrupt Controller.
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pDevices, "apic", &pDev); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pDev, "0", &pInst); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertInteger(pInst, "Trusted", 1); /* boolean */ RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pInst, "Config", &pCfg); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertInteger(pCfg, "IOAPIC", fIOAPIC); RC_CHECK();
c5fbfff2c6f46db681b0c092d69e6c163917806avboxsync * I/O Advanced Programmable Interrupt Controller.
c5fbfff2c6f46db681b0c092d69e6c163917806avboxsync rc = CFGMR3InsertNode(pDevices, "ioapic", &pDev); RC_CHECK();
e4bbd9d26beb3e1b2403ce02e8be7740ead622afvboxsync rc = CFGMR3InsertNode(pDev, "0", &pInst); RC_CHECK();
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync rc = CFGMR3InsertInteger(pInst, "Trusted", 1); /* boolean */ RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pInst, "Config", &pCfg); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync * RTC MC146818.
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pDevices, "mc146818", &pDev); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pDev, "0", &pInst); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pInst, "Config", &pCfg); RC_CHECK();
c5fbfff2c6f46db681b0c092d69e6c163917806avboxsync rc = CFGMR3InsertNode(pDevices, "vga", &pDev); RC_CHECK();
c5fbfff2c6f46db681b0c092d69e6c163917806avboxsync rc = CFGMR3InsertNode(pDev, "0", &pInst); RC_CHECK();
c5fbfff2c6f46db681b0c092d69e6c163917806avboxsync rc = CFGMR3InsertInteger(pInst, "Trusted", 1); /* boolean */ RC_CHECK();
e4bbd9d26beb3e1b2403ce02e8be7740ead622afvboxsync rc = CFGMR3InsertInteger(pInst, "PCIDeviceNo", 2); RC_CHECK();
22779f914326d58cfd205ee44c1100323fd59821vboxsync rc = CFGMR3InsertInteger(pInst, "PCIFunctionNo", 0); RC_CHECK();
04b02ffb8824a60fd37777bc1f7d2f35104a274cvboxsync rc = CFGMR3InsertNode(pInst, "Config", &pCfg); RC_CHECK();
f74dc240a0d264675cd342aeae29a624aa5b91efvboxsync hrc = pMachine->COMGETTER(VRAMSize)(&cRamMBs); H();
22779f914326d58cfd205ee44c1100323fd59821vboxsync rc = CFGMR3InsertInteger(pCfg, "VRamSize", cRamMBs * _1M); RC_CHECK();
d10b60270f0c0eeb87f45002a010cff8ba2126b1vboxsync * BIOS logo
d10b60270f0c0eeb87f45002a010cff8ba2126b1vboxsync hrc = biosSettings->COMGETTER(LogoFadeIn)(&fFadeIn); H();
c5fbfff2c6f46db681b0c092d69e6c163917806avboxsync rc = CFGMR3InsertInteger(pCfg, "FadeIn", fFadeIn ? 1 : 0); RC_CHECK();
c5fbfff2c6f46db681b0c092d69e6c163917806avboxsync hrc = biosSettings->COMGETTER(LogoFadeOut)(&fFadeOut); H();
c5fbfff2c6f46db681b0c092d69e6c163917806avboxsync rc = CFGMR3InsertInteger(pCfg, "FadeOut", fFadeOut ? 1: 0); RC_CHECK();
c5fbfff2c6f46db681b0c092d69e6c163917806avboxsync hrc = biosSettings->COMGETTER(LogoDisplayTime)(&logoDisplayTime); H();
67927207a2d6bb545eb655ef14cdb090b1957120vboxsync rc = CFGMR3InsertInteger(pCfg, "LogoTime", logoDisplayTime); RC_CHECK();
67927207a2d6bb545eb655ef14cdb090b1957120vboxsync hrc = biosSettings->COMGETTER(LogoImagePath)(logoImagePath.asOutParam()); H();
04b02ffb8824a60fd37777bc1f7d2f35104a274cvboxsync rc = CFGMR3InsertString(pCfg, "LogoFile", logoImagePath ? Utf8Str(logoImagePath) : ""); RC_CHECK();
d55a27219d1a4cf241ff0cc0f8ac3a97b40e1ad3vboxsync * Boot menu
762fe54a6432c5fed423102dcd8f072a9e5e9cb9vboxsync biosSettings->COMGETTER(BootMenuMode)(&bootMenuMode);
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync rc = CFGMR3InsertInteger(pCfg, "ShowBootMenu", value); RC_CHECK();
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync /* Custom VESA mode list */
6a0a658a7d69e5730cdf36b4f717fea42fee6b4cvboxsync unsigned cModes = 0;
6a0a658a7d69e5730cdf36b4f717fea42fee6b4cvboxsync RTStrPrintf(szExtraDataKey, sizeof(szExtraDataKey), "CustomVideoMode%d", iMode);
aae15a3015041f7ed6043344bf4939736254acf6vboxsync hrc = pMachine->GetExtraData(Bstr(szExtraDataKey), &str); H();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertString(pCfg, szExtraDataKey, psz);
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertInteger(pCfg, "CustomVideoModes", cModes);
6a0a658a7d69e5730cdf36b4f717fea42fee6b4cvboxsync /* VESA height reduction */
aae15a3015041f7ed6043344bf4939736254acf6vboxsync IFramebuffer *pFramebuffer = pConsole->getDisplay()->getFramebuffer();
6a0a658a7d69e5730cdf36b4f717fea42fee6b4cvboxsync hrc = pFramebuffer->COMGETTER(HeightReduction)(&ulHeightReduction); H();
6a0a658a7d69e5730cdf36b4f717fea42fee6b4cvboxsync /* If framebuffer is not available, there is no height reduction. */
6a0a658a7d69e5730cdf36b4f717fea42fee6b4cvboxsync rc = CFGMR3InsertInteger(pCfg, "HeightReduction", ulHeightReduction); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync /* Attach the display. */
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pInst, "LUN#0", &pLunL0); RC_CHECK();
6a0a658a7d69e5730cdf36b4f717fea42fee6b4cvboxsync rc = CFGMR3InsertString(pLunL0, "Driver", "MainDisplay"); RC_CHECK();
6a0a658a7d69e5730cdf36b4f717fea42fee6b4cvboxsync rc = CFGMR3InsertNode(pLunL0, "Config", &pCfg); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertInteger(pCfg, "Object", (uintptr_t)pDisplay); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync * IDE (update this when the main interface changes)
6a0a658a7d69e5730cdf36b4f717fea42fee6b4cvboxsync rc = CFGMR3InsertNode(pDevices, "piix3ide", &pDev); /* piix3 */ RC_CHECK();
6a0a658a7d69e5730cdf36b4f717fea42fee6b4cvboxsync rc = CFGMR3InsertNode(pDev, "0", &pIdeInst); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertInteger(pIdeInst, "Trusted", 1); /* boolean */ RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertInteger(pIdeInst, "PCIDeviceNo", 1); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertInteger(pIdeInst, "PCIFunctionNo", 1); RC_CHECK();
f350d4fb2d12fd22c0905fe9c7a121499da7b52dvboxsync rc = CFGMR3InsertNode(pIdeInst, "Config", &pCfg); RC_CHECK();
6a0a658a7d69e5730cdf36b4f717fea42fee6b4cvboxsync rc = CFGMR3InsertInteger(pCfg, "PIIX4", fPIIX4); /* boolean */ RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync /* Attach the status driver */
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertNode(pIdeInst, "LUN#999", &pLunL0); RC_CHECK();
6a0a658a7d69e5730cdf36b4f717fea42fee6b4cvboxsync rc = CFGMR3InsertString(pLunL0, "Driver", "MainStatus"); RC_CHECK();
6a0a658a7d69e5730cdf36b4f717fea42fee6b4cvboxsync rc = CFGMR3InsertNode(pLunL0, "Config", &pCfg); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertInteger(pCfg, "papLeds", (uintptr_t)&pConsole->mapIDELeds[0]);RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync rc = CFGMR3InsertInteger(pCfg, "First", 0); RC_CHECK();
6a0a658a7d69e5730cdf36b4f717fea42fee6b4cvboxsync rc = CFGMR3InsertInteger(pCfg, "Last", 3); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync * SATA controller
aae15a3015041f7ed6043344bf4939736254acf6vboxsync hrc = pMachine->COMGETTER(SATAController)(sataController.asOutParam());
cbb0f4da6089c4359e31e8028d94850b833cab17vboxsync hrc = sataController->COMGETTER(Enabled)(&enabled); H();
a5f487d264b5aebe8d28ad35d0353630bd2b77cdvboxsync rc = CFGMR3InsertNode(pDevices, "ahci", &pDev); RC_CHECK();
a5f487d264b5aebe8d28ad35d0353630bd2b77cdvboxsync rc = CFGMR3InsertNode(pDev, "0", &pSataInst); RC_CHECK();
0412c212ede05017a46044b407f58c82374f6fe4vboxsync rc = CFGMR3InsertInteger(pSataInst, "Trusted", 1); RC_CHECK();
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync rc = CFGMR3InsertInteger(pSataInst, "PCIDeviceNo", 13); RC_CHECK();
ba44972d4fba964e9794fb07b869741c42aa7d35vboxsync rc = CFGMR3InsertInteger(pSataInst, "PCIFunctionNo", 0); RC_CHECK();
ba44972d4fba964e9794fb07b869741c42aa7d35vboxsync rc = CFGMR3InsertNode(pSataInst, "Config", &pCfg); RC_CHECK();
aae15a3015041f7ed6043344bf4939736254acf6vboxsync hrc = sataController->COMGETTER(PortCount)(&cPorts); H();
e0e0c19eefceaf5d4ec40f9466b58a771f50e799vboxsync rc = CFGMR3InsertInteger(pCfg, "PortCount", cPorts); RC_CHECK();
ffa06e5b007c5b2f57341d90088189ce5f99c091vboxsync /* Needed configuration values for the bios. */
ffa06e5b007c5b2f57341d90088189ce5f99c091vboxsync rc = CFGMR3InsertString(pBiosCfg, "SataHardDiskDevice", "ahci"); RC_CHECK();
d10b60270f0c0eeb87f45002a010cff8ba2126b1vboxsync { "PrimaryMaster", "PrimarySlave", "SecondaryMaster", "SecondarySlave" };
d10b60270f0c0eeb87f45002a010cff8ba2126b1vboxsync { "SataPrimaryMasterLUN", "SataPrimarySlaveLUN", "SataSecondaryMasterLUN", "SataSecondarySlaveLUN" };
d10b60270f0c0eeb87f45002a010cff8ba2126b1vboxsync hrc = sataController->GetIDEEmulationPort(i, &lPortNumber); H();
d10b60270f0c0eeb87f45002a010cff8ba2126b1vboxsync rc = CFGMR3InsertInteger(pCfg, s_apszConfig[i], lPortNumber); RC_CHECK();
04b02ffb8824a60fd37777bc1f7d2f35104a274cvboxsync rc = CFGMR3InsertInteger(pBiosCfg, s_apszBiosConfig[i], lPortNumber); RC_CHECK();
04b02ffb8824a60fd37777bc1f7d2f35104a274cvboxsync /* Attach the status driver */
67927207a2d6bb545eb655ef14cdb090b1957120vboxsync rc = CFGMR3InsertNode(pSataInst,"LUN#999", &pLunL0); RC_CHECK();
762fe54a6432c5fed423102dcd8f072a9e5e9cb9vboxsync rc = CFGMR3InsertString(pLunL0, "Driver", "MainStatus"); RC_CHECK();
d55a27219d1a4cf241ff0cc0f8ac3a97b40e1ad3vboxsync rc = CFGMR3InsertNode(pLunL0, "Config", &pCfg); RC_CHECK();
67927207a2d6bb545eb655ef14cdb090b1957120vboxsync AssertRelease(cPorts <= RT_ELEMENTS(pConsole->mapSATALeds));
67927207a2d6bb545eb655ef14cdb090b1957120vboxsync rc = CFGMR3InsertInteger(pCfg, "papLeds", (uintptr_t)&pConsole->mapSATALeds[0]); RC_CHECK();
67927207a2d6bb545eb655ef14cdb090b1957120vboxsync rc = CFGMR3InsertInteger(pCfg, "First", 0); RC_CHECK();
67927207a2d6bb545eb655ef14cdb090b1957120vboxsync rc = CFGMR3InsertInteger(pCfg, "Last", cPorts - 1); RC_CHECK();
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync /* Attach the harddisks */
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync hrc = pMachine->COMGETTER(HardDiskAttachments)(hdaColl.asOutParam()); H();
f9dd063f9fc5484ce7c1dffbd47b6ca9913a51b7vboxsync hrc = hdaColl->Enumerate(hdaEnum.asOutParam()); H();
a48399c41d6eb8b66ad69c050ad263af36873e9cvboxsync hrc = hda->COMGETTER(HardDisk)(hardDisk.asOutParam()); H();
int iLUN;
switch (enmBus)
case StorageBus_IDE:
return VERR_GENERAL_FAILURE;
return VERR_GENERAL_FAILURE;
case StorageBus_SATA:
return VERR_GENERAL_FAILURE;
/* Can be NULL if SATA controller is not enabled and current hard disk is attached to SATA controller. */
if (pHardDiskCtl)
STR_CONV();
STR_FREE();
if (!curHardDisk)
STR_CONV();
STR_FREE();
STR_CONV();
STR_FREE();
STR_CONV();
if (port != 0)
char *pszTN;
STR_FREE();
if (str)
STR_CONV();
STR_FREE();
if (str)
STR_CONV();
STR_FREE();
STR_CONV();
STR_FREE();
STR_CONV();
STR_FREE();
STR_CONV();
STR_FREE();
STR_CONV();
STR_FREE();
AssertFailed();
if (dvdDrive)
if (hostDvdDrive)
STR_CONV();
STR_FREE();
if (dvdImage)
STR_CONV();
STR_FREE();
#ifdef VBOX_WITH_E1000
if (!fEnabled)
switch (adapterType)
#ifdef VBOX_WITH_E1000
return VERR_GENERAL_FAILURE;
switch (adapterType)
rc = CFGMR3InsertInteger(pCfg, "papLeds", (uintptr_t)&pConsole->mapNetworkLeds[ulInstance]); RC_CHECK();
if (fSniffer)
STR_CONV();
STR_FREE();
switch (networkAttachment)
if (fSniffer)
STR_CONV();
STR_FREE();
STR_CONV();
STR_FREE();
if (fSniffer)
# if defined(RT_OS_SOLARIS)
/* TAP setup application/script */
/* TAP terminate application/script */
/* "FileHandle" must NOT be inserted here, it is done in DrvTAP.cpp */
# ifdef VBOX_WITH_CROSSBOW
if (fSniffer)
switch (hrc)
#ifdef RT_OS_LINUX
case VERR_ACCESS_DENIED:
STR_CONV();
if (fSniffer)
STR_FREE();
if (serialPort)
if (!fEnabled)
if (parallelPort)
if (!fEnabled)
if (audioAdapter)
if (enabled)
switch (audioController)
case AudioControllerType_AC97:
case AudioControllerType_SB16:
switch (audioDriver)
case AudioDriverType_Null:
#ifdef RT_OS_WINDOWS
#ifdef VBOX_WITH_WINMM
case AudioDriverType_WinMM:
#ifdef RT_OS_SOLARIS
case AudioDriverType_SolAudio:
#ifdef RT_OS_LINUX
case AudioDriverType_OSS:
# ifdef VBOX_WITH_ALSA
case AudioDriverType_ALSA:
# ifdef VBOX_WITH_PULSE
case AudioDriverType_Pulse:
#ifdef RT_OS_DARWIN
STR_CONV();
STR_FREE();
if (USBCtlPtr)
if (fEnabled)
#ifdef VBOX_WITH_EHCI
if (fEnabled)
// VBoxManage setextradata "myvm" "VBoxInternal/USB/USBProxy/GlobalConfig/Force11PacketSize" 1
switch (mode)
case ClipboardMode_Disabled:
pConsole->mVMMDev->hgcmHostCall ("VBoxSharedClipboard", VBOX_SHARED_CLIPBOARD_HOST_FN_SET_MODE, 1, &parm);
bool fGlobalExtraData = true;
if (fGlobalExtraData)
if (fGlobalExtraData)
fGlobalExtraData = false;
if (pszCFGMValueName)
if (pNode)
#undef H
return rc;