]> git.baikalelectronics.ru Git - kernel.git/commit
net/tls: don't arm strparser immediately in tls_set_sw_offload()
authorJakub Kicinski <jakub.kicinski@netronome.com>
Fri, 19 Jul 2019 17:29:14 +0000 (10:29 -0700)
committerDaniel Borkmann <daniel@iogearbox.net>
Mon, 22 Jul 2019 14:04:16 +0000 (16:04 +0200)
commit31dfacc44caeeef72db79f25d130093656c4b0b1
treea16b6ee38d52cdfd8fff38bc9f703290b96c2f59
parent35f6b545c584581977c076b0a63808fe49746e59
net/tls: don't arm strparser immediately in tls_set_sw_offload()

In tls_set_device_offload_rx() we prepare the software context
for RX fallback and proceed to add the connection to the device.
Unfortunately, software context prep includes arming strparser
so in case of a later error we have to release the socket lock
to call strp_done().

In preparation for not releasing the socket lock half way through
callbacks move arming strparser into a separate function.
Following patches will make use of that.

Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com>
Reviewed-by: Dirk van der Merwe <dirk.vandermerwe@netronome.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
include/net/tls.h
net/tls/tls_device.c
net/tls/tls_main.c
net/tls/tls_sw.c