Commit 08cbdefb authored by Dmitry Safonov's avatar Dmitry Safonov Committed by Andrei Vagin

x86/compat: don't set has_compat_sigreturn if !CONFIG_COMPAT

We can be on v4.9 or newer kernel, but have no 32-bit multilib
toolchain, which will result in !CONFIG_COMPAT but
kdat_compat_sigreturn_test() will return true as we have
new arch_prctls in kernel needed for compatible C/R.
Fail compat test in this case.

travis-ci: success for 32-bit tests fixes
Reported-by: 's avatarAndrei Vagin <avagin@virtuozzo.com>
Signed-off-by: 's avatarDmitry Safonov <dsafonov@virtuozzo.com>
Signed-off-by: 's avatarPavel Emelyanov <xemul@virtuozzo.com>
Signed-off-by: 's avatarAndrei Vagin <avagin@virtuozzo.com>
parent dd6736bd
......@@ -30,6 +30,7 @@
#ifdef CONFIG_X86_64
int kdat_compat_sigreturn_test(void)
{
#ifdef CONFIG_COMPAT
unsigned long auxval;
int ret;
......@@ -46,6 +47,7 @@ int kdat_compat_sigreturn_test(void)
ret = syscall(SYS_arch_prctl, ARCH_MAP_VDSO_32, 1);
if (ret == -1 && errno == EEXIST)
return 1;
#endif
return 0;
}
#endif /* CONFIG_X86_64 */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment