Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
net: xfrm: fix compress vs decompress serialization
A crash was seen in xfrm when running ltp's 'tcp4_ipsec06' stresser on v4.x based RT kernels. ipcomp_compress() will serialize access to the ipcomp_scratches percpu buffer by disabling BH and preventing a softirq from coming in and running ipcom_decompress(), which is never called from process context. This of course won't work on RT and the buffer can get corrupted; there have been similar issues with in the past with such assumptions, ie: ebf255ed6c44 (net: add back the missing serialization in ip_send_unicast_reply()). Similarly, this patch addresses the issue with locallocks allowing RT to have a percpu spinlock and do the correct serialization. Signed-off-by: Davidlohr Bueso <dbueso@suse.de> Signed-off-by: Tom Zanussi <zanussi@kernel.org>
- Loading branch information