public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH net-next V2] docs: tls: Enhance TLS resync async process documentation
@ 2026-01-13 10:08 Tariq Toukan
  2026-01-16 13:35 ` Simon Horman
  2026-01-19 14:19 ` patchwork-bot+netdevbpf
  0 siblings, 2 replies; 3+ messages in thread
From: Tariq Toukan @ 2026-01-13 10:08 UTC (permalink / raw)
  To: Eric Dumazet, Jakub Kicinski, Paolo Abeni, Andrew Lunn,
	David S. Miller
  Cc: Jonathan Corbet, netdev, linux-doc, linux-kernel, Mark Bloch,
	Gal Pressman, Bagas Sanjaya, Sabrina Dubroca, Shahar Shitrit,
	Tariq Toukan

From: Shahar Shitrit <shshitrit@nvidia.com>

Expand the tls-offload.rst documentation to provide a more detailed
explanation of the asynchronous resync process, including the role
of struct tls_offload_resync_async in managing resync requests on
the kernel side.

Also, add documentation for helper functions
tls_offload_rx_resync_async_request_start/ _end/ _cancel.

Signed-off-by: Shahar Shitrit <shshitrit@nvidia.com>
Signed-off-by: Tariq Toukan <tariqt@nvidia.com>
---
 Documentation/networking/tls-offload.rst | 30 ++++++++++++++++++++++++
 1 file changed, 30 insertions(+)

V2:
- Fix style issues.

diff --git a/Documentation/networking/tls-offload.rst b/Documentation/networking/tls-offload.rst
index 7354d48cdf92..42800d86d269 100644
--- a/Documentation/networking/tls-offload.rst
+++ b/Documentation/networking/tls-offload.rst
@@ -318,6 +318,36 @@ is restarted.
 When the header is matched the device sends a confirmation request
 to the kernel, asking if the guessed location is correct (if a TLS record
 really starts there), and which record sequence number the given header had.
+
+The asynchronous resync process is coordinated on the kernel side using
+struct tls_offload_resync_async, which tracks and manages the resync request.
+
+Helper functions to manage struct tls_offload_resync_async:
+
+``tls_offload_rx_resync_async_request_start()``
+Initializes an asynchronous resync attempt by specifying the sequence range to
+monitor and resetting internal state in the struct.
+
+``tls_offload_rx_resync_async_request_end()``
+Retains the device's guessed TCP sequence number for comparison with current or
+future logged ones. It also clears the RESYNC_REQ_ASYNC flag from the resync
+request, indicating that the device has submitted its guessed sequence number.
+
+``tls_offload_rx_resync_async_request_cancel()``
+Cancels any in-progress resync attempt, clearing the request state.
+
+When the kernel processes an RX segment that begins a new TLS record, it
+examines the current status of the asynchronous resynchronization request.
+
+If the device is still waiting to provide its guessed TCP sequence number
+(the async state), the kernel records the sequence number of this segment so
+that it can later be compared once the device's guess becomes available.
+
+If the device has already submitted its guessed sequence number (the non-async
+state), the kernel now tries to match that guess against the sequence numbers of
+all TLS record headers that have been logged since the resync request
+started.
+
 The kernel confirms the guessed location was correct and tells the device
 the record sequence number. Meanwhile, the device had been parsing
 and counting all records since the just-confirmed one, it adds the number

base-commit: cbe8e6bef6a3b4b895b47ea56f5952f1936aacb6
-- 
2.31.1


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH net-next V2] docs: tls: Enhance TLS resync async process documentation
  2026-01-13 10:08 [PATCH net-next V2] docs: tls: Enhance TLS resync async process documentation Tariq Toukan
@ 2026-01-16 13:35 ` Simon Horman
  2026-01-19 14:19 ` patchwork-bot+netdevbpf
  1 sibling, 0 replies; 3+ messages in thread
From: Simon Horman @ 2026-01-16 13:35 UTC (permalink / raw)
  To: Tariq Toukan
  Cc: Eric Dumazet, Jakub Kicinski, Paolo Abeni, Andrew Lunn,
	David S. Miller, Jonathan Corbet, netdev, linux-doc, linux-kernel,
	Mark Bloch, Gal Pressman, Bagas Sanjaya, Sabrina Dubroca,
	Shahar Shitrit

On Tue, Jan 13, 2026 at 12:08:03PM +0200, Tariq Toukan wrote:
> From: Shahar Shitrit <shshitrit@nvidia.com>
> 
> Expand the tls-offload.rst documentation to provide a more detailed
> explanation of the asynchronous resync process, including the role
> of struct tls_offload_resync_async in managing resync requests on
> the kernel side.
> 
> Also, add documentation for helper functions
> tls_offload_rx_resync_async_request_start/ _end/ _cancel.
> 
> Signed-off-by: Shahar Shitrit <shshitrit@nvidia.com>
> Signed-off-by: Tariq Toukan <tariqt@nvidia.com>
> ---
>  Documentation/networking/tls-offload.rst | 30 ++++++++++++++++++++++++
>  1 file changed, 30 insertions(+)
> 
> V2:
> - Fix style issues.

Thanks for the update.

Reviewed-by: Simon Horman <horms@kernel.org>

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH net-next V2] docs: tls: Enhance TLS resync async process documentation
  2026-01-13 10:08 [PATCH net-next V2] docs: tls: Enhance TLS resync async process documentation Tariq Toukan
  2026-01-16 13:35 ` Simon Horman
@ 2026-01-19 14:19 ` patchwork-bot+netdevbpf
  1 sibling, 0 replies; 3+ messages in thread
From: patchwork-bot+netdevbpf @ 2026-01-19 14:19 UTC (permalink / raw)
  To: Tariq Toukan
  Cc: edumazet, kuba, pabeni, andrew+netdev, davem, corbet, netdev,
	linux-doc, linux-kernel, mbloch, gal, bagasdotme, sd, shshitrit

Hello:

This patch was applied to netdev/net-next.git (main)
by Jakub Kicinski <kuba@kernel.org>:

On Tue, 13 Jan 2026 12:08:03 +0200 you wrote:
> From: Shahar Shitrit <shshitrit@nvidia.com>
> 
> Expand the tls-offload.rst documentation to provide a more detailed
> explanation of the asynchronous resync process, including the role
> of struct tls_offload_resync_async in managing resync requests on
> the kernel side.
> 
> [...]

Here is the summary with links:
  - [net-next,V2] docs: tls: Enhance TLS resync async process documentation
    https://git.kernel.org/netdev/net-next/c/8fc807104125

You are awesome, thank you!
-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2026-01-19 14:23 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-01-13 10:08 [PATCH net-next V2] docs: tls: Enhance TLS resync async process documentation Tariq Toukan
2026-01-16 13:35 ` Simon Horman
2026-01-19 14:19 ` patchwork-bot+netdevbpf

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox