mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/
synced 2026-10-14 05:55:17 +00:00
DAMON debugfs interface iterates current monitoring targets in
'dbgfs_target_ids_read()' while holding the corresponding
'kdamond_lock'. However, it also destructs the monitoring targets in
'dbgfs_before_terminate()' without holding the lock. This can result in
a use_after_free bug. This commit avoids the race by protecting the
destruction with the corresponding 'kdamond_lock'.
Link: https://lkml.kernel.org/r/20211221094447.2241-1-sj@kernel.org
Reported-by: Sangwoo Bae <sangwoob@amazon.com>
Fixes:
|
History
|
|
|---|---|---|
| .. | ||
| core-test.h | ||
| core.c | ||
| dbgfs-test.h | ||
| dbgfs.c | ||
| Kconfig | ||
| Makefile | ||
| paddr.c | ||
| prmtv-common.c | ||
| prmtv-common.h | ||
| reclaim.c | ||
| vaddr-test.h | ||
| vaddr.c | ||