diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2025-05-20 20:10:01 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2025-05-20 20:10:01 -0700 |
commit | 5da472ae1f128840b27795fa461b47a85d882ce2 (patch) | |
tree | a13ac3017b13399e4296f82d2240a93df304a154 /kernel/padata.c | |
parent | b36ddb9210e6812eb1c86ad46b66cc46aa193487 (diff) | |
parent | b2df03ed4052e97126267e8c13ad4204ea6ba9b6 (diff) |
Merge tag 'v6.15-p7' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6
Pull crypto fixes from Herbert Xu:
"This fixes a regression in padata as well as an ancient double-free
bug in af_alg"
* tag 'v6.15-p7' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6:
crypto: algif_hash - fix double free in hash_accept
padata: do not leak refcount in reorder_work
Diffstat (limited to 'kernel/padata.c')
-rw-r--r-- | kernel/padata.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/kernel/padata.c b/kernel/padata.c index b3d4eacc4f5d..7eee94166357 100644 --- a/kernel/padata.c +++ b/kernel/padata.c @@ -358,7 +358,8 @@ static void padata_reorder(struct parallel_data *pd) * To avoid UAF issue, add pd ref here, and put pd ref after reorder_work finish. */ padata_get_pd(pd); - queue_work(pinst->serial_wq, &pd->reorder_work); + if (!queue_work(pinst->serial_wq, &pd->reorder_work)) + padata_put_pd(pd); } } |