mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Wang Liang <wangliang74@huawei.com>
To: Ido Schimmel <idosch@idosch.org>
Cc: <davem@davemloft.net>, <edumazet@google.com>, <kuba@kernel.org>,
	<pabeni@redhat.com>, <horms@kernel.org>, <dsahern@kernel.org>,
	<yuehaibing@huawei.com>, <zhangchangzhong@huawei.com>,
	<netdev@vger.kernel.org>, <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH net-next] net: add sysctl ndisc_debug
Date: Fri, 27 Jun 2025 09:13:55 +0800	[thread overview]
Message-ID: <eedc1f82-1f99-421c-9b92-2155e5991a7f@huawei.com> (raw)
In-Reply-To: <aFq2s3SnM1lzuGHb@shredder>


在 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

      reply	other threads:[~2025-06-27  1:13 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-06-24 12:51 Wang Liang
2025-06-24 14:31 ` Ido Schimmel
2025-06-27  1:13   ` Wang Liang [this message]

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=eedc1f82-1f99-421c-9b92-2155e5991a7f@huawei.com \
    --to=wangliang74@huawei.com \
    --cc=davem@davemloft.net \
    --cc=dsahern@kernel.org \
    --cc=edumazet@google.com \
    --cc=horms@kernel.org \
    --cc=idosch@idosch.org \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=yuehaibing@huawei.com \
    --cc=zhangchangzhong@huawei.com \
    /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

all inboxes | Powered by JetHome®