0
0
mirror of https://git.openwrt.org/openwrt/openwrt.git synced 2025-09-19 23:39:21 +00:00
Files
openwrt/target/linux/bcm27xx/patches-5.15/950-0500-net-phy-lan87xx-Allow-more-time-for-link-detect.patch
Shiji Yang 6dcf9882e4 kernel: bump 5.15 to 5.15.189
Changelog: https://cdn.kernel.org/pub/linux/kernel/v5.x/ChangeLog-5.15.189

Manually rebased patches:
  bcm27xx/patches-5.15/950-0600-xhci-quirks-add-link-TRB-quirk-for-VL805.patch[1]
  bcm27xx/patches-5.15/950-0606-usb-xhci-add-VLI_TRB_CACHE_BUG-quirk.patch[1]
  bcm27xx/patches-5.15/950-0717-usb-xhci-add-a-quirk-for-Superspeed-bulk-OUT-transfe.patch[1]
  bcm53xx/patches-5.15/180-usb-xhci-add-support-for-performing-fake-doorbell.patch[1]

All other patches are automatically refreshed.

[1] https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.15.189&id=e262ff8d634cf6e0028fb7b3643cdd8b758513be

Signed-off-by: Shiji Yang <yangshiji66@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/19466
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2025-07-21 23:04:05 +02:00

39 lines
1.3 KiB
Diff

From eb860f6a2dee9a4c94a7101c1d43194b95fdbc8d Mon Sep 17 00:00:00 2001
From: Phil Elwell <phil@raspberrypi.com>
Date: Wed, 22 Sep 2021 15:38:13 +0100
Subject: [PATCH] net: phy: lan87xx: Allow more time for link detect
With EDPWRDOWN set in idle, it must be cleared before checking for
ENERGYON going high, indicating that a link is being established.
The existing code allows 640ms for ENERGYON to go high, but on
Raspberry Pis that appears not to be enough, causing link detection
to fail.
Increase the polling timeout to 1500ms - with a polling interval of
10ms it shouldn't cause unnecessary delays.
See: https://github.com/raspberrypi/linux/issues/4393
Signed-off-by: Phil Elwell <phil@raspberrypi.com>
---
drivers/net/phy/smsc.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
--- a/drivers/net/phy/smsc.c
+++ b/drivers/net/phy/smsc.c
@@ -243,12 +243,12 @@ static int lan87xx_read_status(struct ph
if (rc < 0)
return rc;
- /* Wait max 640 ms to detect energy and the timeout is not
+ /* Wait max 1500 ms to detect energy and the timeout is not
* an actual error.
*/
read_poll_timeout(phy_read, rc,
rc & MII_LAN83C185_ENERGYON || rc < 0,
- 10000, 640000, true, phydev,
+ 10000, 1500000, true, phydev,
MII_LAN83C185_CTRL_STATUS);
if (rc < 0)
return rc;