[Xen-devel] [PATCH for 4.11 2/2] xen: Fix backport of "x86/tsx: Implement controls for RTM force-abort mode"

Andrew Cooper posted 2 patches 6 years, 9 months ago
[Xen-devel] [PATCH for 4.11 2/2] xen: Fix backport of "x86/tsx: Implement controls for RTM force-abort mode"
Posted by Andrew Cooper 6 years, 9 months ago
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>
---
CC: Jan Beulich <JBeulich@suse.com>

 xen/arch/x86/cpu/vpmu.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/xen/arch/x86/cpu/vpmu.c b/xen/arch/x86/cpu/vpmu.c
index 639ae0c..9a42e09 100644
--- a/xen/arch/x86/cpu/vpmu.c
+++ b/xen/arch/x86/cpu/vpmu.c
@@ -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 */
-- 
2.1.4


_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel
Re: [Xen-devel] [PATCH for 4.11 2/2] xen: Fix backport of "x86/tsx: Implement controls for RTM force-abort mode"
Posted by Jan Beulich 6 years, 9 months ago
>>> On 29.04.19 at 18:16, <andrew.cooper3@citrix.com> wrote:
> 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-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel