Re: [Patch 10/18] fs/logfs/inode.c

From: JÃrn Engel
Date: Sun Jun 10 2007 - 13:45:13 EST


On Sun, 10 June 2007 19:24:28 +0200, Arnd Bergmann wrote:
> On Sunday 03 June 2007, JÃrn Engel wrote:
> > +struct inode *logfs_new_inode(struct inode *dir, int mode)
> > +{
> > +ÂÂÂÂÂÂÂstruct super_block *sb = dir->i_sb;
> > +ÂÂÂÂÂÂÂstruct inode *inode;
> > +
> > +ÂÂÂÂÂÂÂinode = new_inode(sb);
> > +ÂÂÂÂÂÂÂif (!inode)
> > +ÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂreturn ERR_PTR(-ENOMEM);
> > +
> > +ÂÂÂÂÂÂÂlogfs_init_inode(inode);
> > +
> > +ÂÂÂÂÂÂÂinode->i_mode = mode;
> > +ÂÂÂÂÂÂÂinode->i_ino = logfs_get_ino(sb);
> > +
> > +ÂÂÂÂÂÂÂinsert_inode_hash(inode);
> > +
> > +ÂÂÂÂÂÂÂreturn inode;
> > +}
>
> I think this is missing code that sets the initial i_uid/i_gid,
> but there may be more missing. Changing the uid value works,
> but creating files as non-root user doesn't.

Eek! I'll have a look.

JÃrn

--
When in doubt, punt. When somebody actually complains, go back and fix it...
The 90% solution is a good thing.
-- Rob Landley
-
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/