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: <20140828043211.GD3971@dhcp-17-37.nay.redhat.com>
Date:	Thu, 28 Aug 2014 12:32:11 +0800
From:	WANG Chao <chaowang@...hat.com>
To:	Christoph Lameter <cl@...ux.com>
Cc:	Andrew Morton <akpm@...ux-foundation.org>,
	Pekka Enberg <penberg@...nel.org>,
	David Rientjes <rientjes@...gle.com>,
	Joonsoo Kim <iamjoonsoo.kim@....com>,
	"open list:SLAB ALLOCATOR" <linux-mm@...ck.org>,
	open list <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] mm, slub: do not add duplicate sysfs

On 08/27/14 at 10:32am, Christoph Lameter wrote:
> Maybe something like this may be a proper fix:
> 
> Subject: slub: Disable tracing of mergeable slabs
> 
> Tracing of mergeable slabs is confusing since the objects
> of multiple slab caches will be traced. Moreover this creates
> a situation where a mergeable slab will become unmergeable.
> 
> If tracing is desired then it may be best to switch merging
> off for starters.
> 
> Signed-off-by: Christoph Lameter <cl@...ux.com>
> 
> Index: linux/mm/slub.c
> ===================================================================
> --- linux.orig/mm/slub.c	2014-08-08 11:52:30.039681592 -0500
> +++ linux/mm/slub.c	2014-08-27 10:30:16.508108726 -0500
> @@ -4604,6 +4604,14 @@ static ssize_t trace_show(struct kmem_ca
>  static ssize_t trace_store(struct kmem_cache *s, const char *buf,
>  							size_t length)
>  {
> +	/*
> +	 * Tracing a merged cache is going to give confusing results
> +	 * as well as cause other issues like converting a mergeable
> +	 * cache into an umergeable one.
> +	 */
> +	if (s->refcount > 1)
> +		return -EINVAL;
> +
>  	s->flags &= ~SLAB_TRACE;
>  	if (buf[0] == '1') {
>  		s->flags &= ~__CMPXCHG_DOUBLE;

What about failslab_store()? SLAB_FAILSLAB is also a nomerge flag.
--
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