summaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authorOleg Nesterov <oleg@tv-sign.ru>2005-10-23 20:25:39 +0400
committerLinus Torvalds <torvalds@g5.osdl.org>2005-10-24 08:12:35 -0700
commit108150ea78003044e41150c75259447b2c0953b6 (patch)
treeffe0b7e59e6ca1c8a4dad18110e485e5c72872bc /net
parentba9e358fd04190a59e605c2963a15e014139a707 (diff)
downloadop-kernel-dev-108150ea78003044e41150c75259447b2c0953b6.zip
op-kernel-dev-108150ea78003044e41150c75259447b2c0953b6.tar.gz
[PATCH] posix-timers: fix cleanup_timers() and run_posix_cpu_timers() races
1. cleanup_timers() sets timer->task = NULL under tasklist + ->sighand locks. That means that this code in posix_cpu_timer_del() and posix_cpu_timer_set() lock_timer(timer); if (timer->task == NULL) return; read_lock(tasklist); put_task_struct(timer->task) is racy. With this patch timer->task modified and accounted only under timer->it_lock. Sadly, this means that dead task_struct won't be freed until timer deleted or armed. 2. run_posix_cpu_timers() collects expired timers into local list under tasklist + ->sighand again. That means that posix_cpu_timer_del() should check timer->it.cpu.firing under these locks too. Signed-off-by: Oleg Nesterov <oleg@tv-sign.ru> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'net')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud