]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/commitdiff
x86/reboot: Add Dell Optiplex 7450 AIO reboot quirk
authorAlex Hung <alex.hung@canonical.com>
Thu, 14 Jul 2016 10:05:56 +0000 (18:05 +0800)
committerIngo Molnar <mingo@kernel.org>
Thu, 14 Jul 2016 18:57:22 +0000 (20:57 +0200)
Dell Optiplex 7450 AIO works with BOOT_ACPI; however, the quirk for
"OptiPlex 745" changes its boot method to BOOT_BIOS and causes 7450 AIO
hangs when rebooting; as a result, 7450 AIO is appended to overwrite
BOOT_BIOS by BOOT_ACPI in order not to break the original 745 series

Signed-off-by: Alex Hung <alex.hung@canonical.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Ingo Molnar <mingo@kernel.org>
arch/x86/kernel/reboot.c

index a9b31eb815f23e93eae56960879448d7a63fba09..15ed70f8278b1b8f13e5e7852edb3987441c60b2 100644 (file)
@@ -54,6 +54,19 @@ bool port_cf9_safe = false;
  * Dell Inc. so their systems "just work". :-)
  */
 
+/*
+ * Some machines require the "reboot=a" commandline options
+ */
+static int __init set_acpi_reboot(const struct dmi_system_id *d)
+{
+       if (reboot_type != BOOT_ACPI) {
+               reboot_type = BOOT_ACPI;
+               pr_info("%s series board detected. Selecting %s-method for reboots.\n",
+                       d->ident, "ACPI");
+       }
+       return 0;
+}
+
 /*
  * Some machines require the "reboot=b" or "reboot=k"  commandline options,
  * this quirk makes that automatic.
@@ -395,6 +408,14 @@ static struct dmi_system_id __initdata reboot_dmi_table[] = {
                        DMI_MATCH(DMI_PRODUCT_NAME, "Dell XPS710"),
                },
        },
+       {       /* Handle problems with rebooting on Dell Optiplex 7450 AIO */
+               .callback = set_acpi_reboot,
+               .ident = "Dell OptiPlex 7450 AIO",
+               .matches = {
+                       DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."),
+                       DMI_MATCH(DMI_PRODUCT_NAME, "OptiPlex 7450 AIO"),
+               },
+       },
 
        /* Hewlett-Packard */
        {       /* Handle problems with rebooting on HP laptops */