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:	Fri, 26 Aug 2011 16:27:21 +0200
From:	Tejun Heo <tj@...nel.org>
To:	"Kirill A. Shutemov" <kirill@...temov.name>
Cc:	Cyrill Gorcunov <gorcunov@...il.com>,
	Andrew Morton <akpm@...ux-foundation.org>,
	Pavel Emelyanov <xemul@...allels.com>,
	linux-kernel@...r.kernel.org,
	James Bottomley <jbottomley@...allels.com>,
	containers@...ts.osdl.org, Andi Kleen <andi@...stfloor.org>,
	Nathan Lynch <ntl@...ox.com>,
	LINUXFS-ML <linux-fsdevel@...r.kernel.org>,
	Zan Lynx <zlynx@....org>, Daniel Lezcano <dlezcano@...ibm.com>,
	Vasiliy Kulikov <segoon@...nwall.com>
Subject: Re: [RFC] fs, proc: Introduce the /proc/<pid>/map_files/ directory v2

Hello,

On Fri, Aug 26, 2011 at 05:23:34PM +0300, Kirill A. Shutemov wrote:
> On Fri, Aug 26, 2011 at 04:06:20PM +0200, Tejun Heo wrote:
> > > +struct map_files_info {
> > > +	struct file	*file;
> > > +	unsigned char	name[16+16+2]; /* max: %016lx-%016lx\0 */
> > > +	unsigned long	len;
> > > +};
> > 
> > That's slightly above 50 bytes.
> 
> We can use 4 * sizeof(unsigned long) + 2 for name to save a bit on 32 bit
> architectures.

Ooh, I wasn't trying to say it was too big.  I was trying to say it
would be okay to have that on stack.  :)

> BTW, show_map_vma() uses "%08lx-%08lx" to print ->start, ->end. I think
> it's good idea to use this here as well to be consistent with
> /proc/$PID/{s,}maps

I'm not too sure about this one.  First of all, I think %08lx is more
of an accident than intention (just forgot to update it while
transitioning to 64bit) and when ls'd the output can be a bit messy
without leading 0's, but again my opinion here isn't very strong.

Thanks.

-- 
tejun
--
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