diff options
| author | Leon Yen <leon.yen@mediatek.com> | 2025-12-15 20:22:31 +0800 |
|---|---|---|
| committer | Felix Fietkau <nbd@nbd.name> | 2026-03-23 09:21:25 +0000 |
| commit | bb2f07819d063a58756186cac6465341956ac0a4 (patch) | |
| tree | 0129768fb88574b6f2d76b01eb0b529ae65a1176 /tools/perf/scripts/python/bin | |
| parent | 1695f662329faa07c860c73453c097823852df28 (diff) | |
wifi: mt76: mt792x: Fix a potential deadlock in high-load situations
A deadlock may occur between two works, ps_work and mac_work, if their work
functions run simultaneously as they attempt to cancel each other by
calling cancel_delayed_work_sync().
mt792x_mac_work() -> ... -> cancel_delayed_work_sync(&pm->ps_work);
mt792x_pm_power_save_work() -> cancel_delayed_work_sync(&mphy->mac_work);
In high-load situations, they are queued but may not have chance to be
executed until the CPUs are released. Once the CPUs are available, there
is a high possibility that the ps_work function and mac_work function will
be executed simultaneously, resulting in a possible deadlock.
This patch replaces cancel_delayed_work_sync() with cancel_delayed_work()
in ps_work to eliminate the deadlock and make the code easier to maintain.
Signed-off-by: Leon Yen <leon.yen@mediatek.com>
Tested-by: Chia-Lin Kao (AceLan) <acelan.kao@canonical.com>
Link: https://patch.msgid.link/20251215122231.3180648-1-leon.yen@mediatek.com
Signed-off-by: Felix Fietkau <nbd@nbd.name>
Diffstat (limited to 'tools/perf/scripts/python/bin')
0 files changed, 0 insertions, 0 deletions
