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: <200811201058.30017.rusty@rustcorp.com.au>
Date:	Thu, 20 Nov 2008 10:58:29 +1030
From:	Rusty Russell <rusty@...tcorp.com.au>
To:	Eric Dumazet <dada1@...mosbay.com>
Cc:	David Miller <davem@...emloft.net>, netdev@...r.kernel.org
Subject: Re: [PATCH] net: make ip_rt_acct a normal percpu var

On Thursday 20 November 2008 09:53:48 Eric Dumazet wrote:
> Rusty Russell a écrit :
> > On Thursday 20 November 2008 08:50:23 David Miller wrote:
> >> Do you really need this to forward some work you are doing?  If not
> >> can we just let sleeping dogs lie on this one? :)
> >
> > Yes, I have patches to convert the dynamic percpu data to use the same
> > mechanism as static percpu data.  Unfortunately we don't have a mechanism
> > for enlarging the percpu region (which is why this wasn't done earlier),
> > so we use a heuristic to figure out how much extra percpu region to
> > allocate at boot.
> >
> > And 4k makes this one of the Big Pigs in dynamic per-cpu allocations.
> >
> > (SNMP mibs are even worse, but that's a separate debate...)
> >
> > I can try to implement a bss-like DEFINE_PER_CPU_ZERO(), but it seems
> > silly to talk about tight boot loader size restrictions for SMP kernels.
>
> Then, if we really want to run 4096 cpus on a machine, we dont want to
> allocate 16 MBytes of memory for these ip_rt_acct counters, or even more
> for SNMP mibs.
>
> Maybe its time to design a new mechanism, to avoid the basic "one variable"
> shared by all cpus, and avoid the overkill "one separate variable for each
> cpu", and loop 4096 times to do the sum of this variable...

Per-node vars; no doubt we'll get there.  It might be worth having YA percpu 
counters implementation which does exactly this.  After the dynamic percpu 
changes and some local_* ops changes to allow use with dynamic percpu vars, it 
should be straightforward.

I don't think it's urgent: my concern is not with people who have 4096 cpus 
(but I do care about people with 2 cpus and CONFIG_NR_CPUS=4096).

Cheers,
Rusty.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ