[Devel] [PATCH] net: Delete get_exec_env() from venet_init_net()
Kirill Tkhai
ktkhai at odin.com
Thu Jun 11 02:39:31 PDT 2015
It's better to avoid get_exec_env() in a place, where we easily can
do that.
get_exec_env() used to be used in the places, where caller did
set_exec_env() before the call. Delete it to make it do not confuse
us like it would be an unported place from 2.6.32.
Signed-off-by: Kirill Tkhai <ktkhai at odin.com>
---
drivers/net/venetdev.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/net/venetdev.c b/drivers/net/venetdev.c
index 6b7d8fc7..99004c2 100644
--- a/drivers/net/venetdev.c
+++ b/drivers/net/venetdev.c
@@ -1086,10 +1086,9 @@ static int venet_dev_start(struct ve_struct *ve)
static __net_init int venet_init_net(struct net *net)
{
- struct ve_struct *env;
+ struct ve_struct *env = net->owner_ve;
int err;
- env = get_exec_env();
if (env->ve_netns && net != env->ve_netns) {
/* Don't create venet-s in sub net namespaces */
return 0;
More information about the Devel
mailing list