Messages in this thread | | | Date | Thu, 20 Jan 2011 21:14:30 +0100 (CET) | From | Jesper Juhl <> | Subject | Re: [PATCH 09/10] Add yaffs2 file system: Linux glue code |
| |
On Fri, 14 Jan 2011, Charles Manning wrote:
> Signed-off-by: Charles Manning <cdhmanning@gmail.com> > --- ... > +static int yaffs_setxattr(struct dentry *dentry, const char *name, > + const void *value, size_t size, int flags) > +{ > + struct inode *inode = dentry->d_inode; > + int error = 0; > + struct yaffs_dev *dev; > + struct yaffs_obj *obj = yaffs_inode_to_obj(inode); > +
You only use the local variable 'inode' in the call to yaffs_inode_to_obj(), so you could get rid of that local variable and just do struct yaffs_obj *obj = yaffs_inode_to_obj(dentry->d_inode); this applies to a few other function in this file as well.
-- Jesper Juhl <jj@chaosbits.net> http://www.chaosbits.net/ Don't top-post http://www.catb.org/~esr/jargon/html/T/top-post.html Plain text mails only, please.
| |