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: <20140704013222.GH9508@dastard>
Date:	Fri, 4 Jul 2014 11:32:22 +1000
From:	Dave Chinner <david@...morbit.com>
To:	Andi Kleen <andi@...stfloor.org>
Cc:	Rasmus Villemoes <linux@...musvillemoes.dk>,
	Nick Piggin <npiggin@...nel.dk>,
	Al Viro <viro@...iv.linux.org.uk>,
	linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: DNAME_INLINE_LEN versus CONFIG_GENERIC_LOCKBREAK

On Thu, Jul 03, 2014 at 12:53:01PM -0700, Andi Kleen wrote:
> Rasmus Villemoes <linux@...musvillemoes.dk> writes:
> 
> > In dcache.h, DNAME_INLINE_LEN is carefully chosen so that sizeof(struct
> > dentry) is a (specific) multiple of 64 bytes. Obviously this breaks when
> > certain debug options are chosen (DEBUG_LOCK_ALLOC and DEBUG_SPINLOCK),
> > but also, AFAICT, on architectures with CONFIG_GENERIC_LOCKBREAK.
> >
> > I'm not sure it matters, but if it does, I'd suggest putting a
> > BUILD_BUG_ON somewhere, protected by suitable #ifdefs, so that the code
> > documents the assumptions that went into the particular choice of
> > DNAME_INLINE_LEN (this would also help catch changes to some of the
> > structures embedded in struct dentry which would violate those
> > assumptions). 
> 
> The right fix would be to pad it correctly for these other variants
> too.

IF you've turned on debugging options, then you've already lost more
performance that careful packing of the dentry slab cache gains you.
There's no point in carefully tuning DNAME_INLINE_LEN for debug
options - it's just code that will break and annoy people as debug
implementations change.

Cheers,

Dave.
-- 
Dave Chinner
david@...morbit.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