[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <eedc1f82-1f99-421c-9b92-2155e5991a7f@huawei.com>
Date: Fri, 27 Jun 2025 09:13:55 +0800
From: Wang Liang <wangliang74@...wei.com>
To: Ido Schimmel <idosch@...sch.org>
CC: <davem@...emloft.net>, <edumazet@...gle.com>, <kuba@...nel.org>,
<pabeni@...hat.com>, <horms@...nel.org>, <dsahern@...nel.org>,
<yuehaibing@...wei.com>, <zhangchangzhong@...wei.com>,
<netdev@...r.kernel.org>, <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH net-next] net: add sysctl ndisc_debug
在 2025/6/24 22:31, Ido Schimmel 写道:
> On Tue, Jun 24, 2025 at 08:51:15PM +0800, Wang Liang wrote:
>> Ipv6 ndisc uses ND_PRINTK to print logs. However it only works when
>> ND_DEBUG was set in the compilation phase. This patch adds sysctl
>> ndisc_debug, so we can change the print switch when system is running and
>> get ipv6 ndisc log to debug.
> Is there a good reason to do this instead of using dynamic debug? Note
> that we will never be able to remove this sysctl.
>
> Users of vanilla kernels can only see the messages printed with 'val'
> being 0 or 1. Maybe convert them to call net_{err,warn}_ratelimited()
> instead of ND_PRINTK() and convert the rest to net_dbg_ratelimited() so
> that users will be able to enable / disable them during runtime via the
> dynamic debug interface?
Hi! Thanks for your review!
Yes, you are right. Dynamic debug is indeed a better choice.
I will use it to replace sysctl in v2.
------
Best regards
Wang Liang
Powered by blists - more mailing lists