diff options
author | Jakub Kicinski | 2021-10-28 10:43:58 -0700 |
---|---|---|
committer | Jakub Kicinski | 2021-10-28 10:43:58 -0700 |
commit | 7df621a3eea6761bc83e641aaca6963210c7290d (patch) | |
tree | 65ab9d0d1894153ceefcb6b5a1c25b8d17c466fd /include/net/tls.h | |
parent | f2edaa4ad5d51371709196f2c258fbe875962dee (diff) | |
parent | 411a44c24a561e449b592ff631b7ae321f1eb559 (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net
include/net/sock.h
7b50ecfcc6cd ("net: Rename ->stream_memory_read to ->sock_is_readable")
4c1e34c0dbff ("vsock: Enable y2038 safe timeval for timeout")
drivers/net/ethernet/marvell/octeontx2/af/rvu_debugfs.c
0daa55d033b0 ("octeontx2-af: cn10k: debugfs for dumping LMTST map table")
e77bcdd1f639 ("octeontx2-af: Display all enabled PF VF rsrc_alloc entries.")
Adjacent code addition in both cases, keep both.
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'include/net/tls.h')
-rw-r--r-- | include/net/tls.h | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/include/net/tls.h b/include/net/tls.h index adab19a8aed7..526cb2c3b724 100644 --- a/include/net/tls.h +++ b/include/net/tls.h @@ -361,6 +361,7 @@ int tls_sk_query(struct sock *sk, int optname, char __user *optval, int __user *optlen); int tls_sk_attach(struct sock *sk, int optname, char __user *optval, unsigned int optlen); +void tls_err_abort(struct sock *sk, int err); int tls_set_sw_offload(struct sock *sk, struct tls_context *ctx, int tx); void tls_sw_strparser_arm(struct sock *sk, struct tls_context *ctx); @@ -378,7 +379,7 @@ void tls_sw_release_resources_rx(struct sock *sk); void tls_sw_free_ctx_rx(struct tls_context *tls_ctx); int tls_sw_recvmsg(struct sock *sk, struct msghdr *msg, size_t len, int nonblock, int flags, int *addr_len); -bool tls_sw_stream_read(const struct sock *sk); +bool tls_sw_sock_is_readable(struct sock *sk); ssize_t tls_sw_splice_read(struct socket *sock, loff_t *ppos, struct pipe_inode_info *pipe, size_t len, unsigned int flags); @@ -469,12 +470,6 @@ static inline bool tls_is_sk_tx_device_offloaded(struct sock *sk) #endif } -static inline void tls_err_abort(struct sock *sk, int err) -{ - sk->sk_err = err; - sk_error_report(sk); -} - static inline bool tls_bigint_increment(unsigned char *seq, int len) { int i; @@ -515,7 +510,7 @@ static inline void tls_advance_record_sn(struct sock *sk, struct cipher_context *ctx) { if (tls_bigint_increment(ctx->rec_seq, prot->rec_seq_size)) - tls_err_abort(sk, EBADMSG); + tls_err_abort(sk, -EBADMSG); if (prot->version != TLS_1_3_VERSION && prot->cipher_type != TLS_CIPHER_CHACHA20_POLY1305) |