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]
Date: Tue, 30 Jan 2024 18:10:57 -0500
From: Steven Rostedt <rostedt@...dmis.org>
To: Linus Torvalds <torvalds@...ux-foundation.org>
Cc: Masami Hiramatsu <mhiramat@...nel.org>, linux-kernel@...r.kernel.org,
 linux-trace-kernel@...r.kernel.org
Subject: Re: [PATCH 5/6] eventfs: get rid of dentry pointers without
 refcounts

On Tue, 30 Jan 2024 15:06:13 -0800
Linus Torvalds <torvalds@...ux-foundation.org> wrote:

> On Tue, 30 Jan 2024 at 14:56, Linus Torvalds
> <torvalds@...ux-foundation.org> wrote:
> >
> > With that, the base size of 'struct eventfs_inode' actually becomes 96
> > bytes for me.  
> 
> It can be shrunk some more.
> 
> The field ordering is suboptimal. Pointers are 8 bytes and 8-byte
> aligned, but 'struct kref' is just 4 bytes, and 'struct eventfs_attr'
> is 12 bytes and 4-byte aligned.
> 
> So if you pack all the 8-byte-aligned fields at the beginning, and the
> 4-byte-aligned ones at the end, you get 88 bytes.
> 
> At which point a name pointer would *just* fit in 96 bytes.

Does that mean I should keep the kstrdup_const()?

> 
> ...  and then some debug option is enabled, and it all goes to hell again.

Heh, I'm not too concerned about debug options. As anyone concerned about
memory size should have already have audited their .config to turn off
anything they don't need.

-- Steve

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ