On 30.5.2017. 11:48, Martin Pieuchot wrote: > On 30/05/17(Tue) 10:45, Martin Pieuchot wrote: >> Diff below moves IPv4 & IPv6 incoming/forwarding path, PIPEX ppp >> processing and IPv4 & IPv6 dispatch functions outside the KERNEL_LOCK(). >> >> We currently rely on the NET_LOCK() serializing access to most global >> data structures for that. IP input queues are no longer used in the >> forwarding case. They still exist as boundary between the network and >> transport layers because TCP/UDP & friends still need the KERNEL_LOCK(). >> >> Since we do not want to grab the NET_LOCK() for every packet, the >> softnet thread will do it once before processing a batch. That means >> the L2 processing path, which is currently running without lock, will >> now run with the NET_LOCK(). >> >> IPsec is the bridge of this layer. A bad player. Since IPsec isn't >> ready to run without KERNEL_LOCK(), the softnet thread will grab the >> KERNEL_LOCK() as soon as ``ipsec_in_use'' is set. >> >> I tried to document as much as possible the current design in my >> commit messages and in the comment below. Please ask if something >> isn't clear. > Hrvoje Popovski found that ip{,6}_send_dispatch() also need the IPsec > dance. > > Updated diff below.
i'm confirming that i can't reproduce panic with this diff ...