• Paul E. McKenney's avatar
    [PATCH] Make RCU task_struct safe for oprofile · 4369ef3c
    Paul E. McKenney authored
    Applying RCU to the task structure broke oprofile, because
    free_task_notify() can now be called from softirq.  This means that the
    task_mortuary lock must be acquired with irq disabled in order to avoid
    intermittent self-deadlock.  Since irq is now disabled, the critical
    section within process_task_mortuary() has been restructured to be O(1) in
    order to maximize scalability and minimize realtime latency degradation.
    
    Kudos to Wu Fengguang for finding this problem!
    
    CC: Wu Fengguang <wfg@mail.ustc.edu.cn>
    Cc: Philippe Elie <phil.el@wanadoo.fr>
    Cc: John Levon <levon@movementarian.org>
    Signed-off-by: default avatar"Paul E. McKenney" <paulmck@us.ibm.com>
    Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
    Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
    4369ef3c
buffer_sync.c 12.7 KB