From 6fea88655d8ef07b893b69de6bec044e4932d569 Mon Sep 17 00:00:00 2001 From: Hoang Hong Quan Date: Sun, 13 Oct 2024 10:01:50 +0700 Subject: [PATCH] Improve accuracy of HP brand check --- Scripts/acpi_guru.py | 2 +- Scripts/config_prodigy.py | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Scripts/acpi_guru.py b/Scripts/acpi_guru.py index a55f81d..973b93d 100644 --- a/Scripts/acpi_guru.py +++ b/Scripts/acpi_guru.py @@ -3023,7 +3023,7 @@ DefinitionBlock ("", "SSDT", 2, "ZPSS", "SURFACE", 0x00001000) selected_patches.append("FakeEC") - if "HP" in hardware_report.get("Motherboard").get("Name"): + if "HP " in hardware_report.get("Motherboard").get("Name"): selected_patches.append("CMOS") if "Laptop" in hardware_report.get("Motherboard").get("Platform") and self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("Codename"), start=26) or \ diff --git a/Scripts/config_prodigy.py b/Scripts/config_prodigy.py index 8138043..700e75f 100644 --- a/Scripts/config_prodigy.py +++ b/Scripts/config_prodigy.py @@ -497,8 +497,8 @@ class ConfigProdigy: config["Kernel"]["Quirks"]["AppleXcpmExtraMsrs"] = "-E" in hardware_report.get("CPU").get("Codename") and not self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("Codename"), start=26) is None config["Kernel"]["Quirks"]["CustomSMBIOSGuid"] = True config["Kernel"]["Quirks"]["DisableIoMapper"] = not "AMD" in hardware_report.get("CPU").get("Manufacturer") - config["Kernel"]["Quirks"]["DisableRtcChecksum"] = "ASUS" in hardware_report.get("Motherboard").get("Name") or "HP" in hardware_report.get("Motherboard").get("Name") - config["Kernel"]["Quirks"]["LapicKernelPanic"] = "HP" in hardware_report.get("Motherboard").get("Name") + config["Kernel"]["Quirks"]["DisableRtcChecksum"] = "ASUS" in hardware_report.get("Motherboard").get("Name") or "HP " in hardware_report.get("Motherboard").get("Name") + config["Kernel"]["Quirks"]["LapicKernelPanic"] = "HP " in hardware_report.get("Motherboard").get("Name") config["Kernel"]["Quirks"]["PanicNoKextDump"] = config["Kernel"]["Quirks"]["PowerTimeoutKernelPanic"] = True config["Kernel"]["Quirks"]["ProvideCurrentCpuInfo"] = "AMD" in hardware_report.get("CPU").get("Manufacturer") or \ not self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("Codename"), end=2) is None @@ -532,7 +532,7 @@ class ConfigProdigy: config["UEFI"]["Drivers"] = self.load_drivers() config["UEFI"]["Quirks"]["IgnoreInvalidFlexRatio"] = not self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("Codename"), start=26) is None config["UEFI"]["Quirks"]["ReleaseUsbOwnership"] = True - config["UEFI"]["Quirks"]["UnblockFsConnect"] = "HP" in hardware_report.get("Motherboard").get("Name") + config["UEFI"]["Quirks"]["UnblockFsConnect"] = "HP " in hardware_report.get("Motherboard").get("Name") config["UEFI"]["ReservedMemory"] = [] for kext in kexts: