[PATCH] x86/reboot: use EFI reboot on ThinkPad X1 Carbon 5th

Marek Marczykowski-Górecki posted 1 patch 1 month ago
arch/x86/kernel/reboot.c | 11 +++++++++++
1 file changed, 11 insertions(+)
[PATCH] x86/reboot: use EFI reboot on ThinkPad X1 Carbon 5th
Posted by Marek Marczykowski-Górecki 1 month ago
This laptop needs EFI reboot to respect BootNext variable, otherwise it
uses just BootOrder on reboot.

Signed-off-by: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com>
---
 arch/x86/kernel/reboot.c | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/arch/x86/kernel/reboot.c b/arch/x86/kernel/reboot.c
index 6032fa9ec753..97d139a6d7e5 100644
--- a/arch/x86/kernel/reboot.c
+++ b/arch/x86/kernel/reboot.c
@@ -471,6 +471,17 @@ static const struct dmi_system_id reboot_dmi_table[] __initconst = {
 		},
 	},
 
+	/* Lenovo */
+	{
+		/* BootNext EFI variable is not respected without EFI reboot */
+		.callback = set_efi_reboot,
+		.ident = "Lenovo ThinkPad X1 Carbon 5th",
+		.matches = {
+			DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
+			DMI_MATCH(DMI_PRODUCT_VERSION, "ThinkPad X1 Carbon 5th"),
+		},
+	},
+
 	{	/* PCIe Wifi card isn't detected after reboot otherwise */
 		.callback = set_pci_reboot,
 		.ident = "Zotac ZBOX CI327 nano",
-- 
2.52.0