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]
Message-ID: <20081009080601.GD24560@one.firstfloor.org>
Date:	Thu, 9 Oct 2008 10:06:01 +0200
From:	Andi Kleen <andi@...stfloor.org>
To:	KOSAKI Motohiro <kosaki.motohiro@...fujitsu.com>
Cc:	Lai Jiangshan <laijs@...fujitsu.com>,
	Andi Kleen <andi@...stfloor.org>, paulmck@...ux.vnet.ibm.com,
	linux-kernel@...r.kernel.org, mingo@...e.hu, rjw@...k.pl,
	dipankar@...ibm.com, tglx@...uxtronix.de
Subject: Re: [PATCH] rudimentary tracing for Classic RCU

On Thu, Oct 09, 2008 at 04:14:26PM +0900, KOSAKI Motohiro wrote:
> Hi Lai-san,
> 
> > >> In this case, why not define it as:
> > >> static char buf[20*NR_CPUS + 100];
> > > 
> > > Actually you should near never use NR_CPUS now but always num_possible_cpus()
> > > (or even num_online_cpus()) Using NR_CPUS can lead to extreme waste
> > > of memory on kernels which are compiled for 4096 CPUs for example.
> > > 
> > > And with num_possible_cpus() kmalloc is needed.
> > 
> > I thought the default value of NR_CPUS is 32.
> 
> it's pointless.
> Almost distribution use _very_ large NR_CPUS (likes 4096).

Right now it's more like 8-128, but at least there is some effort
to make a 4096 CPU distribution possible and Mike Travis has been
 tirelessly working on eradicating all the rogue NR_CPUs all over 
the tree.  So it's better to not add more.

> So, We should concern large NR_CPUS.

Agreed.

-Andi

-- 
ak@...ux.intel.com
--
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