]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/blobdiff - arch/x86/power/cpu.c
x86/entry: Fix assumptions that the HW TSS is at the beginning of cpu_tss
[mirror_ubuntu-bionic-kernel.git] / arch / x86 / power / cpu.c
index 4d68d59f457d5aa0a2913cc1c31b4272efc50aa0..50593e13828109986b61d5aa8eb7671a9040b232 100644 (file)
@@ -165,12 +165,13 @@ static void fix_processor_context(void)
        struct desc_struct *desc = get_cpu_gdt_rw(cpu);
        tss_desc tss;
 #endif
-       set_tss_desc(cpu, t);   /*
-                                * This just modifies memory; should not be
-                                * necessary. But... This is necessary, because
-                                * 386 hardware has concept of busy TSS or some
-                                * similar stupidity.
-                                */
+
+       /*
+        * This just modifies memory; should not be necessary. But... This is
+        * necessary, because 386 hardware has concept of busy TSS or some
+        * similar stupidity.
+        */
+       set_tss_desc(cpu, &t->x86_tss);
 
 #ifdef CONFIG_X86_64
        memcpy(&tss, &desc[GDT_ENTRY_TSS], sizeof(tss_desc));
@@ -428,7 +429,7 @@ static int msr_initialize_bdw(const struct dmi_system_id *d)
        return msr_init_context(bdw_msr_id, ARRAY_SIZE(bdw_msr_id));
 }
 
-static struct dmi_system_id msr_save_dmi_table[] = {
+static const struct dmi_system_id msr_save_dmi_table[] = {
        {
         .callback = msr_initialize_bdw,
         .ident = "BROADWELL BDX_EP",