diff --git a/NEWS b/NEWS index 6864af471c..1214ec4727 100644 --- a/NEWS +++ b/NEWS @@ -24,6 +24,7 @@ The following bugs are resolved with this release: [28532] powerpc64[le]: CFI for assembly templated syscalls is incorrect [28678] nptl/tst-create1 hangs sporadically [28700] "dns [!UNAVAIL=return] files" NSS default for hosts is not useful + [28704] elf/tst-cpu-features-cpuinfo fails for KVM guests on some AMD systems Version 2.34 diff --git a/sysdeps/x86/tst-cpu-features-cpuinfo.c b/sysdeps/x86/tst-cpu-features-cpuinfo.c index 2d4927f5e5..830aaca2ec 100644 --- a/sysdeps/x86/tst-cpu-features-cpuinfo.c +++ b/sysdeps/x86/tst-cpu-features-cpuinfo.c @@ -169,7 +169,14 @@ do_test (int argc, char **argv) else if (cpu_features->basic.kind == arch_kind_amd) { fails += CHECK_PROC (ibpb, AMD_IBPB); - fails += CHECK_PROC (ibrs, AMD_IBRS); + + /* The IBRS feature on AMD processors is reported using the Intel feature + * on KVM guests (synthetic bit). In both cases the cpuinfo entry is the + * same. */ + if (HAS_CPU_FEATURE (IBRS_IBPB)) + fails += CHECK_PROC (ibrs, IBRS_IBPB); + else + fails += CHECK_PROC (ibrs, AMD_IBRS); fails += CHECK_PROC (stibp, AMD_STIBP); } fails += CHECK_PROC (ibt, IBT);