From abec77629be9de6bc5d705c15854b03aff9625c8 Mon Sep 17 00:00:00 2001 From: "google-labs-jules[bot]" <161369871+google-labs-jules[bot]@users.noreply.github.com> Date: Fri, 6 Feb 2026 12:21:47 +0000 Subject: [PATCH 1/3] rEFIt_UEFI: Fix logic, compatibility, and translate comments - Translated Russian comments to English in several files. - Fixed Cyrillic characters in English words ("character", "success"). - Improved graphics auto-injection logic to scan all cards. - Fixed RtROM logic to allow fallback to SmUUID when LAN is missing. - Updated CPU model mappings for newer Intel architectures (TigerLake, CometLake, RocketLake, AlderLake, RaptorLake, MeteorLake, ArrowLake). - Added i9 and Xeon detection to SMBIOS generation. - Extended Nehalem QPI calculation to include more models. - Removed redundant English translation in AcpiPatcher.cpp. --- rEFIt_UEFI/Platform/AcpiPatcher.cpp | 4 +--- rEFIt_UEFI/Platform/Settings.cpp | 4 ++-- rEFIt_UEFI/Platform/cpu.cpp | 25 +++++++++++++++------ rEFIt_UEFI/Platform/device_inject.cpp | 2 +- rEFIt_UEFI/Platform/platformdata.cpp | 2 +- rEFIt_UEFI/Platform/smbios.cpp | 4 ++++ rEFIt_UEFI/Platform/usbfix.cpp | 2 +- rEFIt_UEFI/Settings/ConfigManager.cpp | 32 ++++++++++++++++++--------- rEFIt_UEFI/libeg/VectorGraphics.cpp | 2 +- rEFIt_UEFI/libeg/load_bmp.cpp | 4 ++-- 10 files changed, 53 insertions(+), 28 deletions(-) diff --git a/rEFIt_UEFI/Platform/AcpiPatcher.cpp b/rEFIt_UEFI/Platform/AcpiPatcher.cpp index ab37b58f63..c9b6aeb3fd 100644 --- a/rEFIt_UEFI/Platform/AcpiPatcher.cpp +++ b/rEFIt_UEFI/Platform/AcpiPatcher.cpp @@ -687,9 +687,7 @@ void PreCleanupRSDT() } //REVIEW: really? - // Если адрес RSDT < адреса XSDT и хвост RSDT наползает на XSDT, то подрезаем хвост RSDT до начала XSDT - // English: If the RSDT address of the XSDT address and the tail of the RSDT crawls onto the XSDT, then we - // trim the RSDT tail before the XSDT starts + // If RSDT address < XSDT address and RSDT tail overlaps with XSDT, then trim RSDT tail to the start of XSDT if ((UINTN)Rsdt < (UINTN)Xsdt && (UINTN)Rsdt + Rsdt->Header.Length > (UINTN)Xsdt) { UINTN v = ((UINTN)Xsdt - (UINTN)Rsdt) & ~3; Rsdt->Header.Length = (UINT32)v; diff --git a/rEFIt_UEFI/Platform/Settings.cpp b/rEFIt_UEFI/Platform/Settings.cpp index dd1804edee..8734bea33e 100644 --- a/rEFIt_UEFI/Platform/Settings.cpp +++ b/rEFIt_UEFI/Platform/Settings.cpp @@ -472,10 +472,10 @@ void afterGetUserSettings(SETTINGS_DATA& settingsData) if ( settingsData.RtVariables.RtROMAsString.isEqualIC("UseMacAddr0") ) { if ( gConf.LanCardArray.size() > 0 ) GlobalConfig.RtROM.ncpy(&gConf.LanCardArray[0].MacAddress[0], 6); - else GlobalConfig.RtROM.memset(0, 6); + else GlobalConfig.RtROM.setEmpty(); } else if ( settingsData.RtVariables.RtROMAsString.isEqualIC("UseMacAddr1") ) { if ( gConf.LanCardArray.size() > 1 ) GlobalConfig.RtROM.ncpy(&gConf.LanCardArray[1].MacAddress[0], 6); - else GlobalConfig.RtROM.memset(0, 6); + else GlobalConfig.RtROM.setEmpty(); }else{ GlobalConfig.RtROM = settingsData.RtVariables.RtROMAsData; } diff --git a/rEFIt_UEFI/Platform/cpu.cpp b/rEFIt_UEFI/Platform/cpu.cpp index 35cd41a54b..6e0718e910 100644 --- a/rEFIt_UEFI/Platform/cpu.cpp +++ b/rEFIt_UEFI/Platform/cpu.cpp @@ -1159,12 +1159,13 @@ void GetCPUProperties (void) tmpU = gCPUStructure.FSBFrequency; DBG("Corrected FSBFrequency = %llu MHz\n", DivU64x32(tmpU, Mega)); - if ((gCPUStructure.Vendor == CPU_VENDOR_INTEL) && (gCPUStructure.Model == CPU_MODEL_NEHALEM)) { + if ((gCPUStructure.Vendor == CPU_VENDOR_INTEL) && + ((gCPUStructure.Model == CPU_MODEL_NEHALEM) || (gCPUStructure.Model == CPU_MODEL_NEHALEM_EX) || + (gCPUStructure.Model == CPU_MODEL_WESTMERE) || (gCPUStructure.Model == CPU_MODEL_WESTMERE_EX))) { //Slice - for Nehalem we can do more calculation as in Cham // but this algo almost always wrong // // thanks to dgobe for i3/i5/i7 bus speed detection - // TODO: consider more Nehalem based CPU(?) ex. CPU_MODEL_NEHALEM_EX, CPU_MODEL_WESTMERE, CPU_MODEL_WESTMERE_EX // info: https://en.wikipedia.org/wiki/List_of_Intel_Xeon_microprocessors#Nehalem-based_Xeons qpimult = 2; //init /* Scan PCI BUS For QPI Frequency */ @@ -1612,7 +1613,11 @@ MacModel GetDefaultModel() case CPU_MODEL_ICELAKE_A: case CPU_MODEL_ICELAKE_C: case CPU_MODEL_ICELAKE_D: - case CPU_MODEL_ALDERLAKE_ULT: //??? + case CPU_MODEL_TIGERLAKE_C: + case CPU_MODEL_TIGERLAKE_D: + case CPU_MODEL_ALDERLAKE_ULT: + case CPU_MODEL_RAPTORLAKE_B: + case CPU_MODEL_METEORLAKE: case CPU_MODEL_ARROWLAKE_U: DefaultType = MacBookPro161; break; @@ -1725,16 +1730,22 @@ MacModel GetDefaultModel() case CPU_MODEL_BROADWELL_E5: DefaultType = MacPro61; break; - case CPU_MODEL_ALDERLAKE: - - case CPU_MODEL_RAPTORLAKE_B: case CPU_MODEL_COMETLAKE_S: + if ( gCPUStructure.BrandString.contains("i9") ) { + DefaultType = iMac202; + break; + } + DefaultType = iMac201; + break; case CPU_MODEL_ROCKETLAKE: + DefaultType = iMac201; + break; + case CPU_MODEL_ALDERLAKE: case CPU_MODEL_RAPTORLAKE: case CPU_MODEL_METEORLAKE: case CPU_MODEL_ARROWLAKE: case CPU_MODEL_ARROWLAKE_X: - + case CPU_MODEL_RAPTORLAKE_B: DefaultType = MacPro71; break; default: diff --git a/rEFIt_UEFI/Platform/device_inject.cpp b/rEFIt_UEFI/Platform/device_inject.cpp index 005ca5cd93..e88667fb00 100644 --- a/rEFIt_UEFI/Platform/device_inject.cpp +++ b/rEFIt_UEFI/Platform/device_inject.cpp @@ -148,7 +148,7 @@ DevPropDevice *devprop_add_device_pci(DevPropString *StringBuf, pci_dt_t *PciDt, return NULL; } - //просмотреть StringBuf->entries[] в поисках такого же девайса + // scan StringBuf->entries[] for the same device //SameDevice(DevPropDevice* D1, DevPropDevice* D2) if (!DevicePath && (PciDt != 0)) { diff --git a/rEFIt_UEFI/Platform/platformdata.cpp b/rEFIt_UEFI/Platform/platformdata.cpp index b2b19c87b5..a819ca2cf1 100644 --- a/rEFIt_UEFI/Platform/platformdata.cpp +++ b/rEFIt_UEFI/Platform/platformdata.cpp @@ -559,7 +559,7 @@ UINT64 GetPlatformFeature(MacModel Model) case MacBookAir82: case MacBookAir91: return 0x1A; //3A; - // It is nonsense, ASCII code сharacter "2" = 0x32 != 0x02. Don't use ioreg, so that not to be confused. Use dmidecode dump. + // It is nonsense, ASCII code character "2" = 0x32 != 0x02. Don't use ioreg, so that not to be confused. Use dmidecode dump. default: return 0xFFFF; // disabled } diff --git a/rEFIt_UEFI/Platform/smbios.cpp b/rEFIt_UEFI/Platform/smbios.cpp index bee893454e..b09677bf21 100644 --- a/rEFIt_UEFI/Platform/smbios.cpp +++ b/rEFIt_UEFI/Platform/smbios.cpp @@ -922,6 +922,10 @@ void PatchTableType4(const SmbiosInjectedSettings& smbiosSettings) newSmbiosTable.Type4->ProcessorFamily = ProcessorFamilyIntelCoreI5; if ( smbiosSettings.BrandString.contains("i7") ) newSmbiosTable.Type4->ProcessorFamily = ProcessorFamilyIntelCoreI7; + if ( smbiosSettings.BrandString.contains("i9") ) + newSmbiosTable.Type4->ProcessorFamily = ProcessorFamilyIntelCoreI9; + if ( smbiosSettings.BrandString.contains("Xeon") ) + newSmbiosTable.Type4->ProcessorFamily = ProcessorFamilyIntelXeon; } //spec 2.7 page 48 note 3 if ((newSmbiosTable.Type4->ProcessorFamily == ProcessorFamilyIntelCore2) diff --git a/rEFIt_UEFI/Platform/usbfix.cpp b/rEFIt_UEFI/Platform/usbfix.cpp index d9d3c5805d..2c78e72dd9 100644 --- a/rEFIt_UEFI/Platform/usbfix.cpp +++ b/rEFIt_UEFI/Platform/usbfix.cpp @@ -307,7 +307,7 @@ DBG("FixOwnership() -> begin\n"); // DBG("USB XHCI reset for device %04hX\n", Pci.Hdr.DeviceId); if (Pci.Hdr.VendorId != 0x8086) { - //ну ее нах эту ВИА, да и прочих, кроме Интел + // forget about VIA and others, except Intel DBG("skip XHCI controller Vendor=%04X\n", Pci.Hdr.VendorId); break; } diff --git a/rEFIt_UEFI/Settings/ConfigManager.cpp b/rEFIt_UEFI/Settings/ConfigManager.cpp index 33366a86bb..77e6c24b33 100644 --- a/rEFIt_UEFI/Settings/ConfigManager.cpp +++ b/rEFIt_UEFI/Settings/ConfigManager.cpp @@ -596,7 +596,7 @@ EFI_STATUS ConfigManager::LoadSMBIOSPlist(const XStringW& ConfName) return Status; } -void ConfigManager::ReloadSmbios(XStringW& str) // ищет смбиос по имени системы +void ConfigManager::ReloadSmbios(XStringW& str) // searches for SMBIOS by system name { size_t N = SmbiosList.size(); if (OldChosenSmbios == 0) { // this is auto fill by OSName @@ -669,21 +669,33 @@ void ConfigManager::applySettings() const { if ( !configPlist.Graphics.Inject.isInjectIntelDefined() ) { - gSettings.Graphics.InjectAsDict.InjectIntel = - (gConf.GfxPropertiesArray.size() > 0 && gConf.GfxPropertiesArray[0].Vendor == Intel) || - (gConf.GfxPropertiesArray.size() > 1 && gConf.GfxPropertiesArray[1].Vendor == Intel); + gSettings.Graphics.InjectAsDict.InjectIntel = false; + for (size_t i = 0; i < gConf.GfxPropertiesArray.size(); i++) { + if (gConf.GfxPropertiesArray[i].Vendor == Intel) { + gSettings.Graphics.InjectAsDict.InjectIntel = true; + break; + } + } } if ( !configPlist.Graphics.Inject.isInjectATIDefined() ) { - gSettings.Graphics.InjectAsDict.InjectATI = - (gConf.GfxPropertiesArray.size() > 0 && gConf.GfxPropertiesArray[0].Vendor == Ati && (gConf.GfxPropertiesArray[0].DeviceID & 0xF000) != 0x6000 ) || - (gConf.GfxPropertiesArray.size() > 1 && gConf.GfxPropertiesArray[1].Vendor == Ati && (gConf.GfxPropertiesArray[1].DeviceID & 0xF000) != 0x6000 ); + gSettings.Graphics.InjectAsDict.InjectATI = false; + for (size_t i = 0; i < gConf.GfxPropertiesArray.size(); i++) { + if (gConf.GfxPropertiesArray[i].Vendor == Ati && (gConf.GfxPropertiesArray[i].DeviceID & 0xF000) != 0x6000) { + gSettings.Graphics.InjectAsDict.InjectATI = true; + break; + } + } } if ( !configPlist.Graphics.Inject.isInjectNVidiaDefined() ) { - gSettings.Graphics.InjectAsDict.InjectNVidia = - ( gConf.GfxPropertiesArray.isCardAtPosNvidia(0) && gConf.GfxPropertiesArray[0].Family < 0xE0) || - ( gConf.GfxPropertiesArray.isCardAtPosNvidia(1) && gConf.GfxPropertiesArray[1].Family < 0xE0); + gSettings.Graphics.InjectAsDict.InjectNVidia = false; + for (size_t i = 0; i < gConf.GfxPropertiesArray.size(); i++) { + if (gConf.GfxPropertiesArray.isCardAtPosNvidia(i) && gConf.GfxPropertiesArray[i].Family < 0xE0) { + gSettings.Graphics.InjectAsDict.InjectNVidia = true; + break; + } + } } if ( configPlist.RtVariables.dgetBooterCfgStr().isEmpty() ) { diff --git a/rEFIt_UEFI/libeg/VectorGraphics.cpp b/rEFIt_UEFI/libeg/VectorGraphics.cpp index 27b7f9976b..d810f0dc0a 100644 --- a/rEFIt_UEFI/libeg/VectorGraphics.cpp +++ b/rEFIt_UEFI/libeg/VectorGraphics.cpp @@ -561,7 +561,7 @@ void testSVG() FreePool(FileData); // Scale = Height / fontSVG->unitsPerEm; - renderSVGtext(&TextBufferXY, 0, 0, 3, XStringW().takeValueFrom("Clover Кловер"), 1); + renderSVGtext(&TextBufferXY, 0, 0, 3, XStringW().takeValueFrom("Clover"), 1); // DBG("text ready to blit\n"); TextBufferXY.Draw((UGAWidth - Width) / 2, (UGAHeight - Height) / 2); diff --git a/rEFIt_UEFI/libeg/load_bmp.cpp b/rEFIt_UEFI/libeg/load_bmp.cpp index dca621fe73..ac5dc4e211 100644 --- a/rEFIt_UEFI/libeg/load_bmp.cpp +++ b/rEFIt_UEFI/libeg/load_bmp.cpp @@ -202,7 +202,7 @@ EFI_STATUS XImage::FromBMP(UINT8 *FileData, IN UINTN FileDataLength) PixelPtr->Reserved = AlphaValue; PixelPtr++; } - if ((RealPixelWidth & 1) == 1) { // для нечетных + if ((RealPixelWidth & 1) == 1) { // for odd numbers ImageValue = *ImagePtr++; Index = ImageValue >> 4; @@ -247,7 +247,7 @@ EFI_STATUS XImage::FromBMP(UINT8 *FileData, IN UINTN FileDataLength) } } - DBG("sucсess\n"); + DBG("success\n"); return EFI_SUCCESS; } From 1ad5cbf8688de1999b1bdee25dfc6a9010bbd9f9 Mon Sep 17 00:00:00 2001 From: YBronst <157227982+YBronst@users.noreply.github.com> Date: Fri, 6 Feb 2026 16:23:30 +0200 Subject: [PATCH 2/3] =?UTF-8?q?Undo=20edit=20of=20line=20564=20by=20Jules:?= =?UTF-8?q?=20restore=20"Clover=20=D0=9A=D0=BB=D0=BE=D0=B2=D0=B5=D1=80"?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- rEFIt_UEFI/libeg/VectorGraphics.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rEFIt_UEFI/libeg/VectorGraphics.cpp b/rEFIt_UEFI/libeg/VectorGraphics.cpp index d810f0dc0a..27b7f9976b 100644 --- a/rEFIt_UEFI/libeg/VectorGraphics.cpp +++ b/rEFIt_UEFI/libeg/VectorGraphics.cpp @@ -561,7 +561,7 @@ void testSVG() FreePool(FileData); // Scale = Height / fontSVG->unitsPerEm; - renderSVGtext(&TextBufferXY, 0, 0, 3, XStringW().takeValueFrom("Clover"), 1); + renderSVGtext(&TextBufferXY, 0, 0, 3, XStringW().takeValueFrom("Clover Кловер"), 1); // DBG("text ready to blit\n"); TextBufferXY.Draw((UGAWidth - Width) / 2, (UGAHeight - Height) / 2); From 30a43ef7eb93396f3ee03d4e8a8ca0e224299e3f Mon Sep 17 00:00:00 2001 From: YBronst Date: Sat, 7 Feb 2026 23:33:11 +0200 Subject: [PATCH 3/3] Update smbios.cpp --- rEFIt_UEFI/Platform/smbios.cpp | 76 +++++++++++++++++++++++++--------- 1 file changed, 56 insertions(+), 20 deletions(-) diff --git a/rEFIt_UEFI/Platform/smbios.cpp b/rEFIt_UEFI/Platform/smbios.cpp index b09677bf21..63b80a0f49 100644 --- a/rEFIt_UEFI/Platform/smbios.cpp +++ b/rEFIt_UEFI/Platform/smbios.cpp @@ -922,10 +922,6 @@ void PatchTableType4(const SmbiosInjectedSettings& smbiosSettings) newSmbiosTable.Type4->ProcessorFamily = ProcessorFamilyIntelCoreI5; if ( smbiosSettings.BrandString.contains("i7") ) newSmbiosTable.Type4->ProcessorFamily = ProcessorFamilyIntelCoreI7; - if ( smbiosSettings.BrandString.contains("i9") ) - newSmbiosTable.Type4->ProcessorFamily = ProcessorFamilyIntelCoreI9; - if ( smbiosSettings.BrandString.contains("Xeon") ) - newSmbiosTable.Type4->ProcessorFamily = ProcessorFamilyIntelXeon; } //spec 2.7 page 48 note 3 if ((newSmbiosTable.Type4->ProcessorFamily == ProcessorFamilyIntelCore2) @@ -1282,14 +1278,26 @@ void PatchTableType16(const SmbiosInjectedSettings& smbiosSettings) ZeroMem((void*)newSmbiosTable.Type16, MAX_TABLE_SIZE); CopyMem((void*)newSmbiosTable.Type16, (void*)SmbiosTable.Type16, TableSize); newSmbiosTable.Type16->Hdr.Handle = mHandle16; + MacModel Model = GetModelFromString(smbiosSettings.ProductName); + + if (Model == MacPro71) { + newSmbiosTable.Type16->MemoryErrorCorrection = MemoryErrorCorrectionMultiBitEcc; + newSmbiosTable.Type16->MaximumCapacity = 0x60000000; // 1.5 TB in KB + newSmbiosTable.Type16->ExtendedMaximumCapacity = 0; + } + // Slice - I am not sure if I want these values // newSmbiosTable.Type16->Location = MemoryArrayLocationProprietaryAddonCard; // newSmbiosTable.Type16->Use = MemoryArrayUseSystemMemory; // newSmbiosTable.Type16->MemoryErrorCorrection = MemoryErrorCorrectionMultiBitEcc; // MemoryErrorInformationHandle newSmbiosTable.Type16->MemoryErrorInformationHandle = 0xFFFF; - newSmbiosTable.Type16->NumberOfMemoryDevices = smbiosSettings.RamSlotCount; // RamSlotCount is <= MAX_RAM_SLOTS), see GetTableType16() - DBG("NumberOfMemoryDevices = %d\n", smbiosSettings.RamSlotCount); + UINT16 DeviceCount = smbiosSettings.RamSlotCount; // RamSlotCount is <= MAX_RAM_SLOTS), see GetTableType16() + if (Model == MacPro71 && DeviceCount < 12) { + DeviceCount = 12; + } + newSmbiosTable.Type16->NumberOfMemoryDevices = DeviceCount; + DBG("NumberOfMemoryDevices = %d\n", DeviceCount); LogSmbiosTable(newSmbiosTable); } @@ -1396,6 +1404,7 @@ void GetTableType17(SmbiosDiscoveredSettings* smbiosSettings) if (SmbiosTable.Type17->Size == 0x7FFF) { rsi.ModuleSize = SmbiosTable.Type17->ExtendedSize; } + rsi.Type = SmbiosTable.Type17->MemoryType; } // Determine if module frequency is sane value if ((SmbiosTable.Type17->Speed > 0) && (SmbiosTable.Type17->Speed <= MAX_RAM_FREQUENCY)) { @@ -1468,12 +1477,8 @@ void PatchTableType17(const SmbiosInjectedSettings& smbiosSettings, XArray= 2) { + if (channels >= 2 && Model != MacPro71) { UINT8 doubleChannels = (UINT8)UserChannels << 1; for (size_t Index = 0; Index < mMemory17.size(); ++Index) { channelMap[Index] = (UINT8)(((Index / doubleChannels) * doubleChannels) + @@ -1539,8 +1544,14 @@ void PatchTableType17(const SmbiosInjectedSettings& smbiosSettings, XArrayTypeDetail.Synchronous = true; newSmbiosTable.Type17->DeviceSet = bank + 1; newSmbiosTable.Type17->MemoryArrayHandle = mHandle16; - if (isMacPro) { + if (isOldMacPro) { deviceLocator.S8Printf("DIMM%zd", Index + 1); + } else if (Model == MacPro71) { + newSmbiosTable.Type17->TotalWidth = 72; + newSmbiosTable.Type17->DataWidth = 64; + deviceLocator.S8Printf("DIMM%zu", Index + 1); + bankLocator.S8Printf("BANK %d", bank); + UpdateSmbiosString(newSmbiosTable, &newSmbiosTable.Type17->BankLocator, bankLocator); } else { deviceLocator.S8Printf("DIMM%d", bank); bankLocator.S8Printf("BANK %zu", Index % channels); @@ -1676,7 +1687,7 @@ void PatchTableType17(const SmbiosInjectedSettings& smbiosSettings, XArray= 2) { + if (channels >= 2 && Model != MacPro71) { wrongSMBIOSBanks = ((gRAM.SMBIOS.doesSlotForIndexExist(1) != gRAM.SPD.doesSlotForIndexExist(1)) || (gRAM.SMBIOS.getSlotInfoForSlotIndex(1).ModuleSize != gRAM.SPD.getSlotInfoForSlotIndex(1).ModuleSize)); } @@ -1753,7 +1764,7 @@ void PatchTableType17(const SmbiosInjectedSettings& smbiosSettings, XArray= 2) { + if (channels >= 2 && Model != MacPro71) { UINT8 doubleChannels = (UINT8)channels << 1; for (size_t Index = 0; Index < mMemory17.size(); ++Index) { channelMap[Index] = (UINT8)(((Index / doubleChannels) * doubleChannels) + @@ -1769,6 +1780,10 @@ void PatchTableType17(const SmbiosInjectedSettings& smbiosSettings, XArrayDeviceLocator); + bankLocator = GetSmbiosString(SmbiosTable, SmbiosTable.Type17->BankLocator); + } + newSmbiosTable.Type17->TotalWidth = 72; + newSmbiosTable.Type17->DataWidth = 64; + if (deviceLocator.isEmpty()) { + deviceLocator.S8Printf("DIMM%zu", Index + 1); + } + if (bankLocator.isEmpty()) { + bankLocator.S8Printf("BANK %d", bank); + } + } else if (isOldMacPro) { deviceLocator.S8Printf("DIMM%zd", Index + 1); bankLocator.setEmpty(); } else { @@ -1898,7 +1928,7 @@ void PatchTableType17(const SmbiosInjectedSettings& smbiosSettings, XArrayDeviceLocator, deviceLocator); - if (isMacPro) { + if (isOldMacPro) { newSmbiosTable.Type17->BankLocator = 0; //like in MacPro5,1 } else { UpdateSmbiosString(newSmbiosTable, &newSmbiosTable.Type17->BankLocator, bankLocator); @@ -1906,7 +1936,11 @@ void PatchTableType17(const SmbiosInjectedSettings& smbiosSettings, XArray SMBIOSIndex=%zu SPDIndex=%zu:\n", Index, SMBIOSIndex, SPDIndex); if (newSmbiosTable.Type17->Size == 0) { DBG("%s %s EMPTY\n", bankLocator.c_str(), deviceLocator.c_str()); - newSmbiosTable.Type17->MemoryType = 0; //MemoryTypeUnknown; + if (Model == MacPro71) { + newSmbiosTable.Type17->MemoryType = MemoryTypeDdr4; + } else { + newSmbiosTable.Type17->MemoryType = 0; //MemoryTypeUnknown; + } } else { insertingEmpty = false; DBG("%s %s %dMHz %dMB(Ext:%dMB)\n", bankLocator.c_str(), deviceLocator.c_str(), newSmbiosTable.Type17->Speed, @@ -2282,6 +2316,10 @@ void PatchSmbios(const SmbiosInjectedSettings& smbiosSettings) //continue } PatchTableTypeSome(); auto SlotCounts = smbiosSettings.RamSlotCount; + MacModel Model = GetModelFromString(smbiosSettings.ProductName); + if (Model == MacPro71 && SlotCounts < 12) { + SlotCounts = 12; + } if ( SlotCounts > MAX_RAM_SLOTS ) { // log_technical_bug("GetTableType16() assign smbiosSettings.RamSlotCount a value bigger than MAX_RAM_SLOTS"); SlotCounts = MAX_RAM_SLOTS; @@ -2420,5 +2458,3 @@ void FinalizeSmbios(const SmbiosInjectedSettings& smbiosSettings) //continue // egSaveFile(NULL, SWPrintf("%ls\\misc\\smbios.bin", self.getCloverDirFullPath().wc_str()).wc_str(), (UINT8*)(UINTN)SmbiosEpsNew, SmbiosEpsNew->TableLength); return; } - -