]> xenbits.xensource.com Git - people/iwj/xen.git/commitdiff
xen: Fix backport of "x86/tsx: Implement controls for RTM force-abort mode"
authorAndrew Cooper <andrew.cooper3@citrix.com>
Fri, 3 May 2019 08:51:31 +0000 (10:51 +0200)
committerJan Beulich <jbeulich@suse.com>
Fri, 3 May 2019 08:51:31 +0000 (10:51 +0200)
The posted version of this patch depends on c/s 3c555295 "x86/vpmu: Improve
documentation and parsing for vpmu=" (Xen 4.12 and later) to prevent
`vpmu=rtm-abort` impliying `vpmu=1`, which is outside of security support.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Jan Beulich <jbeulich@suse.com>
xen/arch/x86/cpu/vpmu.c

index 639ae0ca63046f46de619b28410a7d652fbccacf..9a42e09a11c85133d66b8097c79b62743a5a92bc 100644 (file)
@@ -91,6 +91,10 @@ static int __init parse_vpmu_params(const char *s)
 
             s = ss + 1;
         } while ( *ss );
+
+        if ( !vpmu_features ) /* rtm-abort doesn't imply vpmu=1 */
+            break;
+
         /* fall through */
     case 1:
         /* Default VPMU mode */