Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1422664AbVLOJoi (ORCPT ); Thu, 15 Dec 2005 04:44:38 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1422669AbVLOJoi (ORCPT ); Thu, 15 Dec 2005 04:44:38 -0500 Received: from mail.suse.de ([195.135.220.2]:26508 "EHLO mx1.suse.de") by vger.kernel.org with ESMTP id S1422664AbVLOJoi (ORCPT ); Thu, 15 Dec 2005 04:44:38 -0500 Date: Thu, 15 Dec 2005 10:44:37 +0100 From: Andi Kleen To: Ravikiran G Thirumalai Cc: Andi Kleen , linux-kernel@vger.kernel.org, discuss@x86-64.org, Andrew Morton Subject: Re: [discuss] [patch 1/3] x86_64: Node local pda take 2 -- early cpu_to_node Message-ID: <20051215094437.GY23384@wotan.suse.de> References: <20051215023345.GB3787@localhost.localdomain> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20051215023345.GB3787@localhost.localdomain> Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1419 Lines: 40 On Wed, Dec 14, 2005 at 06:33:45PM -0800, Ravikiran G Thirumalai wrote: > Here is take 2 on x86_64 node local pda allocation. > > This patchset does away with the extra memory reference for non CONFIG_NUMA > case. The early cpu_to_node helps AMD and EM64T systems which work well > with CONFIG_ACPI_NUMA. cpu_to_node is not inited early for AMD systems > which work only with old style K8_NUMA. (Tested on EM64 NUMA and Tyan K8 > dual core 4 cpu boxes) Thanks for now testing on AMD too - that makes me more confident in your patches. > Andi, I could not eliminate the need for a initial static pda array, since > sched_init needs the static per-cpu offset array for NR_CPUS early. Hope > this is OK. See my comment. > + * Setup cpu_to_node using the SRAT lapcis & ACPI MADT table > + * info. > + */ > +void __init init_cpu_to_node(void) > +{ > + int i; > + for (i = 0; i < NR_CPUS; i++) > + cpu_to_node[i] = apicid_to_node[x86_cpu_to_apicid[i]]; > +} I would prefer it if you moved that to numa.c and run always (even for the k8topology case). Otherwise k8topology will behave differently whether CONFIG_ACPI_NUMA is set or not, and I don't like that. -Andi - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/