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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <47C91BC6.6050603@cosmosbay.com>
Date:	Sat, 01 Mar 2008 10:03:02 +0100
From:	Eric Dumazet <dada1@...mosbay.com>
To:	Oliver Hartkopp <oliver@...tkopp.net>
CC:	Arnaldo Carvalho de Melo <acme@...stprotocols.net>,
	David Miller <davem@...emloft.net>, netdev@...r.kernel.org
Subject: Re: Patch: [NET]: Remove CONFIG_PROC_FS depency for pcounter inuse

Oliver Hartkopp a écrit :
> Hi all,
> 
> attached you'll find a patch that fixes the depency that has been 
> introduced in commit 65f7651788e18fadb2fbb7276af935d7871e1803 ([NET]: 
> prot_inuse cleanups and optimizations).
> 
> As the inuse counters are only used by internet protocols right now, 
> using CONFIG_INET would have been more obvious to recognize this illegal 
> optimization here. Going a bit deeper into this problem we can see, that 
> the pcounters are ONLY used for the internet protocols BUT initialized 
> for ALL protocols in proto_[un|]register() in net/core/sock.c.
> 
> This forces all network protocols to initialize the pcounters and 
> therefore request dynamic percpu memory even when it is not used at all.
> 
> I would suggest to
> 
> 1. move the ..._inuse_[init|free]() stuff from sock.c to af_inet[|6].c 
> and his friends
> 
> OR
> 
> 2. add new parameters to proto_[un|]register() like 'alloc_inuse' and 
> 'free_inuse'
> 
> My favourite sollution would be the second one but before creating a 
> patch for one of these suggestions, i wanted to ask for your opinion or 
> if there is any 'even nicer' idea from your side.

Hello Oliver

I am just coming back from hollidays.

Last thing I did before leaving was to post a patch to correct performance hit 
of percpu_counters in mainline. ([PATCH] alloc_percpu() fails to allocate 
percpu data http://lkml.org/lkml/2008/2/21/254 )

Before accepting Andrew Morton claims about percpu_counters being superior to 
pcounter, I benched them and found they were not.

As soon as percpu_counters are not grossly inefficient, the only move will be 
to just zap pcounter, as most people dont like it.

Only one patch will be necessary, please dont try to hide pcounter by small 
patches :)

Thank you
--
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