mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 19:21:31 -04:00
userns: rename is_owner_or_cap to inode_owner_or_capable
And give it a kernel-doc comment. [[email protected]: btrfs changed in linux-next] Signed-off-by: Serge E. Hallyn <[email protected]> Cc: "Eric W. Biederman" <[email protected]> Cc: Daniel Lezcano <[email protected]> Acked-by: David Howells <[email protected]> Cc: James Morris <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
This commit is contained in:
parent
e795b71799
commit
2e14967075
30 changed files with 47 additions and 44 deletions
13
fs/inode.c
13
fs/inode.c
|
|
@ -1735,11 +1735,14 @@ void inode_init_owner(struct inode *inode, const struct inode *dir,
|
|||
}
|
||||
EXPORT_SYMBOL(inode_init_owner);
|
||||
|
||||
/*
|
||||
* return true if current either has CAP_FOWNER to the
|
||||
* file, or owns the file.
|
||||
/**
|
||||
* inode_owner_or_capable - check current task permissions to inode
|
||||
* @inode: inode being checked
|
||||
*
|
||||
* Return true if current either has CAP_FOWNER to the inode, or
|
||||
* owns the file.
|
||||
*/
|
||||
bool is_owner_or_cap(const struct inode *inode)
|
||||
bool inode_owner_or_capable(const struct inode *inode)
|
||||
{
|
||||
struct user_namespace *ns = inode_userns(inode);
|
||||
|
||||
|
|
@ -1749,4 +1752,4 @@ bool is_owner_or_cap(const struct inode *inode)
|
|||
return true;
|
||||
return false;
|
||||
}
|
||||
EXPORT_SYMBOL(is_owner_or_cap);
|
||||
EXPORT_SYMBOL(inode_owner_or_capable);
|
||||
|
|
|
|||
Loading…
Reference in a new issue