Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1166327 > unrolled thread
| Started by | Tejun Heo <tj@kernel.org> |
|---|---|
| First post | 2015-06-16 21:20 +0200 |
| Last post | 2015-06-16 23:00 +0200 |
| Articles | 2 — 2 participants |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
[PATCH 1/4] kernfs: make kernfs_get_inode() public Tejun Heo <tj@kernel.org> - 2015-06-16 21:20 +0200
Re: [PATCH 1/4] kernfs: make kernfs_get_inode() public Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2015-06-16 23:00 +0200
| From | Tejun Heo <tj@kernel.org> |
|---|---|
| Date | 2015-06-16 21:20 +0200 |
| Subject | [PATCH 1/4] kernfs: make kernfs_get_inode() public |
| Message-ID | <pC4yS-3dz-13@gated-at.bofh.it> |
Move kernfs_get_inode() prototype from fs/kernfs/kernfs-internal.h to
include/linux/kernfs.h. It obtains the matching inode for a
kernfs_node.
It will be used by cgroup for inode based permission checks for now
but is generally useful.
Signed-off-by: Tejun Heo <tj@kernel.org>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
Hello, Greg.
Given that cgroup will be the first and only, for now, user, I think
it'd be the eaiest to route this with the related cgroup patches
through the cgroup tree. What do you think?
Thanks.
fs/kernfs/kernfs-internal.h | 1 -
include/linux/kernfs.h | 5 +++++
2 files changed, 5 insertions(+), 1 deletion(-)
diff --git a/fs/kernfs/kernfs-internal.h b/fs/kernfs/kernfs-internal.h
index af9fa74..6762bfb 100644
--- a/fs/kernfs/kernfs-internal.h
+++ b/fs/kernfs/kernfs-internal.h
@@ -76,7 +76,6 @@ extern struct kmem_cache *kernfs_node_cache;
/*
* inode.c
*/
-struct inode *kernfs_get_inode(struct super_block *sb, struct kernfs_node *kn);
void kernfs_evict_inode(struct inode *inode);
int kernfs_iop_permission(struct inode *inode, int mask);
int kernfs_iop_setattr(struct dentry *dentry, struct iattr *iattr);
diff --git a/include/linux/kernfs.h b/include/linux/kernfs.h
index 71ecdab..e6b2f7d 100644
--- a/include/linux/kernfs.h
+++ b/include/linux/kernfs.h
@@ -277,6 +277,7 @@ void kernfs_put(struct kernfs_node *kn);
struct kernfs_node *kernfs_node_from_dentry(struct dentry *dentry);
struct kernfs_root *kernfs_root_from_sb(struct super_block *sb);
+struct inode *kernfs_get_inode(struct super_block *sb, struct kernfs_node *kn);
struct kernfs_root *kernfs_create_root(struct kernfs_syscall_ops *scops,
unsigned int flags, void *priv);
@@ -352,6 +353,10 @@ static inline struct kernfs_node *kernfs_node_from_dentry(struct dentry *dentry)
static inline struct kernfs_root *kernfs_root_from_sb(struct super_block *sb)
{ return NULL; }
+static inline struct inode *
+kernfs_get_inode(struct super_block *sb, struct kernfs_node *kn)
+{ return NULL; }
+
static inline struct kernfs_root *
kernfs_create_root(struct kernfs_syscall_ops *scops, unsigned int flags,
void *priv)
--
2.4.3
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[toc] | [next] | [standalone]
| From | Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
|---|---|
| Date | 2015-06-16 23:00 +0200 |
| Message-ID | <pC67E-5mw-9@gated-at.bofh.it> |
| In reply to | #1166327 |
On Tue, Jun 16, 2015 at 03:10:14PM -0400, Tejun Heo wrote: > Move kernfs_get_inode() prototype from fs/kernfs/kernfs-internal.h to > include/linux/kernfs.h. It obtains the matching inode for a > kernfs_node. > > It will be used by cgroup for inode based permission checks for now > but is generally useful. > > Signed-off-by: Tejun Heo <tj@kernel.org> > Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> > --- > Hello, Greg. > > Given that cgroup will be the first and only, for now, user, I think > it'd be the eaiest to route this with the related cgroup patches > through the cgroup tree. What do you think? That's fine with me, feel free to add: Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> to it. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web