Re: [PATCH 2/8] numa: x86_64: use generic percpu var numa_node_id() implementation

Tejun Heo <[email protected]>
Newsgroups org.kernel.vger.linux-numa,org.kvack.linux-mm
Message-ID <[email protected]>
Hello,

On 04/29/2010 06:56 PM, Lee Schermerhorn wrote:
> Tejun:  do you mean:
> 
> #ifdef CONFIG_NUMA
>         if (cpu != 0 && percpu_read(numa_node) == 0 &&
> ........................^ here?
>             early_cpu_to_node(cpu) != NUMA_NO_NODE)
>                 set_numa_node(early_cpu_to_node(cpu));
> #endif
> 
> Looks like 'numa_node_id()' would work there.

Yeah, it just looked weird to use raw variable when an access wrapper
is there.

> But, I wonder what the "cpu != 0 && percpu_read(numa_node) == 0" is
> trying to do?

That I have don't have any clue about.  :-)

> Just trying to grok the intent.  Maybe someone will chime in.

Christoph?  Mel?

Thanks.

-- 
tejun

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to [email protected].  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"[email protected]"> [email protected] </a>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.