From: Mikhail Zhilkin <csharper2005@gmail.com>
To: u-boot@lists.u-boot-project.org
Cc: jerome.forissier@arm.com, ryder.lee@mediatek.com,
weijie.gao@mediatek.com, chunfeng.yun@mediatek.com,
igor.belwon@mentallysanemainliners.org, dlechner@baylibre.com,
jstephan@baylibre.com, GSS_MTK_Uboot_upstream@mediatek.com,
trini@konsulko.com, Mikhail Zhilkin <csharper2005@gmail.com>
Subject: [PATCH v1 2/3] net: mtk_eth: an8855: enable link error recovery
Date: Sat, 7 Nov 2026 17:24:39 +0300 [thread overview]
Message-ID: <20261107142441.2104669-3-csharper2005@gmail.com> (raw)
In-Reply-To: <20261107142441.2104669-1-csharper2005@gmail.com>
Sync the Link Error Recovery configuration with the upstream Linux
driver.
Currently, the U-Boot driver explicitly clears the
AN8855_RG_LINK_ERRO_EN bit (bit 23) in the AN8855_RX_CTRL_26 register
during SGMII initialization. Setting this bit instead of clearing it
matches the Linux driver behavior, allowing the MAC/PCS to gracefully
recover from momentary link errors on marginal hardware rather than
dropping packets or the entire link.
Signed-off-by: Mikhail Zhilkin <csharper2005@gmail.com>
---
drivers/net/mtk_eth/an8855.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/mtk_eth/an8855.c b/drivers/net/mtk_eth/an8855.c
index eb037ec1382..513f4534701 100644
--- a/drivers/net/mtk_eth/an8855.c
+++ b/drivers/net/mtk_eth/an8855.c
@@ -599,7 +599,7 @@ static int an8855_port_sgmii_init(struct an8855_switch_priv *priv, u32 port)
an8855_reg_write(priv, AN8855_PLL_CTRL_0, val);
an8855_reg_read(priv, AN8855_RX_CTRL_26, &val);
- val &= ~BIT(23);
+ val |= BIT(23);
val |= BIT(26);
an8855_reg_write(priv, AN8855_RX_CTRL_26, val);
--
2.53.0
next prev parent reply other threads:[~2026-11-07 14:33 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-07 14:24 [PATCH v1 0/3] net: mtk_eth: an8855: fix packet loss and sync with Linux Mikhail Zhilkin
2026-11-07 14:24 ` [PATCH v1 1/3] net: mtk_eth: an8855: fix bitwise collision in RX_CTRL_8 register Mikhail Zhilkin
2026-11-09 21:23 ` David Lechner
2026-11-07 14:24 ` Mikhail Zhilkin [this message]
2026-11-09 21:23 ` [PATCH v1 2/3] net: mtk_eth: an8855: enable link error recovery David Lechner
2026-11-07 14:24 ` [PATCH v1 3/3] net: mtk_eth: an8855: sync SerDes analog tuning with Linux driver Mikhail Zhilkin
2026-11-09 21:25 ` David Lechner
2026-11-09 21:23 ` [PATCH v1 0/3] net: mtk_eth: an8855: fix packet loss and sync with Linux David Lechner
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=20261107142441.2104669-3-csharper2005@gmail.com \
--to=csharper2005@gmail.com \
--cc=GSS_MTK_Uboot_upstream@mediatek.com \
--cc=chunfeng.yun@mediatek.com \
--cc=dlechner@baylibre.com \
--cc=igor.belwon@mentallysanemainliners.org \
--cc=jerome.forissier@arm.com \
--cc=jstephan@baylibre.com \
--cc=ryder.lee@mediatek.com \
--cc=trini@konsulko.com \
--cc=u-boot@lists.u-boot-project.org \
--cc=weijie.gao@mediatek.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.