On 23 December 2016 at 11:41, Martin Pieuchot <[email protected]> wrote: > On 23/12/16(Fri) 06:08, Visa Hankala wrote: >> NET_LOCK() should raise IPL before acquiring the lock, and NET_UNLOCK() >> should restore the level after releasing the lock. Otherwise, lock >> recursion can occur, most likely right after the splx(). An example: >> >> nd6_slowtimo <- NET_LOCK() >> timeout_run >> softclock >> softintr_dispatch >> dosoftint >> interrupt >> k_intr >> if_netisr <- NET_LOCK() >> taskq_thread >> >> OK? > > This should never happen. Simply because the NET_LOCK() MUST NOT be > taken in (soft) interrupt context. > > The real problem is that nd6_slowtimo() is set twice, once with > timeout_set_proc(9) and once with timeout_set(9). Diff below fixes > that. > > ok? >
Most definitely.
