netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jakub Kicinski <kuba@kernel.org>
To: Moon Yeounsu <yyyynoom@gmail.com>
Cc: Andrew Lunn <andrew+netdev@lunn.ch>,
	"David S. Miller" <davem@davemloft.net>,
	Eric Dumazet <edumazet@google.com>,
	Paolo Abeni <pabeni@redhat.com>,
	netdev@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH net-next] net: dlink: add Kconfig option for RMON registers
Date: Mon, 19 May 2025 16:57:58 -0700	[thread overview]
Message-ID: <20250519165758.58157a0b@kernel.org> (raw)
In-Reply-To: <20250519214046.47856-2-yyyynoom@gmail.com>

On Tue, 20 May 2025 06:40:45 +0900 Moon Yeounsu wrote:
> This patch adds a Kconfig option to enable MMIO for RMON registers.
> 
> To read RMON registers, the code `dw32(RmonStatMask, 0x0007ffff);`
> must also be skipped, so this patch adds a preprocessor directive to
> that line as well.
> 
> On the `D-Link DGE-550T Rev-A3`, RMON statistics registers can be read
> correctly and statistic data can be collected. However, the behavior on
> other hardware is uncertain, and there may be undiscovered issues even
> on this device. Thus, the default setting is `no`, allowing users to
> enable it manually if necessary.

Kconfig is not a great choice for chip specific logic.
You should check some sort of chip ID register or PCI ID
to match the chip version at runtime. Most users don't compile
their own kernels.
-- 
pw-bot: cr

  reply	other threads:[~2025-05-19 23:57 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-05-19 21:40 [PATCH net-next] net: dlink: add Kconfig option for RMON registers Moon Yeounsu
2025-05-19 23:57 ` Jakub Kicinski [this message]
2025-05-22  6:20   ` Moon Yeounsu
2025-05-22 15:39     ` Jakub Kicinski

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=20250519165758.58157a0b@kernel.org \
    --to=kuba@kernel.org \
    --cc=andrew+netdev@lunn.ch \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=yyyynoom@gmail.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;
as well as URLs for NNTP newsgroup(s).