Re: [RFC] [PATCH 6/8] inode-diet: Move i_cindex from struct inode to struct file

From: Al Viro
Date: Mon Jun 19 2006 - 15:36:41 EST


On Mon, Jun 19, 2006 at 08:33:35PM +0100, Al Viro wrote:
> On Mon, Jun 19, 2006 at 11:20:09AM -0400, Theodore Tso wrote:
> > inode.i_cindex isn't initialized until the character device is opened
> > anyway, and there are far more struct inodes in memory than there are
> > struct file. So move the cindex field to file.f_cindex, and change
> > the one(!) user of cindex to use file pointer, which is in fact simpler.
>
> NAK. Please, take it to the union into cdev part.

Explanation: the whole point of that sucker is to avoid i_rdev use
in drivers, switching to i_cdev + i_cindex. _Especially_ in open().
There is a bunch of other drivers that would get cleaner from that,
including a lot of tty code.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/