From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from zeniv.linux.org.uk ([195.92.253.2]:52592 "EHLO ZenIV.linux.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751446AbeERUXR (ORCPT ); Fri, 18 May 2018 16:23:17 -0400 Date: Fri, 18 May 2018 21:23:15 +0100 From: Al Viro To: Alexey Dobriyan Cc: linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org, hch@lst.de Subject: Re: [PATCH -vfs] proc: don't maintain sizeof(struct proc_dir_entry) Message-ID: <20180518202315.GU30522@ZenIV.linux.org.uk> References: <20180518200213.GA8006@avx2> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180518200213.GA8006@avx2> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: On Fri, May 18, 2018 at 11:02:13PM +0300, Alexey Dobriyan wrote: > Automatically cap sizeof(struct proc_dir_entry) at 192/128 bytes or > 256/192 bytes if spinlock debugging/lockdep is enabled. > --- a/fs/proc/internal.h > +++ b/fs/proc/internal.h > @@ -61,13 +61,15 @@ struct proc_dir_entry { > char *name; > umode_t mode; > u8 namelen; > + char inline_name[]; > +} __randomize_layout; > + Hmm... proc_root initialization relies upon a gccism after that... Speaking of which, why the hell do we even bother with proc_root.name?