x86: cpu -- Don't exit early if --cpu-cap=ins specified

Since we're using bintmaps for options don't exit early
if --cpu-cap=ins specified because there might be a
combination of options.

Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
Reviewed-by: Dmitry Safonov <0x7f454c46@gmail.com>
Signed-off-by: Andrei Vagin <avagin@virtuozzo.com>
This commit is contained in:
Cyrill Gorcunov 2018-08-30 14:00:25 +03:00 committed by Andrei Vagin
parent 5d4e6bd636
commit fbb67af9fd

View file

@ -287,8 +287,10 @@ static int cpu_validate_features(compel_cpuinfo_t *cpu_info)
/*
* Capability on instructions level only.
*/
if (opts.cpu_cap & CPU_CAP_INS)
return cpu_validate_ins_features(cpu_info);
if (opts.cpu_cap & CPU_CAP_INS) {
if (cpu_validate_ins_features(cpu_info))
return -1;
}
/*
* Strict capability mode. Everything must match.