netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jiri Pirko <jiri@resnulli.us>
To: Jakub Kicinski <jakub.kicinski@netronome.com>
Cc: netdev@vger.kernel.org, davem@davemloft.net,
	stephen@networkplumber.org, dsahern@gmail.com,
	mlxsw@mellanox.com
Subject: Re: [patch net-next v3 1/3] net: devlink: allow to change namespaces
Date: Tue, 13 Aug 2019 08:13:55 +0200	[thread overview]
Message-ID: <20190813061355.GF2428@nanopsycho> (raw)
In-Reply-To: <20190812182122.5bc71d30@cakuba.netronome.com>

Tue, Aug 13, 2019 at 03:21:22AM CEST, jakub.kicinski@netronome.com wrote:
>On Mon, 12 Aug 2019 15:47:49 +0200, Jiri Pirko wrote:
>> @@ -6953,9 +7089,33 @@ int devlink_compat_switch_id_get(struct net_device *dev,
>>  	return 0;
>>  }
>>  
>> +static void __net_exit devlink_pernet_exit(struct net *net)
>> +{
>> +	struct devlink *devlink;
>> +
>> +	mutex_lock(&devlink_mutex);
>> +	list_for_each_entry(devlink, &devlink_list, list)
>> +		if (net_eq(devlink_net(devlink), net))
>> +			devlink_netns_change(devlink, &init_net);
>> +	mutex_unlock(&devlink_mutex);
>> +}
>
>Just to be sure - this will not cause any locking issues?
>Usually the locking order goes devlink -> rtnl

rtnl is not taken. Do I miss something?

  reply	other threads:[~2019-08-13  6:13 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-08-12 13:47 [patch net-next v3 0/3] net: devlink: Finish network namespace support Jiri Pirko
2019-08-12 13:47 ` [patch net-next v3 1/3] net: devlink: allow to change namespaces Jiri Pirko
2019-08-13  1:21   ` Jakub Kicinski
2019-08-13  6:13     ` Jiri Pirko [this message]
2019-08-13 17:04       ` Jakub Kicinski
2019-08-12 13:47 ` [patch net-next v3 2/3] net: devlink: export devlink net set/get helpers Jiri Pirko
2019-08-12 13:47 ` [patch net-next v3 3/3] netdevsim: create devlink and netdev instances in namespace Jiri Pirko
2019-08-12 13:51 ` [patch iproute2-next v3 1/2] devlink: introduce cmdline option to switch to a different namespace Jiri Pirko
2019-08-12 13:51 ` [patch iproute2-next v3 2/2] devlink: add support for network namespace change Jiri Pirko
2019-08-13  0:24 ` [patch net-next v3 0/3] net: devlink: Finish network namespace support David Ahern
2019-08-13  1:11   ` Jakub Kicinski
2019-08-13  1:46     ` David Ahern
2019-08-13 17:45       ` Jakub Kicinski
2019-08-13  6:07     ` Jiri Pirko
2019-08-13  6:09   ` Jiri Pirko

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190813061355.GF2428@nanopsycho \
    --to=jiri@resnulli.us \
    --cc=davem@davemloft.net \
    --cc=dsahern@gmail.com \
    --cc=jakub.kicinski@netronome.com \
    --cc=mlxsw@mellanox.com \
    --cc=netdev@vger.kernel.org \
    --cc=stephen@networkplumber.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).