x86/resctrl: Fix to restore to original value when re-enabling hardware prefetch...
authorKohei Tarumizu <tarumizu.kohei@fujitsu.com>
Wed, 24 Aug 2022 16:44:10 +0000 (09:44 -0700)
committerDave Hansen <dave.hansen@linux.intel.com>
Wed, 31 Aug 2022 18:42:17 +0000 (11:42 -0700)
commit499c8bb4693d1c8d8f3d6dd38e5bdde3ff5bd906
treeb6b1ab36b80d45f1e4e54e61ad4d659c298d5c42
parentb90cb1053190353cc30f0fef0ef1f378ccc063c5
x86/resctrl: Fix to restore to original value when re-enabling hardware prefetch register

The current pseudo_lock.c code overwrites the value of the
MSR_MISC_FEATURE_CONTROL to 0 even if the original value is not 0.
Therefore, modify it to save and restore the original values.

Fixes: 018961ae5579 ("x86/intel_rdt: Pseudo-lock region creation/removal core")
Fixes: 443810fe6160 ("x86/intel_rdt: Create debugfs files for pseudo-locking testing")
Fixes: 8a2fc0e1bc0c ("x86/intel_rdt: More precise L2 hit/miss measurements")
Signed-off-by: Kohei Tarumizu <tarumizu.kohei@fujitsu.com>
Signed-off-by: Dave Hansen <dave.hansen@linux.intel.com>
Acked-by: Reinette Chatre <reinette.chatre@intel.com>
Link: https://lkml.kernel.org/r/eb660f3c2010b79a792c573c02d01e8e841206ad.1661358182.git.reinette.chatre@intel.com
arch/x86/kernel/cpu/resctrl/pseudo_lock.c