[CRIU] [PATCH] zdtm/static/fpu01: check for OSXSAVE instead of XSAVE

Adrian Reber adrian at lisas.de
Wed Feb 8 05:06:23 PST 2017


From: Adrian Reber <areber at redhat.com>

When checking for XSAVE availability it makes more sense
to check for OSXSAVE than to check for XSAVE. This way the
check works on systems booted with the 'noxsave' kernel
command-line.

Signed-off-by: Adrian Reber <areber at redhat.com>
---
 test/zdtm/static/fpu01.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/test/zdtm/static/fpu01.c b/test/zdtm/static/fpu01.c
index c8e6ca1..ff32f57 100644
--- a/test/zdtm/static/fpu01.c
+++ b/test/zdtm/static/fpu01.c
@@ -19,7 +19,7 @@ static int verify_cpu(void)
 
 	/* Do we have xsave? */
 	cpuid(1, &eax, &ebx, &ecx, &edx);
-	if (!(ecx & (1u << 26)))
+	if (!(ecx & (1u << 27)))
 		return -1;
 
 	/* Is YMM here? */
-- 
1.8.3.1



More information about the CRIU mailing list