RE: [PATCH 0/2] fs: supply inode uid/gid setting interface

2013-08-27 Thread David Laight
> Subject: Re: [PATCH 0/2] fs: supply inode uid/gid setting interface
> 
> On 2013/8/23 12:10, Greg KH wrote:
> > On Fri, Aug 23, 2013 at 10:48:36AM +0800, Rui Xiang wrote:
> >> This patchset implements an accessor functions to set uid/gid
> >> in inode struct. Just finish code clean up.
> >
> > Why?
> >
> It can introduce a new function to reduce some codes.
>  Just clean up.

In what sense is it a 'cleanup' ?

To my mind it just means that anyone reading the code has
to go and look at another file in order to see what the
function does (it might be expected to be more complex).

It also adds run time cost, while probably not directly
measurable I suspect it more than doubles the execution
time of that code fragment - do that everywhere and the
system will run like a sick pig.

The only real use for accessor functions is when you
don't want the structure offset to be public.
In this case that is obviously not the case since
all the drivers are directly accessing other members
of the structure.

David



--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 0/2] fs: supply inode uid/gid setting interface

2013-08-23 Thread Rui Xiang
On 2013/8/23 12:10, Greg KH wrote:
> On Fri, Aug 23, 2013 at 10:48:36AM +0800, Rui Xiang wrote:
>> This patchset implements an accessor functions to set uid/gid
>> in inode struct. Just finish code clean up.
> 
> Why?
> 
It can introduce a new function to reduce some codes. 
 Just clean up. 


Thanks.

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 0/2] fs: supply inode uid/gid setting interface

2013-08-22 Thread Greg KH
On Fri, Aug 23, 2013 at 10:48:36AM +0800, Rui Xiang wrote:
> This patchset implements an accessor functions to set uid/gid
> in inode struct. Just finish code clean up.

Why?
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH 0/2] fs: supply inode uid/gid setting interface

2013-08-22 Thread Rui Xiang
This patchset implements an accessor functions to set uid/gid
in inode struct. Just finish code clean up.

Rui Xiang (2):
  fs: implement inode uid/gid setting function
  fs: use inode_set_user to set uid/gid of inode

 arch/ia64/kernel/perfmon.c|  3 +--
 arch/powerpc/platforms/cell/spufs/inode.c |  3 +--
 arch/s390/hypfs/inode.c   |  3 +--
 drivers/infiniband/hw/qib/qib_fs.c|  3 +--
 drivers/usb/gadget/f_fs.c |  3 +--
 drivers/usb/gadget/inode.c|  5 +++--
 fs/9p/vfs_inode.c |  6 ++
 fs/adfs/inode.c   |  3 +--
 fs/affs/inode.c   |  6 ++
 fs/afs/inode.c|  6 ++
 fs/anon_inodes.c  |  3 +--
 fs/autofs4/inode.c|  4 ++--
 fs/befs/linuxvfs.c|  8 
 fs/ceph/caps.c|  5 +++--
 fs/ceph/inode.c   |  8 
 fs/cifs/inode.c   |  6 ++
 fs/configfs/inode.c   |  3 +--
 fs/debugfs/inode.c|  3 +--
 fs/devpts/inode.c |  7 +++
 fs/ext2/ialloc.c  |  3 +--
 fs/ext3/ialloc.c  |  3 +--
 fs/ext4/ialloc.c  |  3 +--
 fs/fat/inode.c|  6 ++
 fs/fuse/control.c |  3 +--
 fs/fuse/inode.c   |  4 ++--
 fs/hfs/inode.c|  6 ++
 fs/hfsplus/inode.c|  3 +--
 fs/hpfs/inode.c   |  3 +--
 fs/hpfs/namei.c   | 12 
 fs/hugetlbfs/inode.c  |  3 +--
 fs/inode.c|  7 +++
 fs/isofs/inode.c  |  3 +--
 fs/isofs/rock.c   |  3 +--
 fs/ncpfs/inode.c  |  3 +--
 fs/nfs/inode.c|  4 ++--
 fs/ntfs/inode.c   | 12 
 fs/ntfs/mft.c |  3 +--
 fs/ntfs/super.c   |  3 +--
 fs/ocfs2/refcounttree.c   |  3 +--
 fs/omfs/inode.c   |  3 +--
 fs/pipe.c |  3 +--
 fs/proc/base.c| 15 +--
 fs/proc/fd.c  |  8 
 fs/proc/inode.c   |  3 +--
 fs/proc/self.c|  3 +--
 fs/stack.c|  3 +--
 fs/sysfs/inode.c  |  3 +--
 fs/xfs/xfs_iops.c |  4 ++--
 include/linux/fs.h|  1 +
 ipc/mqueue.c  |  3 +--
 kernel/cgroup.c   |  3 +--
 mm/shmem.c|  3 +--
 net/socket.c  |  3 +--
 53 files changed, 94 insertions(+), 142 deletions(-)

-- 
1.8.2.2


--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html