mirror of
https://git.openwrt.org/openwrt/openwrt.git
synced 2025-05-21 13:47:57 +00:00
Upstream e2015942e90a couldn't be backported to 6.6 because the following symbols were missing: - disable_work - disable_work_sync - enable_work Seee2015942e9
Upstream 34e5ededf4b8 couldn't be backported to 6.6 because the following symbol was missing: - pcim_iomap_region See34e5ededf4
Reorganize patch numbers now that < 6.12 patches are no longer needed. The following patches still differ from upstream: - e340bff27e63 phy_set_eee_broken symbol is missing in 6.12 https://github.com/torvalds/linux/commit/e340bff27e63 The following patches can't be backported to 6.12 due to missing symbols: - 5e7a74b6a357 phy_disable_eee_mode symbol is missing in 6.12 https://github.com/torvalds/linux/commit/5e7a74b6a357 Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
51 lines
1.7 KiB
Diff
51 lines
1.7 KiB
Diff
From ac48430368c1a4f4e6c2fa92243b4b93fd25bee4 Mon Sep 17 00:00:00 2001
|
|
From: Heiner Kallweit <hkallweit1@gmail.com>
|
|
Date: Wed, 16 Oct 2024 22:05:57 +0200
|
|
Subject: [PATCH] r8169: don't take RTNL lock in rtl_task()
|
|
|
|
There's not really a benefit here in taking the RTNL lock. The task
|
|
handler does exception handling only, so we're in trouble anyway when
|
|
we come here, and there's no need to protect against e.g. a parallel
|
|
ethtool call.
|
|
A benefit of removing the RTNL lock here is that we now can
|
|
synchronously cancel the workqueue from a context holding the RTNL mutex.
|
|
|
|
Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
|
|
Signed-off-by: Andrew Lunn <andrew@lunn.ch>
|
|
---
|
|
drivers/net/ethernet/realtek/r8169_main.c | 8 ++------
|
|
1 file changed, 2 insertions(+), 6 deletions(-)
|
|
|
|
--- a/drivers/net/ethernet/realtek/r8169_main.c
|
|
+++ b/drivers/net/ethernet/realtek/r8169_main.c
|
|
@@ -4800,10 +4800,8 @@ static void rtl_task(struct work_struct
|
|
container_of(work, struct rtl8169_private, wk.work);
|
|
int ret;
|
|
|
|
- rtnl_lock();
|
|
-
|
|
if (!test_bit(RTL_FLAG_TASK_ENABLED, tp->wk.flags))
|
|
- goto out_unlock;
|
|
+ return;
|
|
|
|
if (test_and_clear_bit(RTL_FLAG_TASK_TX_TIMEOUT, tp->wk.flags)) {
|
|
/* if chip isn't accessible, reset bus to revive it */
|
|
@@ -4812,7 +4810,7 @@ static void rtl_task(struct work_struct
|
|
if (ret < 0) {
|
|
netdev_err(tp->dev, "Can't reset secondary PCI bus, detach NIC\n");
|
|
netif_device_detach(tp->dev);
|
|
- goto out_unlock;
|
|
+ return;
|
|
}
|
|
}
|
|
|
|
@@ -4831,8 +4829,6 @@ reset:
|
|
} else if (test_and_clear_bit(RTL_FLAG_TASK_RESET_NO_QUEUE_WAKE, tp->wk.flags)) {
|
|
rtl_reset_work(tp);
|
|
}
|
|
-out_unlock:
|
|
- rtnl_unlock();
|
|
}
|
|
|
|
static int rtl8169_poll(struct napi_struct *napi, int budget)
|