Skip to content

Commit 083b863

Browse files
committed
prepare for sequoia
Signed-off-by: Slice <[email protected]>
1 parent f3d43d9 commit 083b863

File tree

9 files changed

+44
-20
lines changed

9 files changed

+44
-20
lines changed

rEFIt_UEFI/Platform/AcpiPatcher.cpp

Lines changed: 26 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -306,22 +306,25 @@ void GetAcpiTablesList()
306306
UINT32 Count = XsdtTableCount();
307307
UINT64* Ptr = XsdtEntryPtrFromIndex(0);
308308
UINT64* EndPtr = XsdtEntryPtrFromIndex(Count);
309-
DBG("from XSDT:\n");
309+
DBG("from XSDT: count=%u\n", Count);
310310
for (; Ptr < EndPtr; Ptr++) {
311311
EFI_ACPI_DESCRIPTION_HEADER* Table = (EFI_ACPI_DESCRIPTION_HEADER*)(UINTN)ReadUnaligned64(Ptr);
312+
// DBG("X: Table=%16llX\n", (UINTN)Table);
312313
if (!Table) {
313314
// skip NULL entry
314315
continue;
315316
}
316317
AddDropTable(Table, IndexFromXsdtEntryPtr(Ptr));
317318
}
318319
} else if (Rsdt) {
319-
DBG("from RSDT:\n");
320+
320321
UINT32 Count = RsdtTableCount();
322+
DBG("from RSDT: count=%u\n", Count);
321323
UINT32* Ptr = RsdtEntryPtrFromIndex(0);
322324
UINT32* EndPtr = RsdtEntryPtrFromIndex(Count);
323325
for (; Ptr < EndPtr; Ptr++) {
324326
EFI_ACPI_DESCRIPTION_HEADER* Table = (EFI_ACPI_DESCRIPTION_HEADER*)(UINTN)*Ptr;
327+
// DBG("R: Table=%16llX\n", (UINTN)Table);
325328
if (!Table) {
326329
// skip NULL entry
327330
continue;
@@ -1239,16 +1242,26 @@ EFI_ACPI_2_0_FIXED_ACPI_DESCRIPTION_TABLE* GetFadt()
12391242
// EFI_STATUS Status;
12401243

12411244
RsdPtr = (__typeof__(RsdPtr))FindAcpiRsdPtr();
1245+
// DBG("0: RsdPtr=%16llX\n", (UINTN)RsdPtr);
12421246
if (RsdPtr == NULL) {
12431247
/*Status = */EfiGetSystemConfigurationTable (&gEfiAcpi20TableGuid, (void **)&RsdPtr);
12441248
if (RsdPtr == NULL) {
12451249
/*Status = */EfiGetSystemConfigurationTable (&gEfiAcpi10TableGuid, (void **)&RsdPtr);
1250+
// DBG("1: RsdPtr=%16llX\n", (UINTN)RsdPtr);
12461251
if (RsdPtr == NULL) {
12471252
return NULL;
12481253
}
12491254
}
12501255
}
1256+
// DBG("2: RsdPtr=%16llX\n", (UINTN)RsdPtr);
1257+
// DBG(" Rsdt=%08X\n", (UINT32)(RsdPtr->RsdtAddress));
1258+
// DBG(" Xsdt=%16llX\n", (UINTN)(RsdPtr->XsdtAddress)); //==0
1259+
// DBG(" RsdPtr->Revision=%16llX\n", (UINTN)(RsdPtr->Revision)); //==0
1260+
12511261
Rsdt = (RSDT_TABLE*)(UINTN)(RsdPtr->RsdtAddress);
1262+
// if (Rsdt) {
1263+
// DBG(" Rsdt->Header.Signature=%16llX\n", (UINTN)(Rsdt->Header.Signature));
1264+
// }
12521265
if (RsdPtr->Revision > 0) {
12531266
if (Rsdt == NULL || Rsdt->Header.Signature != EFI_ACPI_2_0_ROOT_SYSTEM_DESCRIPTION_TABLE_SIGNATURE) {
12541267
Xsdt = (XSDT_TABLE *)(UINTN)(RsdPtr->XsdtAddress);
@@ -1262,6 +1275,17 @@ EFI_ACPI_2_0_FIXED_ACPI_DESCRIPTION_TABLE* GetFadt()
12621275
/*Status = */EfiGetSystemConfigurationTable (&gEfiAcpi20TableGuid, (void**)&RsdPtr);
12631276
if (RsdPtr != NULL) {
12641277
DBG("Found UEFI Acpi 2.0 RSDP at %llx\n", (uintptr_t)RsdPtr);
1278+
1279+
// DBG("3: RsdPtr=%16llX\n", (UINTN)RsdPtr);
1280+
// DBG(" Rsdt=%08X\n", (UINT32)(RsdPtr->RsdtAddress));
1281+
// DBG(" Xsdt=%16llX\n", (UINTN)(RsdPtr->XsdtAddress));
1282+
// DBG(" RsdPtr->Revision=%16llX\n", (UINTN)(RsdPtr->Revision));
1283+
1284+
Rsdt = (RSDT_TABLE*)(UINTN)(RsdPtr->RsdtAddress);
1285+
// if (Rsdt) {
1286+
// DBG(" Rsdt->Header.Signature=%16llX\n", (UINTN)(Rsdt->Header.Signature));
1287+
// }
1288+
12651289
Rsdt = (RSDT_TABLE*)(UINTN)(RsdPtr->RsdtAddress);
12661290
if (RsdPtr->Revision > 0) {
12671291
if (Rsdt == NULL || Rsdt->Header.Signature != EFI_ACPI_2_0_ROOT_SYSTEM_DESCRIPTION_TABLE_SIGNATURE) {

rEFIt_UEFI/Platform/StartupSound.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -239,7 +239,7 @@ StartupSoundPlay(const EFI_FILE* Dir, CONST CHAR16* SoundFile)
239239
// and we can't free memory up to stop AsyncPlay
240240
FreeAlignedPages(WaveData.Samples, EFI_SIZE_TO_PAGES(WaveData.SamplesLength + 4095));
241241
}
242-
DBG("sound play end with status=%s\n", efiStrError(Status));
242+
// DBG("sound play end with status=%s\n", efiStrError(Status));
243243
return Status;
244244
}
245245

rEFIt_UEFI/Settings/ConfigPlist/ConfigPlistClass.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ class ConfigPlistClass : public ConfigPlistAbstractClass
8989
SmbiosPlistClass::SmbiosDictClass SMBIOS_monterey = SmbiosPlistClass::SmbiosDictClass();
9090
SmbiosPlistClass::SmbiosDictClass SMBIOS_ventura = SmbiosPlistClass::SmbiosDictClass();
9191
SmbiosPlistClass::SmbiosDictClass SMBIOS_sonoma = SmbiosPlistClass::SmbiosDictClass();
92-
SmbiosPlistClass::SmbiosDictClass SMBIOS_fifteen = SmbiosPlistClass::SmbiosDictClass();
92+
SmbiosPlistClass::SmbiosDictClass SMBIOS_sequoia = SmbiosPlistClass::SmbiosDictClass();
9393
// SmbiosPlistClass::SmbiosDictClass SMBIOS_lion = SmbiosPlistClass::SmbiosDictClass();
9494
public:
9595
SystemParameters_Class SystemParameters = SystemParameters_Class();
@@ -120,7 +120,7 @@ class ConfigPlistClass : public ConfigPlistAbstractClass
120120
{"SMBIOS_monterey", SMBIOS_monterey},
121121
{"SMBIOS_ventura", SMBIOS_ventura},
122122
{"SMBIOS_sonoma", SMBIOS_sonoma},
123-
{"SMBIOS_fifteen", SMBIOS_fifteen},
123+
{"SMBIOS_sequoia", SMBIOS_sequoia},
124124
{"SystemParameters", SystemParameters},
125125
{"RtVariables", RtVariables},
126126
{"Quirks", Quirks},

rEFIt_UEFI/Settings/ConfigPlist/SMBIOSPlist.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -761,7 +761,7 @@ class SmbiosPlistClass : public ConfigPlistAbstractClass
761761
SmbiosDictClass SMBIOS_monterey = SmbiosDictClass();
762762
SmbiosDictClass SMBIOS_ventura = SmbiosDictClass();
763763
SmbiosDictClass SMBIOS_sonoma = SmbiosDictClass();
764-
SmbiosDictClass SMBIOS_fifteen = SmbiosDictClass();
764+
SmbiosDictClass SMBIOS_sequoia = SmbiosDictClass();
765765

766766
XmlDictField m_fields[15] = {
767767
{"SMBIOS", SMBIOS},
@@ -778,7 +778,7 @@ class SmbiosPlistClass : public ConfigPlistAbstractClass
778778
{"SMBIOS_monterey", SMBIOS_monterey},
779779
{"SMBIOS_ventura", SMBIOS_ventura},
780780
{"SMBIOS_sonoma", SMBIOS_sonoma},
781-
{"SMBIOS_fifteen", SMBIOS_fifteen},
781+
{"SMBIOS_sequoia", SMBIOS_sequoia},
782782
};
783783

784784
public:

rEFIt_UEFI/entry_scan/loader.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -587,7 +587,7 @@ MacOsVersion GetOSVersion(int LoaderType, const EFI_GUID& APFSTargetUUID, const
587587
OSVersion = "13"_XS8;
588588
} else if ( Prop->getString()->stringValue().contains("Install%20macOS%20Sonoma") || Prop->getString()->stringValue().contains("Install%20macOS%2014")) {
589589
OSVersion = "14"_XS8;
590-
} else if ( Prop->getString()->stringValue().contains("Install%20macOS%20Fifteen") || Prop->getString()->stringValue().contains("Install%20macOS%2015")) {
590+
} else if ( Prop->getString()->stringValue().contains("Install%20macOS%20Sequoia") || Prop->getString()->stringValue().contains("Install%20macOS%2015")) {
591591
OSVersion = "15"_XS8;
592592
} else if ( Prop->getString()->stringValue().contains("Install%20macOS%2010.16")) {
593593
OSVersion = "10.16"_XS8;
@@ -842,8 +842,8 @@ GetOSIconName (const MacOsVersion& OSVersion)
842842
if (OSVersion.isEmpty()) {
843843
OSIconName = L"mac"_XSW;
844844
} else if (OSVersion.elementAt(0) == 15 ){
845-
// Fifteen
846-
OSIconName = L"fifteen,mac"_XSW;
845+
// Sequoia
846+
OSIconName = L"sequoia,mac"_XSW;
847847
} else if (OSVersion.elementAt(0) == 14 ){
848848
// Sonoma
849849
OSIconName = L"sonoma,mac"_XSW;

rEFIt_UEFI/libeg/XIcon.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ CONST LString8 IconsNames[] = {
8686
"os_monterey", //54 == ICON_MONTEREY
8787
"os_ventura", //55 == ICON_VENTURA
8888
"os_sonoma", //56 == ICON_SONOMA
89-
"os_fifteen", //57 == ICON_FIFTEEN
89+
"os_sequoia", //57 == ICON_SEQUOIA
9090
""
9191
};
9292
const INTN IconsNamesSize = sizeof(IconsNames) / sizeof(IconsNames[0]);

rEFIt_UEFI/libeg/XTheme.cpp

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -138,11 +138,11 @@ EFI_STATUS Status = EFI_NOT_FOUND;
138138
ThemeDict = ThemeX->LoadTheme(XStringW(ThemeNameArray[Rnd]));
139139
} else {
140140
ThemeDict = ThemeX->LoadTheme(gSettings.GUI.Theme);
141-
if (ThemeDict == NULL) {
142-
DBG("GlobalConfig: %ls not found, get embedded theme\n", gSettings.GUI.Theme.wc_str());
143-
} else {
144-
DBG("chosen theme %ls\n", gSettings.GUI.Theme.wc_str());
145-
}
141+
// if (ThemeDict == NULL) {
142+
// DBG("GlobalConfig: %ls not found, get embedded theme\n", gSettings.GUI.Theme.wc_str());
143+
// } else {
144+
// DBG("chosen theme %ls\n", gSettings.GUI.Theme.wc_str());
145+
// }
146146
}
147147
}
148148
}

rEFIt_UEFI/refit/lib.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -364,7 +364,7 @@ void DebugPause(void);
364364
#define ICON_MONTEREY (54)
365365
#define ICON_VENTURA (55)
366366
#define ICON_SONOMA (56)
367-
#define ICON_FIFTEEN (57)
367+
#define ICON_SEQUOIA (57)
368368
#define BUILTIN_ICON_BACKGROUND (100)
369369
#define BUILTIN_ICON_SELECTION (101)
370370
#define BUILTIN_ICON_ANIME (102)

rEFIt_UEFI/refit/main.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1242,7 +1242,7 @@ void LOADER_ENTRY::StartLoader()
12421242
if ( FileExists(&self.getCloverDir(), bundleFullPath) ) {
12431243
XString8 bundlePathUnderKextsDir = S8Printf("%ls\\%ls", KextEntry.KextDirNameUnderOEMPath.wc_str(), KextEntry.FileName.wc_str());
12441244
OC_STRING_ASSIGN(mOpenCoreConfiguration.Kernel.Add.Values[kextIdx]->BundlePath, bundlePathUnderKextsDir.c_str());
1245-
DBG("OC BundlePath = '%s'\n", OC_BLOB_GET(&mOpenCoreConfiguration.Kernel.Add.Values[kextIdx]->BundlePath));
1245+
// DBG("OC BundlePath = '%s'\n", OC_BLOB_GET(&mOpenCoreConfiguration.Kernel.Add.Values[kextIdx]->BundlePath));
12461246
} else {
12471247
DBG("Cannot find kext bundlePath at '%s'\n", bundleFullPath.c_str());
12481248
}
@@ -1260,15 +1260,15 @@ void LOADER_ENTRY::StartLoader()
12601260
} else {
12611261
OC_STRING_ASSIGN(mOpenCoreConfiguration.Kernel.Add.Values[kextIdx]->PlistPath, "Contents\\Info.plist");
12621262
}
1263-
DBG("OC PlistPath = '%s'\n", OC_BLOB_GET(&mOpenCoreConfiguration.Kernel.Add.Values[kextIdx]->PlistPath));
1263+
// DBG("OC PlistPath = '%s'\n", OC_BLOB_GET(&mOpenCoreConfiguration.Kernel.Add.Values[kextIdx]->PlistPath));
12641264
} else {
12651265
DBG("Cannot find kext info.plist at '%ls'\n", KextEntry.FileName.wc_str());
12661266
}
12671267
TagDict* dict = getInfoPlist(&self.getCloverDir(), infoPlistPathRelToSelf);
12681268
XString8 execpath = getKextExecPath(&self.getCloverDir(), KextEntry.KextDirNameUnderOEMPath, KextEntry.FileName, dict, NoContents);
12691269
if (execpath.notEmpty()) {
12701270
OC_STRING_ASSIGN(mOpenCoreConfiguration.Kernel.Add.Values[kextIdx]->ExecutablePath, execpath.c_str());
1271-
DBG("OC ExecutablePath = '%s'\n", execpath.c_str());
1271+
// DBG("OC ExecutablePath = '%s'\n", execpath.c_str());
12721272
}
12731273
if ( dict ) dict->ReleaseTag();
12741274
}

0 commit comments

Comments
 (0)