[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAHNKnsR5X8Axttk_YX=fpi5h6iV191fLJ6MZqrLvhZvPe==mXA@mail.gmail.com>
Date: Sun, 20 Jun 2021 18:20:20 +0300
From: Sergey Ryazanov <ryazanov.s.a@...il.com>
To: M Chetan Kumar <m.chetan.kumar@...el.com>
Cc: Loic Poulain <loic.poulain@...aro.org>,
Johannes Berg <johannes@...solutions.net>,
Jakub Kicinski <kuba@...nel.org>,
"David S. Miller" <davem@...emloft.net>, netdev@...r.kernel.org,
Intel Corporation <linuxwwan@...el.com>
Subject: Re: [PATCH net-next 06/10] net: iosm: drop custom netdev(s) removing
Hello Chetan,
On Tue, Jun 15, 2021 at 3:30 AM Sergey Ryazanov <ryazanov.s.a@...il.com> wrote:
> Since the last commit, the WWAN core will remove all our network
> interfaces for us at the time of the WWAN netdev ops unregistering.
> Therefore, we can safely drop the custom code that cleaning the list of
> created netdevs. Anyway it no longer removes any netdev, since all
> netdevs were removed earlier in the wwan_unregister_ops() call.
Are you Ok with this change? I plan to submit a next version of the
series. If you have any objections, I can address them in V2.
BTW, if IOSM modems have a default data channel, I can add a separate
patch to the series to create a default network interface for IOSM if
you tell me which link id is used for the default data channel.
> Signed-off-by: Sergey Ryazanov <ryazanov.s.a@...il.com>
> CC: M Chetan Kumar <m.chetan.kumar@...el.com>
> CC: Intel Corporation <linuxwwan@...el.com>
> ---
> drivers/net/wwan/iosm/iosm_ipc_wwan.c | 15 +--------------
> 1 file changed, 1 insertion(+), 14 deletions(-)
>
> diff --git a/drivers/net/wwan/iosm/iosm_ipc_wwan.c b/drivers/net/wwan/iosm/iosm_ipc_wwan.c
> index 1711b79fc616..bee9b278223d 100644
> --- a/drivers/net/wwan/iosm/iosm_ipc_wwan.c
> +++ b/drivers/net/wwan/iosm/iosm_ipc_wwan.c
> @@ -329,22 +329,9 @@ struct iosm_wwan *ipc_wwan_init(struct iosm_imem *ipc_imem, struct device *dev)
>
> void ipc_wwan_deinit(struct iosm_wwan *ipc_wwan)
> {
> - int if_id;
> -
> + /* This call will remove all child netdev(s) */
> wwan_unregister_ops(ipc_wwan->dev);
>
> - for (if_id = 0; if_id < ARRAY_SIZE(ipc_wwan->sub_netlist); if_id++) {
> - struct iosm_netdev_priv *priv;
> -
> - priv = rcu_access_pointer(ipc_wwan->sub_netlist[if_id]);
> - if (!priv)
> - continue;
> -
> - rtnl_lock();
> - ipc_wwan_dellink(ipc_wwan, priv->netdev, NULL);
> - rtnl_unlock();
> - }
> -
> mutex_destroy(&ipc_wwan->if_mutex);
>
> kfree(ipc_wwan);
--
Sergey
Powered by blists - more mailing lists