lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Fri, 24 Aug 2007 17:23:49 -0700
From:	"Siddha, Suresh B" <suresh.b.siddha@...el.com>
To:	travis@....com
Cc:	Andi Kleen <ak@...e.de>, linux-mm@...ck.org,
	linux-kernel@...r.kernel.org,
	Andrew Morton <akpm@...ux-foundation.org>,
	Christoph Lameter <clameter@....com>
Subject: Re: [PATCH 1/6] x86: fix cpu_to_node references (v2)

On Fri, Aug 24, 2007 at 03:26:55PM -0700, travis@....com wrote:
> Fix four instances where cpu_to_node is referenced
> by array instead of via the cpu_to_node macro.  This
> is preparation to moving it to the per_cpu data area.
> 
...

>  unsigned long __init numa_free_all_bootmem(void) 
> --- a/arch/x86_64/mm/srat.c
> +++ b/arch/x86_64/mm/srat.c
> @@ -431,9 +431,9 @@
>  			setup_node_bootmem(i, nodes[i].start, nodes[i].end);
>  
>  	for (i = 0; i < NR_CPUS; i++) {
> -		if (cpu_to_node[i] == NUMA_NO_NODE)
> +		if (cpu_to_node(i) == NUMA_NO_NODE)
>  			continue;
> -		if (!node_isset(cpu_to_node[i], node_possible_map))
> +		if (!node_isset(cpu_to_node(i), node_possible_map))
>  			numa_set_node(i, NUMA_NO_NODE);
>  	}
>  	numa_init_array();

During this particular routine execution, per cpu areas are not yet setup. In
future, when we make cpu_to_node(i) use per cpu area, then this code will break.

And actually setup_per_cpu_areas() uses cpu_to_node(). So...

thanks,
suresh
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ