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: <20070224130723.01f3c429.kamezawa.hiroyu@jp.fujitsu.com>
Date:	Sat, 24 Feb 2007 13:07:23 +0900
From:	KAMEZAWA Hiroyuki <kamezawa.hiroyu@...fujitsu.com>
To:	Nick Piggin <npiggin@...e.de>
Cc:	linux-kernel@...r.kernel.org
Subject: Re: [rfc][patch] dynamic resizing dentry hash using RCU

On Fri, 23 Feb 2007 16:37:43 +0100
Nick Piggin <npiggin@...e.de> wrote:

> +static void dcache_hash_resize(unsigned int new_shift);
> +static void mod_nr_dentry(int mod)
> +{
> +	unsigned long dentry_size;
> +
> +	dentry_stat.nr_dentry += mod;
> +
> +	dentry_size = 1 << dentry_hash->shift;
> +	if (unlikely(dentry_stat.nr_dentry > dentry_size+(dentry_size>>1)))
> +		dcache_hash_resize(dentry_hash->shift+1);
> +	else if (unlikely(dentry_stat.nr_dentry < (dentry_size>>1)))
> +		dcache_hash_resize(dentry_hash->shift-1);
> +}
> +

Do we need to do this kind of resizing in implicit automatic way ?
I think it's good to show contention rate by /proc and add sysctl for
resize this.

-Kame

-
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