lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20260123090741.1566469-3-o.rempel@pengutronix.de>
Date: Fri, 23 Jan 2026 10:07:38 +0100
From: Oleksij Rempel <o.rempel@...gutronix.de>
To: "David S. Miller" <davem@...emloft.net>,
	Eric Dumazet <edumazet@...gle.com>,
	Jakub Kicinski <kuba@...nel.org>,
	Paolo Abeni <pabeni@...hat.com>,
	Andrew Lunn <andrew+netdev@...n.ch>,
	Thangaraj Samynathan <Thangaraj.S@...rochip.com>,
	Rengarajan Sundararajan <Rengarajan.S@...rochip.com>
Cc: Oleksij Rempel <o.rempel@...gutronix.de>,
	kernel@...gutronix.de,
	linux-kernel@...r.kernel.org,
	netdev@...r.kernel.org,
	UNGLinuxDriver@...rochip.com
Subject: [RFC PATCH 2/4] net: lan78xx: Implement FIFO stall recovery via lite reset

Implement the recovery logic for the devlink FIFO health reporter.

The recovery callback triggers a full hardware Lite Reset using
lan78xx_reset(). This is a fast, reliable way to restore traffic in
unattended embedded deployments when a FIFO stall is detected.

Signed-off-by: Oleksij Rempel <o.rempel@...gutronix.de>
---
 drivers/net/usb/lan78xx.c | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/drivers/net/usb/lan78xx.c b/drivers/net/usb/lan78xx.c
index 221be42e06f4..9dadca4101bc 100644
--- a/drivers/net/usb/lan78xx.c
+++ b/drivers/net/usb/lan78xx.c
@@ -4984,8 +4984,18 @@ static int lan78xx_internal_err_dump(struct devlink_health_reporter *reporter,
 				 ARRAY_SIZE(lan78xx_err_regs));
 }
 
+static int lan78xx_fifo_recover(struct devlink_health_reporter *reporter,
+				void *priv_ctx, struct netlink_ext_ack *extack)
+{
+	struct lan78xx_net *dev = devlink_health_reporter_priv(reporter);
+
+	netdev_warn(dev->net, "Recovering from FIFO stall via Lite Reset\n");
+	return lan78xx_reset(dev);
+}
+
 static const struct devlink_health_reporter_ops lan78xx_fifo_ops = {
 	.name = "fifo",
+	.recover = lan78xx_fifo_recover,
 	.dump = lan78xx_fifo_dump,
 };
 
-- 
2.47.3


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ