Re: [PATCH 6/13: eCryptfs] Superblock operations

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 2006-05-04 at 22:40 +0100, David Howells wrote:
> Pekka Enberg <[email protected]> wrote:
> 
> > > +       ecryptfs_printk(KERN_DEBUG, "Enter; inode = [%p]\n", inode);
> > > +       crypt_stat = &(ECRYPTFS_INODE_TO_PRIVATE(inode))->crypt_stat;
> > > +       ecryptfs_destruct_crypt_stat(crypt_stat);
> > > +       kmem_cache_free(ecryptfs_inode_info_cache,
> > > +                       ECRYPTFS_INODE_TO_PRIVATE(inode));
> > 
> > Better to introduce a local variable for CRYPTFS_INODE_TO_PRIVATE.
> > More readable and smaller kernel text that way.
> 
> But it may use more stack, which is a much more limited resource, so what you
> suggest is not necessarily the best thing to do.

I think either way it's coded, the compiler will probably store the
result in a register.  I would recommend the most readable approach
(which I believe would be using a local variable) and leave the
optimization to the compiler.

> David

Shaggy
-- 
David Kleikamp
IBM Linux Technology Center

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux