From: Zaiyu Wang <zaiyuwang@trustnetic.com>
To: dev@dpdk.org
Cc: Zaiyu Wang <zaiyuwang@trustnetic.com>,
stable@dpdk.org, Jiawen Wu <jiawenwu@trustnetic.com>
Subject: [PATCH v6 06/15] net/txgbe: set i2c sda hold time
Date: Tue, 29 Sep 2026 21:04:37 +0800 [thread overview]
Message-ID: <2D2AE43BFDF868BE+20260929130611.4871-7-zaiyuwang@trustnetic.com> (raw)
In-Reply-To: <20260929130611.4871-1-zaiyuwang@trustnetic.com>
The data_in_hold_time measured on the oscilloscope does not meet the
hardware requirement, which can corrupt SFP EEPROM reads over I2C.
Set the I2C SDA hold time to 100 (0x64) I2C clock periods for both
RX and TX in txgbe_i2c_start().
Fixes: 00970f6398c8 ("net/txgbe: fix reading SFP module SFF-8472 data")
Cc: stable@dpdk.org
Signed-off-by: Zaiyu Wang <zaiyuwang@trustnetic.com>
---
drivers/net/txgbe/base/txgbe_phy.c | 3 +++
drivers/net/txgbe/base/txgbe_regs.h | 3 +++
2 files changed, 6 insertions(+)
diff --git a/drivers/net/txgbe/base/txgbe_phy.c b/drivers/net/txgbe/base/txgbe_phy.c
index 2fbe50e242..8b653f0aeb 100644
--- a/drivers/net/txgbe/base/txgbe_phy.c
+++ b/drivers/net/txgbe/base/txgbe_phy.c
@@ -1334,6 +1334,9 @@ static void txgbe_i2c_start(struct txgbe_hw *hw, u8 dev_addr)
wr32(hw, TXGBE_I2CSCLTMOUT, 0xFFFFFF);
wr32(hw, TXGBE_I2CSDATMOUT, 0xFFFFFF);
+ wr32m(hw, TXGBE_I2C_SDA_HOLD,
+ TXGBE_I2C_SDA_RX_HOLD | TXGBE_I2C_SDA_TX_HOLD, 0x640064);
+
wr32(hw, TXGBE_I2CICM, 0);
wr32(hw, TXGBE_I2CENA, 1);
}
diff --git a/drivers/net/txgbe/base/txgbe_regs.h b/drivers/net/txgbe/base/txgbe_regs.h
index bf46a80862..b0042dc0d6 100644
--- a/drivers/net/txgbe/base/txgbe_regs.h
+++ b/drivers/net/txgbe/base/txgbe_regs.h
@@ -1610,6 +1610,9 @@ enum txgbe_5tuple_protocol {
#define TXGBE_I2CSTAT_MST ((1U << 5))
#define TXGBE_I2CSCLTMOUT 0x0149AC
#define TXGBE_I2CSDATMOUT 0x0149B0 /*I2C SDA Stuck at Low Timeout*/
+#define TXGBE_I2C_SDA_HOLD 0x1497C /* SDA hold time length reg */
+#define TXGBE_I2C_SDA_RX_HOLD 0xff0000 /* SDA rx hold time length reg */
+#define TXGBE_I2C_SDA_TX_HOLD 0xffff /* SDA tx hold time length reg */
/* port cfg Registers */
#define TXGBE_PORTSTAT 0x014404
--
2.55.0.windows.2
next prev parent reply other threads:[~2026-09-29 13:07 UTC|newest]
Thread overview: 116+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20260827114309.10530-1-zaiyuwang@trustnetic.com>
2026-08-27 11:41 ` [PATCH 01/13] net/txgbe: fix e56 PHY configuration error Zaiyu Wang
2026-08-27 11:41 ` [PATCH 02/13] net/txgbe: fix incorrect link state in 10G forced mode Zaiyu Wang
2026-08-27 11:41 ` [PATCH 03/13] net/txgbe: do not force reconfig on link retry Zaiyu Wang
2026-08-27 11:41 ` [PATCH 04/13] net/txgbe: set i2c sda hold time Zaiyu Wang
2026-08-27 11:41 ` [PATCH 05/13] net/txgbe: fix link speed display info for 10G mode Zaiyu Wang
2026-08-27 11:41 ` [PATCH 06/13] net/txgbe: remove stale outer UDP checksum offload flag Zaiyu Wang
2026-08-27 11:41 ` [PATCH 07/13] net/txgbe: add offload support for tunnel type UDP Zaiyu Wang
2026-08-27 11:42 ` [PATCH 08/13] net/txgbe: fix SFP hot-plug when auto-negotiation is on Zaiyu Wang
2026-08-27 11:42 ` [PATCH 09/13] net/txgbe: fix DAC hot-plug on 40G NIC with auto-negotiation Zaiyu Wang
2026-08-27 11:42 ` [PATCH 10/13] net/txgbe: add backplane FFE and capability devargs Zaiyu Wang
2026-08-27 11:42 ` [PATCH 11/13] net/txgbe: add devarg to turn off Tx laser for 40G NIC Zaiyu Wang
2026-08-27 11:42 ` [PATCH 12/13] net/txgbe: fix CR/KR link training and recovery Zaiyu Wang
2026-08-27 11:42 ` [PATCH 13/13] net/txgbe: align link capabilities and DAC classification Zaiyu Wang
2026-09-08 12:38 ` [PATCH v2 00/15] Wangxun fixes and new features Zaiyu Wang
[not found] ` <20260908124047.2284-1-zaiyuwang@trustnetic.com>
2026-09-08 12:38 ` [PATCH v2 01/15] net/txgbe: fix failure to configure 10G on dual-speed DAC Zaiyu Wang
2026-09-08 12:38 ` [PATCH v2 02/15] net/txgbe: fix e56 PHY configuration error Zaiyu Wang
2026-09-08 12:38 ` [PATCH v2 03/15] net/txgbe: fix incorrect link state in 10G forced mode Zaiyu Wang
2026-09-08 12:38 ` [PATCH v2 04/15] net/txgbe: do not force reconfig on link retry Zaiyu Wang
2026-09-08 12:38 ` [PATCH v2 05/15] net/txgbe: set i2c sda hold time Zaiyu Wang
2026-09-08 12:38 ` [PATCH v2 06/15] net/txgbe: fix link speed display info for 10G mode Zaiyu Wang
2026-09-08 12:38 ` [PATCH v2 07/15] net/txgbe: remove stale outer UDP checksum offload flag Zaiyu Wang
2026-09-08 12:38 ` [PATCH v2 08/15] net/txgbe: add offload support for tunnel type UDP Zaiyu Wang
2026-09-08 12:38 ` [PATCH v2 09/15] net/txgbe: fix SFP hot-plug when auto-negotiation is on Zaiyu Wang
2026-09-08 12:38 ` [PATCH v2 10/15] net/txgbe: fix DAC hot-plug on 40G NIC with auto-negotiation Zaiyu Wang
2026-09-08 12:38 ` [PATCH v2 11/15] net/txgbe: fix 40G FFE tuning applied to first lane only Zaiyu Wang
2026-09-08 12:38 ` [PATCH v2 12/15] net/txgbe: add pre2 and backplane capability devargs Zaiyu Wang
2026-09-08 12:38 ` [PATCH v2 13/15] net/txgbe: add devarg to turn off Tx laser for 40G NIC Zaiyu Wang
2026-09-08 12:38 ` [PATCH v2 14/15] net/txgbe: fix CR/KR link training and recovery Zaiyu Wang
2026-09-08 12:39 ` [PATCH v2 15/15] net/txgbe: align link capabilities and DAC classification Zaiyu Wang
2026-09-08 13:25 ` [PATCH v3 00/15] Wangxun fixes and new features Zaiyu Wang
2026-09-08 14:20 ` Stephen Hemminger
[not found] ` <20260908132742.2661-1-zaiyuwang@trustnetic.com>
2026-09-08 13:25 ` [PATCH v3 01/15] net/txgbe: fix failure to configure 10G on dual-speed DAC Zaiyu Wang
2026-09-08 13:25 ` [PATCH v3 02/15] net/txgbe: fix e56 PHY configuration error Zaiyu Wang
2026-09-08 13:25 ` [PATCH v3 03/15] net/txgbe: fix incorrect link state in 10G forced mode Zaiyu Wang
2026-09-08 13:25 ` [PATCH v3 04/15] net/txgbe: do not force reconfig on link retry Zaiyu Wang
2026-09-08 13:25 ` [PATCH v3 05/15] net/txgbe: set i2c sda hold time Zaiyu Wang
2026-09-08 13:25 ` [PATCH v3 06/15] net/txgbe: fix link speed display info for 10G mode Zaiyu Wang
2026-09-08 13:25 ` [PATCH v3 07/15] net/txgbe: remove stale outer UDP checksum offload flag Zaiyu Wang
2026-09-08 13:25 ` [PATCH v3 08/15] net/txgbe: add offload support for tunnel type UDP Zaiyu Wang
2026-09-08 13:25 ` [PATCH v3 09/15] net/txgbe: fix SFP hot-plug when auto-negotiation is on Zaiyu Wang
2026-09-08 13:25 ` [PATCH v3 10/15] net/txgbe: fix DAC hot-plug on 40G NIC with auto-negotiation Zaiyu Wang
2026-09-08 13:25 ` [PATCH v3 11/15] net/txgbe: fix 40G FFE tuning applied to first lane only Zaiyu Wang
2026-09-08 13:25 ` [PATCH v3 12/15] net/txgbe: add pre2 and backplane capability devargs Zaiyu Wang
2026-09-08 13:25 ` [PATCH v3 13/15] net/txgbe: add devarg to turn off Tx laser for 40G NIC Zaiyu Wang
2026-09-08 13:25 ` [PATCH v3 14/15] net/txgbe: fix CR/KR link training and recovery Zaiyu Wang
2026-09-08 13:26 ` [PATCH v3 15/15] net/txgbe: align link capabilities and DAC classification Zaiyu Wang
2026-09-22 12:37 ` [PATCH v4 00/16] Wangxun fixes and new features Zaiyu Wang
2026-09-22 13:35 ` Stephen Hemminger
2026-09-29 11:21 ` Zaiyu Wang
[not found] ` <20260922125414.3638-1-zaiyuwang@trustnetic.com>
2026-09-22 12:37 ` [PATCH v4 01/16] net/txgbe: fix failure to configure 10G on dual-speed DAC Zaiyu Wang
2026-09-22 12:37 ` [PATCH v4 02/16] net/txgbe: use the requested speed in E56 AN setup Zaiyu Wang
2026-09-22 12:37 ` [PATCH v4 03/16] net/txgbe: fix e56 PHY configuration error Zaiyu Wang
2026-09-22 12:37 ` [PATCH v4 04/16] net/txgbe: fix incorrect link state in 10G forced mode Zaiyu Wang
2026-09-22 12:37 ` [PATCH v4 05/16] net/txgbe: do not force reconfig on link retry Zaiyu Wang
2026-09-22 12:37 ` [PATCH v4 06/16] net/txgbe: set i2c sda hold time Zaiyu Wang
2026-09-22 12:37 ` [PATCH v4 07/16] net/txgbe: fix link speed display info for 10G mode Zaiyu Wang
2026-09-22 12:37 ` [PATCH v4 08/16] net/txgbe: remove stale outer UDP checksum offload flag Zaiyu Wang
2026-09-22 12:37 ` [PATCH v4 09/16] net/txgbe: add offload support for tunnel type UDP Zaiyu Wang
2026-09-22 12:37 ` [PATCH v4 10/16] net/txgbe: fix SFP hot-plug when auto-negotiation is on Zaiyu Wang
2026-09-22 12:37 ` [PATCH v4 11/16] net/txgbe: fix DAC hot-plug on 40G NIC with auto-negotiation Zaiyu Wang
2026-09-22 12:37 ` [PATCH v4 12/16] net/txgbe: fix 40G FFE tuning applied to first lane only Zaiyu Wang
2026-09-22 12:37 ` [PATCH v4 13/16] net/txgbe: fix unset pre2 FFE tap and backplane capability Zaiyu Wang
2026-09-22 12:37 ` [PATCH v4 14/16] net/txgbe: add devarg to turn off Tx laser for 40G NIC Zaiyu Wang
2026-09-22 12:37 ` [PATCH v4 15/16] net/txgbe: fix CR/KR link training and recovery Zaiyu Wang
2026-09-22 12:37 ` [PATCH v4 16/16] net/txgbe: align link capabilities and DAC classification Zaiyu Wang
2026-09-29 11:18 ` [PATCH v5 00/15] Wangxun fixes and new features Zaiyu Wang
[not found] ` <20260929112119.4516-1-zaiyuwang@trustnetic.com>
2026-09-29 11:18 ` [PATCH v5 01/15] net/txgbe: fix failure to configure 10G on dual-speed DAC Zaiyu Wang
2026-09-29 11:18 ` [PATCH v5 02/15] net/txgbe: use the requested speed in E56 AN setup Zaiyu Wang
2026-09-29 11:18 ` [PATCH v5 03/15] net/txgbe: fix e56 PHY configuration error Zaiyu Wang
2026-09-29 11:18 ` [PATCH v5 04/15] net/txgbe: fix incorrect link state in 10G forced mode Zaiyu Wang
2026-09-29 11:18 ` [PATCH v5 05/15] net/txgbe: do not force reconfig on link retry Zaiyu Wang
2026-09-29 11:18 ` [PATCH v5 06/15] net/txgbe: set i2c sda hold time Zaiyu Wang
2026-09-29 11:18 ` [PATCH v5 07/15] net/txgbe: fix link speed display info for 10G mode Zaiyu Wang
2026-09-29 11:18 ` [PATCH v5 08/15] net/txgbe: remove stale outer UDP checksum offload flag Zaiyu Wang
2026-09-29 11:18 ` [PATCH v5 09/15] net/txgbe: fix SFP hot-plug when auto-negotiation is on Zaiyu Wang
2026-09-29 11:18 ` [PATCH v5 10/15] net/txgbe: fix DAC hot-plug on 40G NIC with auto-negotiation Zaiyu Wang
2026-09-29 11:18 ` [PATCH v5 11/15] net/txgbe: fix 40G FFE tuning applied to first lane only Zaiyu Wang
2026-09-29 11:18 ` [PATCH v5 12/15] net/txgbe: add pre2 FFE tap and backplane capability devargs Zaiyu Wang
2026-09-29 11:18 ` [PATCH v5 13/15] net/txgbe: add devarg to turn off Tx laser for 40G NIC Zaiyu Wang
2026-09-29 11:18 ` [PATCH v5 14/15] net/txgbe: fix CR/KR link training and recovery Zaiyu Wang
2026-09-29 11:18 ` [PATCH v5 15/15] net/txgbe: align link capabilities and DAC classification Zaiyu Wang
2026-09-29 13:04 ` [PATCH v6 00/15] Wangxun fixes and new features Zaiyu Wang
2026-09-29 16:05 ` Stephen Hemminger
2026-09-30 10:22 ` Zaiyu Wang
[not found] ` <20260929130611.4871-1-zaiyuwang@trustnetic.com>
2026-09-29 13:04 ` [PATCH v6 01/15] net/txgbe: fix failure to configure 10G on dual-speed DAC Zaiyu Wang
2026-09-29 13:04 ` [PATCH v6 02/15] net/txgbe: use the requested speed in E56 AN setup Zaiyu Wang
2026-09-29 13:04 ` [PATCH v6 03/15] net/txgbe: fix e56 PHY configuration error Zaiyu Wang
2026-09-29 13:04 ` [PATCH v6 04/15] net/txgbe: fix incorrect link state in 10G forced mode Zaiyu Wang
2026-09-29 13:04 ` [PATCH v6 05/15] net/txgbe: do not force reconfig on link retry Zaiyu Wang
2026-09-29 13:04 ` Zaiyu Wang [this message]
2026-09-29 13:04 ` [PATCH v6 07/15] net/txgbe: fix link speed display info for 10G mode Zaiyu Wang
2026-09-29 13:04 ` [PATCH v6 08/15] net/txgbe: remove stale outer UDP checksum offload flag Zaiyu Wang
2026-09-29 13:04 ` [PATCH v6 09/15] net/txgbe: fix SFP hot-plug when auto-negotiation is on Zaiyu Wang
2026-09-29 13:04 ` [PATCH v6 10/15] net/txgbe: fix DAC hot-plug on 40G NIC with auto-negotiation Zaiyu Wang
2026-09-29 13:04 ` [PATCH v6 11/15] net/txgbe: fix 40G FFE tuning applied to first lane only Zaiyu Wang
2026-09-29 13:04 ` [PATCH v6 12/15] net/txgbe: add pre2 FFE tap and backplane capability devargs Zaiyu Wang
2026-09-29 13:04 ` [PATCH v6 13/15] net/txgbe: add devarg to turn off Tx laser for 40G NIC Zaiyu Wang
2026-09-29 13:04 ` [PATCH v6 14/15] net/txgbe: fix CR/KR link training and recovery Zaiyu Wang
2026-09-29 13:04 ` [PATCH v6 15/15] net/txgbe: align link capabilities and DAC classification Zaiyu Wang
2026-09-30 10:17 ` [PATCH v7 00/15] Wangxun fixes and new features Zaiyu Wang
2026-09-30 16:18 ` Stephen Hemminger
[not found] ` <20260930102042.2214-1-zaiyuwang@trustnetic.com>
2026-09-30 10:17 ` [PATCH v7 01/15] net/txgbe: fix failure to configure 10G on dual-speed DAC Zaiyu Wang
2026-09-30 10:17 ` [PATCH v7 02/15] net/txgbe: use the requested speed in E56 AN setup Zaiyu Wang
2026-09-30 10:17 ` [PATCH v7 03/15] net/txgbe: fix e56 PHY configuration error Zaiyu Wang
2026-09-30 10:17 ` [PATCH v7 04/15] net/txgbe: fix incorrect link state in 10G forced mode Zaiyu Wang
2026-09-30 10:17 ` [PATCH v7 05/15] net/txgbe: do not force reconfig on link retry Zaiyu Wang
2026-09-30 10:17 ` [PATCH v7 06/15] net/txgbe: set i2c sda hold time Zaiyu Wang
2026-09-30 10:17 ` [PATCH v7 07/15] net/txgbe: fix link speed display info for 10G mode Zaiyu Wang
2026-09-30 10:17 ` [PATCH v7 08/15] net/txgbe: remove stale outer UDP checksum offload flag Zaiyu Wang
2026-09-30 10:17 ` [PATCH v7 09/15] net/txgbe: fix SFP hot-plug when auto-negotiation is on Zaiyu Wang
2026-09-30 10:17 ` [PATCH v7 10/15] net/txgbe: fix DAC hot-plug on 40G NIC with auto-negotiation Zaiyu Wang
2026-09-30 10:17 ` [PATCH v7 11/15] net/txgbe: fix 40G FFE tuning applied to first lane only Zaiyu Wang
2026-09-30 10:17 ` [PATCH v7 12/15] net/txgbe: add pre2 FFE tap and backplane capability devargs Zaiyu Wang
2026-09-30 10:18 ` [PATCH v7 13/15] net/txgbe: add devarg to turn off Tx laser for 40G NIC Zaiyu Wang
2026-09-30 10:18 ` [PATCH v7 14/15] net/txgbe: fix CR/KR link training and recovery Zaiyu Wang
2026-09-30 10:18 ` [PATCH v7 15/15] net/txgbe: align link capabilities and DAC classification Zaiyu Wang
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=2D2AE43BFDF868BE+20260929130611.4871-7-zaiyuwang@trustnetic.com \
--to=zaiyuwang@trustnetic.com \
--cc=dev@dpdk.org \
--cc=jiawenwu@trustnetic.com \
--cc=stable@dpdk.org \
/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