This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug kprobes/3541] unsafe printk calls in hand-coded kprobe handlers


------- Additional Comments From jkenisto at us dot ibm dot com  2006-11-22 00:05 -------
Since kprobes doesn't allow handlers to re-enter, the likely deadlock scenario
is anybody -> printk -> release_console_sem [locks logbuf_lock] -> up -> ... ->
try_to_wake_up -> activate_task -> handler -> printk [goes for logbuf_lock again].

Re: (2b), spin_trylock_irqsave() (which is what we want) can fail in perfectly
benign scenarios.  If it does, it's a deadlock only if printk_cpu ==
smp_processor_id().  Otherwise, just go for the lock again with spinlock_irq_save().

-- 


http://sourceware.org/bugzilla/show_bug.cgi?id=3541

------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]