Changeset 81710 in vbox for trunk/src/VBox
- Timestamp:
- Nov 6, 2019 2:51:26 PM (5 years ago)
- Location:
- trunk/src/VBox/Main
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/Makefile.kmk
r81426 r81710 159 159 VBOX_MAIN_DEFS += VBOX_WITH_EHCI 160 160 endif 161 endif 162 ifdef VBOX_WITH_EFI_IN_DD2 163 VBOX_MAIN_DEFS += VBOX_WITH_EFI_IN_DD2 161 164 endif 162 165 # Unconditionally enable the new semaphore key generation code -
trunk/src/VBox/Main/src-client/ConsoleImpl2.cpp
r81603 r81710 1741 1741 bool const f64BitEntry = eFwType == FirmwareType_EFI64; 1742 1742 1743 Assert(eFwType == FirmwareType_EFI64 || eFwType == FirmwareType_EFI32 || eFwType == FirmwareType_EFIDUAL); 1744 #ifdef VBOX_WITH_EFI_IN_DD2 1745 const char *pszEfiRomFile = eFwType == FirmwareType_EFIDUAL ? "VBoxEFIDual.fd" 1746 : eFwType == FirmwareType_EFI32 ? "VBoxEFI32.fd" 1747 : "VBoxEFI64.fd"; 1748 #else 1743 1749 Utf8Str efiRomFile; 1744 1750 rc = findEfiRom(virtualBox, eFwType, &efiRomFile); 1745 1751 AssertRCReturn(rc, rc); 1752 const char *pszEfiRomFile = efiRomFile.c_str(); 1753 #endif 1746 1754 1747 1755 /* Get boot args */ … … 1816 1824 InsertConfigInteger(pCfg, "McfgBase", uMcfgBase); 1817 1825 InsertConfigInteger(pCfg, "McfgLength", cbMcfgLength); 1818 InsertConfigString(pCfg, "EfiRom", efiRomFile);1826 InsertConfigString(pCfg, "EfiRom", pszEfiRomFile); 1819 1827 InsertConfigString(pCfg, "BootArgs", bootArgs); 1820 1828 InsertConfigString(pCfg, "DeviceProps", deviceProps); -
trunk/src/VBox/Main/src-server/VirtualBoxImpl.cpp
r81427 r81710 1634 1634 static const struct 1635 1635 { 1636 FirmwareType_T type; 1637 const char* fileName; 1638 const char* url; 1636 FirmwareType_T enmType; 1637 bool fBuiltIn; 1638 const char *pszFileName; 1639 const char *pszUrl; 1639 1640 } 1640 1641 firmwareDesc[] = 1641 1642 { 1642 { 1643 /* compiled-in firmware */ 1644 FirmwareType_BIOS, NULL, NULL 1645 }, 1646 { 1647 FirmwareType_EFI32, "VBoxEFI32.fd", "http://virtualbox.org/firmware/VBoxEFI32.fd" 1648 }, 1649 { 1650 FirmwareType_EFI64, "VBoxEFI64.fd", "http://virtualbox.org/firmware/VBoxEFI64.fd" 1651 }, 1652 { 1653 FirmwareType_EFIDUAL, "VBoxEFIDual.fd", "http://virtualbox.org/firmware/VBoxEFIDual.fd" 1654 } 1643 { FirmwareType_BIOS, true, NULL, NULL }, 1644 #ifdef VBOX_WITH_EFI_IN_DD2 1645 { FirmwareType_EFI32, true, "VBoxEFI32.fd", NULL }, 1646 { FirmwareType_EFI64, true, "VBoxEFI64.fd", NULL }, 1647 { FirmwareType_EFIDUAL, true, "VBoxEFIDual.fd", NULL }, 1648 #else 1649 { FirmwareType_EFI32, false, "VBoxEFI32.fd", "http://virtualbox.org/firmware/VBoxEFI32.fd" }, 1650 { FirmwareType_EFI64, false, "VBoxEFI64.fd", "http://virtualbox.org/firmware/VBoxEFI64.fd" }, 1651 { FirmwareType_EFIDUAL, false, "VBoxEFIDual.fd", "http://virtualbox.org/firmware/VBoxEFIDual.fd" }, 1652 #endif 1655 1653 }; 1656 1654 1657 1655 for (size_t i = 0; i < sizeof(firmwareDesc) / sizeof(firmwareDesc[0]); i++) 1658 1656 { 1659 if (aFirmwareType != firmwareDesc[i]. type)1657 if (aFirmwareType != firmwareDesc[i].enmType) 1660 1658 continue; 1661 1659 1662 1660 /* compiled-in firmware */ 1663 if (firmwareDesc[i].fileName == NULL) 1664 { 1661 if (firmwareDesc[i].fBuiltIn) 1662 { 1663 aFile = firmwareDesc[i].pszFileName; 1665 1664 *aResult = TRUE; 1666 1665 break; 1667 1666 } 1668 1667 1669 Utf8Str shortName, fullName; 1670 1671 shortName = Utf8StrFmt("Firmware%c%s", 1672 RTPATH_DELIMITER, 1673 firmwareDesc[i].fileName); 1668 Utf8Str fullName; 1669 Utf8StrFmt shortName("Firmware%c%s", RTPATH_DELIMITER, firmwareDesc[i].pszFileName); 1674 1670 int rc = i_calculateFullPath(shortName, fullName); 1675 1671 AssertRCReturn(rc, VBOX_E_IPRT_ERROR); … … 1681 1677 } 1682 1678 1683 char pszVBoxPath[RTPATH_MAX];1684 rc = RTPathExecDir( pszVBoxPath, RTPATH_MAX);1679 char szVBoxPath[RTPATH_MAX]; 1680 rc = RTPathExecDir(szVBoxPath, RTPATH_MAX); 1685 1681 AssertRCReturn(rc, VBOX_E_IPRT_ERROR); 1686 fullName = Utf8StrFmt("%s%c%s", 1687 pszVBoxPath, 1688 RTPATH_DELIMITER, 1689 firmwareDesc[i].fileName); 1690 if (RTFileExists(fullName.c_str())) 1682 rc = RTPathAppend(szVBoxPath, sizeof(szVBoxPath), firmwareDesc[i].pszFileName); 1683 if (RTFileExists(szVBoxPath)) 1691 1684 { 1692 1685 *aResult = TRUE; 1693 aFile = fullName;1686 aFile = szVBoxPath; 1694 1687 break; 1695 1688 } 1696 1689 1697 1690 /** @todo account for version in the URL */ 1698 aUrl = firmwareDesc[i]. url;1691 aUrl = firmwareDesc[i].pszUrl; 1699 1692 *aResult = FALSE; 1700 1693
Note:
See TracChangeset
for help on using the changeset viewer.