This function is only used in get_ve_by_id. Inline it.

Signed-off-by: Vladimir Davydov <vdavy...@parallels.com>
---
 include/linux/ve_proto.h | 1 -
 kernel/ve/ve.c           | 8 +-------
 2 files changed, 1 insertion(+), 8 deletions(-)

diff --git a/include/linux/ve_proto.h b/include/linux/ve_proto.h
index d491ab01853b..3206dd847fd6 100644
--- a/include/linux/ve_proto.h
+++ b/include/linux/ve_proto.h
@@ -61,7 +61,6 @@ extern struct list_head ve_list_head;
 #define for_each_ve(ve)        list_for_each_entry((ve), &ve_list_head, 
ve_list)
 extern struct mutex ve_list_lock;
 extern struct ve_struct *get_ve_by_id(envid_t);
-extern struct ve_struct *__find_ve_by_id(envid_t);
 extern struct cgroup *ve_cgroup_open(struct cgroup *root, int flags, envid_t 
veid);
 extern int ve_cgroup_remove(struct cgroup *root, envid_t veid);
 
diff --git a/kernel/ve/ve.c b/kernel/ve/ve.c
index 609ea75ad30a..77eff94963a5 100644
--- a/kernel/ve/ve.c
+++ b/kernel/ve/ve.c
@@ -217,17 +217,11 @@ const char *task_ve_name(struct task_struct *task)
 }
 EXPORT_SYMBOL(task_ve_name);
 
-struct ve_struct *__find_ve_by_id(envid_t veid)
-{
-       return idr_find(&ve_idr, veid);
-}
-EXPORT_SYMBOL(__find_ve_by_id);
-
 struct ve_struct *get_ve_by_id(envid_t veid)
 {
        struct ve_struct *ve;
        rcu_read_lock();
-       ve = __find_ve_by_id(veid);
+       ve = idr_find(&ve_idr, veid);
        if (ve && !css_tryget(&ve->css))
                ve = NULL;
        rcu_read_unlock();
-- 
2.1.4

_______________________________________________
Devel mailing list
Devel@openvz.org
https://lists.openvz.org/mailman/listinfo/devel

Reply via email to