Re: [PATCH net 5/9] net/tls: Consume empty data records in tls_sw_recvmsg()

Jakub Kicinski <[email protected]> Mon, 3 Aug 2026 15:47:07 -0700
Newsgroups org.kernel.vger.linux-kselftest,org.kernel.vger.netdev
Message-ID <[email protected]>
On Sun, 26 Jul 2026 20:33:33 -0400 Chuck Lever wrote:
> -		/* Do not use async mode if record is non-data */
> +		/* Do not use async mode if record is non-data, or if it
> +		 * is empty: the receive loop frees an empty record's skb,
> +		 * so its decryption must have completed.
> +		 */
>  		if (tlm->control == TLS_RECORD_TYPE_DATA)
> -			darg.async = ctx->async_capable;
> +			darg.async = ctx->async_capable && to_decrypt;

I vaguely recall that we depend on all records being async
uniformly within a single recvmsg call