Commit 85672ca
block: avoid to reuse
If the 'hctx' isn't removed from cpuhp callback list, we can't reuse it,
otherwise use-after-free may be triggered.
Reported-by: kernel test robot <oliver.sang@intel.com>
Closes: https://lore.kernel.org/oe-lkp/202412172217.b906db7c-lkp@intel.com
Tested-by: kernel test robot <oliver.sang@intel.com>
Fixes: 22465bb ("blk-mq: move cpuhp callback registering out of q->sysfs_lock")
Signed-off-by: Ming Lei <ming.lei@redhat.com>
Link: https://lore.kernel.org/r/20241218101617.3275704-3-ming.lei@redhat.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>hctx not removed from cpuhp callback list1 parent 224749b commit 85672ca
1 file changed
Lines changed: 10 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4412 | 4412 | | |
4413 | 4413 | | |
4414 | 4414 | | |
| 4415 | + | |
| 4416 | + | |
| 4417 | + | |
| 4418 | + | |
| 4419 | + | |
| 4420 | + | |
| 4421 | + | |
| 4422 | + | |
| 4423 | + | |
4415 | 4424 | | |
4416 | 4425 | | |
4417 | 4426 | | |
| |||
4421 | 4430 | | |
4422 | 4431 | | |
4423 | 4432 | | |
4424 | | - | |
| 4433 | + | |
4425 | 4434 | | |
4426 | 4435 | | |
4427 | 4436 | | |
| |||
0 commit comments