On 10/14/14 17:08, Lars Ellenberg wrote:
On Tue, Oct 14, 2014 at 03:27:56PM +0200, Matteo Tescione wrote:
Discussed this topic with Bart from SCST, he suggested:
"To me this looks like a DRBD bug. If a timeout of a DRBD request occurs
the DRBD timeout handler (request_timer_fn()) is called, that function
grabs a spinlock and next calls kthread_create_on_node() with that
spinlock held.

Well, no, our request_timer_fn does nothing like that.
At least it is not supposed to, and I don't see a code path
leading to anything like that.

Hello Lars,

Matteo reported that this occurred with DRBD version 8.4.4 (see also http://sourceforge.net/p/scst/mailman/message/32928699/). My conclusion from the stack trace posted by Matteo is that the call chain was as follows:
-> run_timer_softirq()
-> call_timer_fn
-> request_timer_fn()
-> _drbd_set_state()
-> __drbd_set_state()
-> _drbd_thread_stop() (locks the &thi->t_lock spinlock)
-> drbd_thread_start()
-> kthread_create_on_node()
-> wait_for_completion()

In other words, wait_for_completion() is not only called from soft-IRQ context but also with a spinlock held. Does this make sense to you ?

Thanks,

Bart.
_______________________________________________
drbd-user mailing list
drbd-user@lists.linbit.com
http://lists.linbit.com/mailman/listinfo/drbd-user

Reply via email to