[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1a989ae0-f391-161c-6839-f3d0a617a173@samsung.com>
Date: Mon, 15 May 2023 14:28:19 +0200
From: Marek Szyprowski <m.szyprowski@...sung.com>
To: Ido Schimmel <idosch@...sch.org>, Jiri Pirko <jiri@...nulli.us>
Cc: netdev@...r.kernel.org, kuba@...nel.org, pabeni@...hat.com,
davem@...emloft.net, edumazet@...gle.com, jacob.e.keller@...el.com,
saeedm@...dia.com, moshe@...dia.com
Subject: Re: [patch net] devlink: change per-devlink netdev notifier to
static one
On 15.05.2023 14:05, Ido Schimmel wrote:
> On Mon, May 15, 2023 at 01:35:18PM +0200, Jiri Pirko wrote:
>> Thanks for the report. From the first sight, don't have a clue what may
>> be wrong. Debugging.
> I guess he has CONFIG_NET_NS disabled which turns "__net_initdata" to
> "__initdata" and frees the notifier block after init. "__net_initdata"
> is a NOP when CONFIG_NET_NS is enabled.
>
> Maybe this will help:
>
> diff --git a/net/devlink/core.c b/net/devlink/core.c
> index 0e58eee44bdb..c23ebabadc52 100644
> --- a/net/devlink/core.c
> +++ b/net/devlink/core.c
> @@ -294,7 +294,7 @@ static struct pernet_operations devlink_pernet_ops __net_initdata = {
> .pre_exit = devlink_pernet_pre_exit,
> };
>
> -static struct notifier_block devlink_port_netdevice_nb __net_initdata = {
> +static struct notifier_block devlink_port_netdevice_nb = {
> .notifier_call = devlink_port_netdevice_event,
> };
Bingo, this fixes the issue.
Feel free to add:
Reported-by: Marek Szyprowski <m.szyprowski@...sung.com>
Tested-by: Marek Szyprowski <m.szyprowski@...sung.com>
to the final patch. Thanks!
Best regards
--
Marek Szyprowski, PhD
Samsung R&D Institute Poland
Powered by blists - more mailing lists