mirror of
https://github.com/torvalds/linux.git
synced 2026-05-12 16:18:45 +02:00
Merge branch 'rxrpc-miscellaneous-fixes'
David Howells says:
====================
rxrpc: Miscellaneous fixes
Here are some fixes for rxrpc, as found by Sashiko[1]:
(1) Fix rxrpc_input_call_event() to only unshare DATA packets.
(2) Fix re-decryption of RESPONSE packets where a partially decrypted
skbuff gets requeued if there was a failure due to ENOMEM.
(3) Fix error handling in rxgk_extract_token() where the ENOMEM case is
unhandled.
Link: https://sashiko.dev/#/patchset/20260422161438.2593376-4-dhowells@redhat.com [1]
====================
Link: https://patch.msgid.link/20260423200909.3049438-1-dhowells@redhat.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
commit
5e6391da45
|
|
@ -285,7 +285,6 @@
|
|||
EM(rxrpc_conn_put_unidle, "PUT unidle ") \
|
||||
EM(rxrpc_conn_put_work, "PUT work ") \
|
||||
EM(rxrpc_conn_queue_challenge, "QUE chall ") \
|
||||
EM(rxrpc_conn_queue_retry_work, "QUE retry-wk") \
|
||||
EM(rxrpc_conn_queue_rx_work, "QUE rx-work ") \
|
||||
EM(rxrpc_conn_see_new_service_conn, "SEE new-svc ") \
|
||||
EM(rxrpc_conn_see_reap_service, "SEE reap-svc") \
|
||||
|
|
|
|||
|
|
@ -332,7 +332,8 @@ bool rxrpc_input_call_event(struct rxrpc_call *call)
|
|||
|
||||
saw_ack |= sp->hdr.type == RXRPC_PACKET_TYPE_ACK;
|
||||
|
||||
if (sp->hdr.securityIndex != 0 &&
|
||||
if (sp->hdr.type == RXRPC_PACKET_TYPE_DATA &&
|
||||
sp->hdr.securityIndex != 0 &&
|
||||
skb_cloned(skb)) {
|
||||
/* Unshare the packet so that it can be
|
||||
* modified by in-place decryption.
|
||||
|
|
|
|||
|
|
@ -389,7 +389,6 @@ void rxrpc_process_delayed_final_acks(struct rxrpc_connection *conn, bool force)
|
|||
static void rxrpc_do_process_connection(struct rxrpc_connection *conn)
|
||||
{
|
||||
struct sk_buff *skb;
|
||||
int ret;
|
||||
|
||||
if (test_and_clear_bit(RXRPC_CONN_EV_CHALLENGE, &conn->events))
|
||||
rxrpc_secure_connection(conn);
|
||||
|
|
@ -398,17 +397,8 @@ static void rxrpc_do_process_connection(struct rxrpc_connection *conn)
|
|||
* connection that each one has when we've finished with it */
|
||||
while ((skb = skb_dequeue(&conn->rx_queue))) {
|
||||
rxrpc_see_skb(skb, rxrpc_skb_see_conn_work);
|
||||
ret = rxrpc_process_event(conn, skb);
|
||||
switch (ret) {
|
||||
case -ENOMEM:
|
||||
case -EAGAIN:
|
||||
skb_queue_head(&conn->rx_queue, skb);
|
||||
rxrpc_queue_conn(conn, rxrpc_conn_queue_retry_work);
|
||||
break;
|
||||
default:
|
||||
rxrpc_free_skb(skb, rxrpc_skb_put_conn_work);
|
||||
break;
|
||||
}
|
||||
rxrpc_process_event(conn, skb);
|
||||
rxrpc_free_skb(skb, rxrpc_skb_put_conn_work);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -245,6 +245,7 @@ int rxgk_extract_token(struct rxrpc_connection *conn, struct sk_buff *skb,
|
|||
if (ret != -ENOMEM)
|
||||
return rxrpc_abort_conn(conn, skb, ec, ret,
|
||||
rxgk_abort_resp_tok_dec);
|
||||
return ret;
|
||||
}
|
||||
|
||||
ret = conn->security->default_decode_ticket(conn, skb, ticket_offset,
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user