Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge tag 'x86_urgent_for_v6.17_rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip

Pull x86 fixes from Borislav Petkov:

- Fix the GDS mitigation detection on some machines after the recent
attack vectors conversion

- Filter out the invalid machine reset reason value -1 when running as
a guest as in such cases the reason why the machine was rebooted does
not make a whole lot of sense

- Init the resource control machinery on Hygon hw in order to avoid a
division by zero and to actually enable the feature on hw which
supports it

* tag 'x86_urgent_for_v6.17_rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
x86/bugs: Fix GDS mitigation selecting when mitigation is off
x86/CPU/AMD: Ignore invalid reset reason value
x86/cpu/hygon: Add missing resctrl_cpu_detect() in bsp_init helper

+10 -5
+6 -2
arch/x86/kernel/cpu/amd.c
··· 1326 1326 1327 1327 static __init int print_s5_reset_status_mmio(void) 1328 1328 { 1329 - unsigned long value; 1330 1329 void __iomem *addr; 1330 + u32 value; 1331 1331 int i; 1332 1332 1333 1333 if (!cpu_feature_enabled(X86_FEATURE_ZEN)) ··· 1340 1340 value = ioread32(addr); 1341 1341 iounmap(addr); 1342 1342 1343 + /* Value with "all bits set" is an error response and should be ignored. */ 1344 + if (value == U32_MAX) 1345 + return 0; 1346 + 1343 1347 for (i = 0; i < ARRAY_SIZE(s5_reset_reason_txt); i++) { 1344 1348 if (!(value & BIT(i))) 1345 1349 continue; 1346 1350 1347 1351 if (s5_reset_reason_txt[i]) { 1348 - pr_info("x86/amd: Previous system reset reason [0x%08lx]: %s\n", 1352 + pr_info("x86/amd: Previous system reset reason [0x%08x]: %s\n", 1349 1353 value, s5_reset_reason_txt[i]); 1350 1354 } 1351 1355 }
+1 -3
arch/x86/kernel/cpu/bugs.c
··· 1068 1068 if (gds_mitigation == GDS_MITIGATION_AUTO) { 1069 1069 if (should_mitigate_vuln(X86_BUG_GDS)) 1070 1070 gds_mitigation = GDS_MITIGATION_FULL; 1071 - else { 1071 + else 1072 1072 gds_mitigation = GDS_MITIGATION_OFF; 1073 - return; 1074 - } 1075 1073 } 1076 1074 1077 1075 /* No microcode */
+3
arch/x86/kernel/cpu/hygon.c
··· 16 16 #include <asm/spec-ctrl.h> 17 17 #include <asm/delay.h> 18 18 #include <asm/msr.h> 19 + #include <asm/resctrl.h> 19 20 20 21 #include "cpu.h" 21 22 ··· 118 117 x86_amd_ls_cfg_ssbd_mask = 1ULL << 10; 119 118 } 120 119 } 120 + 121 + resctrl_cpu_detect(c); 121 122 } 122 123 123 124 static void early_init_hygon(struct cpuinfo_x86 *c)