lkml.org 
[lkml]   [2015]   [Jan]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 5/9] perf/x86/intel: Add Intel Cache QoS Monitoring support
On Fri, Jan 23, 2015 at 06:45:44PM +0000, Matt Fleming wrote:

SNIP

> + int phys_id = topology_physical_package_id(cpu);
> + int i;
> +
> + for_each_cpu(i, &cqm_cpumask) {
> + if (phys_id == topology_physical_package_id(i))
> + return; /* already got reader for this socket */
> + }
> +
> + cpumask_set_cpu(cpu, &cqm_cpumask);
> +}
> +
> +static void intel_cqm_cpu_prepare(unsigned int cpu)
> +{
> + struct intel_cqm_state *state = &per_cpu(cqm_state, cpu);
> + struct cpuinfo_x86 *c = &cpu_data(cpu);
> +
> + raw_spin_lock_init(&state->lock);
> + state->rmid = 0;

shouldn't you also init state->cnt?

jirka


\
 
 \ /
  Last update: 2015-01-25 19:41    [W:0.155 / U:0.244 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site