projects
/
linux-2.6-microblaze.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
06ea2c9
)
iavf: Fix a locking bug in an error path
author
Bart Van Assche
<bvanassche@acm.org>
Thu, 6 Feb 2025 17:51:08 +0000
(09:51 -0800)
committer
Jakub Kicinski
<kuba@kernel.org>
Wed, 12 Feb 2025 02:02:04 +0000
(18:02 -0800)
If the netdev lock has been obtained, unlock it before returning.
This bug has been detected by the Clang thread-safety analyzer.
Fixes:
afc664987ab3
("eth: iavf: extend the netdev_lock usage")
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
Link:
https://patch.msgid.link/20250206175114.1974171-28-bvanassche@acm.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/intel/iavf/iavf_main.c
patch
|
blob
|
history
diff --git
a/drivers/net/ethernet/intel/iavf/iavf_main.c
b/drivers/net/ethernet/intel/iavf/iavf_main.c
index
2d7a18f
..
852e5b6
100644
(file)
--- a/
drivers/net/ethernet/intel/iavf/iavf_main.c
+++ b/
drivers/net/ethernet/intel/iavf/iavf_main.c
@@
-2903,8
+2903,8
@@
static void iavf_watchdog_task(struct work_struct *work)
}
mutex_unlock(&adapter->crit_lock);
- netdev_unlock(netdev);
restart_watchdog:
+ netdev_unlock(netdev);
if (adapter->state >= __IAVF_DOWN)
queue_work(adapter->wq, &adapter->adminq_task);
if (adapter->aq_required)