DPDK patches and discussions
 help / color / mirror / Atom feed
From: Zaiyu Wang <zaiyuwang@trustnetic.com>
To: dev@dpdk.org
Cc: Zaiyu Wang <zaiyuwang@trustnetic.com>,
	Jiawen Wu <jiawenwu@trustnetic.com>,
	Jian Wang <jianwang@trustnetic.com>
Subject: [PATCH 4/6] net/txgbe: add BME reset for Amber-Lite 25G VF
Date: Thu, 23 Oct 2025 20:13:53 +0800	[thread overview]
Message-ID: <20251023121356.21944-5-zaiyuwang@trustnetic.com> (raw)
In-Reply-To: <20251023121356.21944-1-zaiyuwang@trustnetic.com>

During VF reset, the PCIE BME (bus master enable) register needs to be
reconfigured to ensure proper NIC functionality.

Signed-off-by: Zaiyu Wang <zaiyuwang@trustnetic.com>
---
 drivers/net/txgbe/base/txgbe_regs.h | 2 ++
 drivers/net/txgbe/base/txgbe_vf.c   | 4 ++++
 2 files changed, 6 insertions(+)

diff --git a/drivers/net/txgbe/base/txgbe_regs.h b/drivers/net/txgbe/base/txgbe_regs.h
index cfe9b94e78..638404bdff 100644
--- a/drivers/net/txgbe/base/txgbe_regs.h
+++ b/drivers/net/txgbe/base/txgbe_regs.h
@@ -1273,6 +1273,8 @@ enum txgbe_5tuple_protocol {
 #define TXGBE_BMECTL                    0x012020
 #define TXGBE_BMEPEND                   0x000168
 
+#define TXGBE_BME_AML                   0x0004B8
+
 /* P2V Mailbox */
 #define TXGBE_MBMEM(i)           (0x005000 + 0x40 * (i)) /* 0-63 */
 #define TXGBE_MBCTL(i)           (0x000600 + 4 * (i)) /* 0-63 */
diff --git a/drivers/net/txgbe/base/txgbe_vf.c b/drivers/net/txgbe/base/txgbe_vf.c
index 5e41ba1a3e..efa32ca10a 100644
--- a/drivers/net/txgbe/base/txgbe_vf.c
+++ b/drivers/net/txgbe/base/txgbe_vf.c
@@ -133,6 +133,10 @@ s32 txgbe_reset_hw_vf(struct txgbe_hw *hw)
 		usec_delay(5);
 	}
 
+	/* amlite: bme */
+	if (hw->mac.type == txgbe_mac_aml_vf)
+		wr32(hw, TXGBE_BME_AML, 0x1);
+
 	if (!timeout)
 		return TXGBE_ERR_RESET_FAILED;
 
-- 
2.21.0.windows.1


  parent reply	other threads:[~2025-10-23 12:14 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-10-23 12:13 [PATCH 0/6] net/txgbe: fill in functionality gaps for Amber-Lite NICs Zaiyu Wang
2025-10-23 12:13 ` [PATCH 1/6] net/txgbe: add Amber-Lite 25G VF IDs to PCI ID map Zaiyu Wang
2025-10-23 12:13 ` [PATCH 2/6] net/txgbe: add flush operation for Amber-Lite NICs Zaiyu Wang
2025-10-23 12:13 ` [PATCH 3/6] net/txgbe: add RSS register selection for Amber-Lite 25G VF Zaiyu Wang
2025-10-23 12:13 ` Zaiyu Wang [this message]
2025-10-23 12:13 ` [PATCH 5/6] net/txgbe: add check link for Amber-Lite VF Zaiyu Wang
2025-10-23 12:13 ` [PATCH 6/6] net/txgbe: add PF-triggered VF link status change handling Zaiyu Wang
2025-10-24 22:49 ` [PATCH 0/6] net/txgbe: fill in functionality gaps for Amber-Lite NICs Stephen Hemminger

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=20251023121356.21944-5-zaiyuwang@trustnetic.com \
    --to=zaiyuwang@trustnetic.com \
    --cc=dev@dpdk.org \
    --cc=jianwang@trustnetic.com \
    --cc=jiawenwu@trustnetic.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).