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: <20080326110047.GD17176@elte.hu>
Date:	Wed, 26 Mar 2008 12:00:51 +0100
From:	Ingo Molnar <mingo@...e.hu>
To:	Al Viro <viro@...IV.linux.org.uk>
Cc:	J?rn Engel <joern@...fs.org>, David Miller <davem@...emloft.net>,
	jirislaby@...il.com, joe@...ches.com, tglx@...utronix.de,
	linux-kernel@...r.kernel.org, Andy Whitcroft <apw@...dowen.org>
Subject: Re: [patch] bkl2mtd: cleanup


* Al Viro <viro@...IV.linux.org.uk> wrote:

> On Wed, Mar 26, 2008 at 11:14:52AM +0100, Ingo Molnar wrote:
> >  /* Info for the block device */
> >  struct block2mtd_dev {
> > -	struct list_head list;
> > -	struct block_device *blkdev;
> > -	struct mtd_info mtd;
> > -	struct mutex write_mutex;
> > +	struct list_head	list;
> > +	struct block_device	*blkdev;
> > +	struct mtd_info		mtd;
> > +	/* serializes writes with each other and also with erase: */
> > +	struct mutex		write_mutex;
> >  };
> 
> Why the hell?

the vertical alignment? For the same reason some of the key VFS data 
structures in include/linux/fs.h are aligned vertically:

  struct inode
  struct file
  struct super_block
  struct address_space
  struct block_device

there are several advantages of aligning structure fields vertically 
(and the same applies to bulk initializers of structures), should i list 
them?

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