diff options
author | John Baldwin <jhb@FreeBSD.org> | 2022-04-22 22:52:12 +0000 |
---|---|---|
committer | John Baldwin <jhb@FreeBSD.org> | 2022-04-22 22:52:12 +0000 |
commit | a4c5d490f6be56468b2a088a5f6169846e39bd84 (patch) | |
tree | 7276fae446661166ccaedbd62e9e372350dabc47 /sys/opencrypto/ktls.h | |
parent | f2d166d5322e557ff1388a5419ed694187fc1dbc (diff) |
KTLS: Move OCF function pointers out of ktls_session.
Instead, create a switch structure private to ktls_ocf.c and store a
pointer to the switch in the ocf_session. This will permit adding an
additional function pointer needed for NIC TLS RX without further
bloating ktls_session.
Reviewed by: hselasky
Sponsored by: Netflix
Differential Revision: https://reviews.freebsd.org/D35011
Diffstat (limited to 'sys/opencrypto/ktls.h')
-rw-r--r-- | sys/opencrypto/ktls.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/sys/opencrypto/ktls.h b/sys/opencrypto/ktls.h index 9eb01c9b02a5..b97f589fecb4 100644 --- a/sys/opencrypto/ktls.h +++ b/sys/opencrypto/ktls.h @@ -49,5 +49,11 @@ struct ktls_ocf_encrypt_state { void ktls_encrypt_cb(struct ktls_ocf_encrypt_state *state, int error); void ktls_ocf_free(struct ktls_session *tls); int ktls_ocf_try(struct socket *so, struct ktls_session *tls, int direction); +int ktls_ocf_encrypt(struct ktls_ocf_encrypt_state *state, + struct ktls_session *tls, struct mbuf *m, struct iovec *outiov, + int outiovcnt); +int ktls_ocf_decrypt(struct ktls_session *tls, + const struct tls_record_layer *hdr, struct mbuf *m, uint64_t seqno, + int *trailer_len); #endif /* !__OPENCRYPTO_KTLS_H__ */ |