net/tls: rename handle_device_resync()
authorJakub Kicinski <jakub.kicinski@netronome.com>
Tue, 11 Jun 2019 04:40:01 +0000 (21:40 -0700)
committerDavid S. Miller <davem@davemloft.net>
Tue, 11 Jun 2019 19:22:26 +0000 (12:22 -0700)
handle_device_resync() doesn't describe the function very well.
The function checks if resync should be issued upon parsing of
a new record.

Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com>
Reviewed-by: Dirk van der Merwe <dirk.vandermerwe@netronome.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/net/tls.h
net/tls/tls_device.c
net/tls/tls_sw.c

index 25641e2f5b967b6ee31d8eea3cf5212e75a1b7dc..1c512da5e4f43faf6cb2e535df3cb67455255f2c 100644 (file)
@@ -608,6 +608,6 @@ int tls_sw_fallback_init(struct sock *sk,
 int tls_set_device_offload_rx(struct sock *sk, struct tls_context *ctx);
 
 void tls_device_offload_cleanup_rx(struct sock *sk);
-void handle_device_resync(struct sock *sk, u32 seq);
+void tls_device_rx_resync_new_rec(struct sock *sk, u32 seq);
 
 #endif /* _TLS_OFFLOAD_H */
index 16635f0c829ce9c879fce5553aa04e07ceb27961..0ecfa0ee415d896bf10dde52f11b098727c1ef63 100644 (file)
@@ -563,7 +563,7 @@ static void tls_device_resync_rx(struct tls_context *tls_ctx,
        clear_bit_unlock(TLS_RX_SYNC_RUNNING, &tls_ctx->flags);
 }
 
-void handle_device_resync(struct sock *sk, u32 seq)
+void tls_device_rx_resync_new_rec(struct sock *sk, u32 seq)
 {
        struct tls_context *tls_ctx = tls_get_ctx(sk);
        struct tls_offload_context_rx *rx_ctx;
index c1d22290f1d0fb8c3a3056d98723468ba78e6f38..bc3a1b188d4a52dde7361bba645e6f5d48a1d5cb 100644 (file)
@@ -2015,7 +2015,8 @@ static int tls_read_size(struct strparser *strp, struct sk_buff *skb)
                goto read_failure;
        }
 #ifdef CONFIG_TLS_DEVICE
-       handle_device_resync(strp->sk, TCP_SKB_CB(skb)->seq + rxm->offset);
+       tls_device_rx_resync_new_rec(strp->sk,
+                                    TCP_SKB_CB(skb)->seq + rxm->offset);
 #endif
        return data_len + TLS_HEADER_SIZE;