Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758118AbZANUha (ORCPT ); Wed, 14 Jan 2009 15:37:30 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1753833AbZANUhV (ORCPT ); Wed, 14 Jan 2009 15:37:21 -0500 Received: from mx1.suse.de ([195.135.220.2]:52758 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752853AbZANUhU (ORCPT ); Wed, 14 Jan 2009 15:37:20 -0500 Date: Wed, 14 Jan 2009 21:37:18 +0100 Message-ID: From: Takashi Iwai To: Valdis.Kletnieks@vt.edu Cc: Kyle McMartin , rusty@rustcorp.com.au, linux-kernel@vger.kernel.org Subject: Re: [PATCH] module: kzalloc mod->ref In-Reply-To: <24465.1231961348@turing-police.cc.vt.edu> References: <20090114033533.GL25103@bombadil.infradead.org> <20090114155859.GO25103@bombadil.infradead.org> <24465.1231961348@turing-police.cc.vt.edu> User-Agent: Wanderlust/2.12.0 (Your Wildest Dreams) SEMI/1.14.6 (Maruoka) FLIM/1.14.7 (=?ISO-8859-4?Q?Sanj=F2?=) APEL/10.6 Emacs/22.3 (x86_64-suse-linux-gnu) MULE/5.0 (SAKAKI) MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 839 Lines: 23 At Wed, 14 Jan 2009 14:29:08 -0500, Valdis.Kletnieks@vt.edu wrote: > > On Wed, 14 Jan 2009 17:25:31 +0100, Takashi Iwai said: > > > We can use nr_cpu_ids instead of NR_CPUS. > > For a machine like 4096 CPUs, such an amount of memory is like a > > peanut :) > > It's not peanuts if you're dealing with a distro kernel that's essentially > forced to compile with NR_CPUS=, but booting on a single or > dual core system with possibly not even 1G of memory. My suggestion above is to use nr_cpu_ids, which is the actual number of CPUs, not a constant like NR_CPUS. Takashi -- 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/