lkml.org 
[lkml]   [2017]   [Jan]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] perf: fix topology test on systems with sparse CPUs
On Mon, Jan 30, 2017 at 05:53:34PM +0100, Jan Stancek wrote:

SNIP

> + ret = build_cpu_topo(tp, cpu);
> if (ret < 0)
> break;
> }
> +
> +out_free:
> + cpu_map__put(map);
> if (ret) {
> free_cpu_topo(tp);
> tp = NULL;
> }
> +out:
> return tp;
> }
>
> @@ -575,7 +579,7 @@ static int write_cpu_topology(int fd, struct perf_header *h __maybe_unused,
> if (ret < 0)
> goto done;
>
> - for (j = 0; j < perf_env.nr_cpus_avail; j++) {
> + for (j = 0; j < perf_env.nr_cpus_online; j++) {

so basically we're changing from avail to online cpus

have you checked all the users of this FEATURE
if such change is ok?

I can't find any after quick search, but it would be
good to be sure and mention that in changelog

thanks,
jirka

\
 
 \ /
  Last update: 2017-01-30 19:50    [W:0.089 / U:0.832 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site