From: David Howells <dhowells@redhat.com>
To: netdev@vger.kernel.org
Cc: Marc Dionne <marc.dionne@auristor.com>,
linux-afs@lists.infradead.org, dhowells@redhat.com,
linux-afs@lists.infradead.org, linux-kernel@vger.kernel.org
Subject: [PATCH net-next 03/13] rxrpc: Remove handling of duplicate packets in recvmsg_queue
Date: Wed, 23 Nov 2022 10:06:46 +0000 [thread overview]
Message-ID: <166919800599.1256245.15876799628241612501.stgit@warthog.procyon.org.uk> (raw)
In-Reply-To: <166919798040.1256245.11495568684139066955.stgit@warthog.procyon.org.uk>
We should not now see duplicate packets in the recvmsg_queue. At one
point, jumbo packets that overlapped with already queued data would be
added to the queue and dealt with in recvmsg rather than in the softirq
input code, but now jumbo packets are split/cloned before being processed
by the input code and the subpackets can be discarded individually.
So remove the recvmsg-side code for handling this.
Signed-off-by: David Howells <dhowells@redhat.com>
cc: Marc Dionne <marc.dionne@auristor.com>
cc: linux-afs@lists.infradead.org
---
net/rxrpc/recvmsg.c | 18 ------------------
1 file changed, 18 deletions(-)
diff --git a/net/rxrpc/recvmsg.c b/net/rxrpc/recvmsg.c
index efb85f983657..134122f5961a 100644
--- a/net/rxrpc/recvmsg.c
+++ b/net/rxrpc/recvmsg.c
@@ -228,7 +228,6 @@ static void rxrpc_rotate_rx_window(struct rxrpc_call *call)
_enter("%d", call->debug_id);
-further_rotation:
skb = skb_dequeue(&call->recvmsg_queue);
rxrpc_see_skb(skb, rxrpc_skb_rotated);
@@ -250,17 +249,6 @@ static void rxrpc_rotate_rx_window(struct rxrpc_call *call)
return;
}
- /* The next packet on the queue might entirely overlap with the one we
- * just consumed; if so, rotate that away also.
- */
- skb = skb_peek(&call->recvmsg_queue);
- if (skb) {
- sp = rxrpc_skb(skb);
- if (sp->hdr.seq != call->rx_consumed &&
- after_eq(call->rx_consumed, sp->hdr.seq))
- goto further_rotation;
- }
-
/* Check to see if there's an ACK that needs sending. */
acked = atomic_add_return(call->rx_consumed - old_consumed,
&call->ackr_nr_consumed);
@@ -318,11 +306,6 @@ static int rxrpc_recvmsg_data(struct socket *sock, struct rxrpc_call *call,
sp = rxrpc_skb(skb);
seq = sp->hdr.seq;
- if (after_eq(call->rx_consumed, seq)) {
- kdebug("obsolete %x %x", call->rx_consumed, seq);
- goto skip_obsolete;
- }
-
if (!(flags & MSG_PEEK))
trace_rxrpc_receive(call, rxrpc_receive_front,
sp->hdr.serial, seq);
@@ -373,7 +356,6 @@ static int rxrpc_recvmsg_data(struct socket *sock, struct rxrpc_call *call,
break;
}
- skip_obsolete:
/* The whole packet has been transferred. */
if (sp->hdr.flags & RXRPC_LAST_PACKET)
ret = 1;
next prev parent reply other threads:[~2022-11-23 10:21 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-11-23 10:06 [PATCH net-next 00/13] rxrpc: Increasing SACK size and moving away from softirq, part 2 David Howells
2022-11-23 10:06 ` [PATCH net-next 01/13] rxrpc: Implement an in-kernel rxperf server for testing purposes David Howells
2022-11-24 18:38 ` Marc Dionne
2022-11-23 10:06 ` [PATCH net-next 02/13] rxrpc: Remove decl for rxrpc_kernel_call_is_complete() David Howells
2022-11-23 10:06 ` David Howells [this message]
2022-11-23 10:06 ` [PATCH net-next 04/13] rxrpc: Remove the [k_]proto() debugging macros David Howells
2022-11-23 10:07 ` [PATCH net-next 05/13] rxrpc: Remove the [_k]net() " David Howells
2022-11-23 10:07 ` [PATCH net-next 06/13] rxrpc: Drop rxrpc_conn_parameters from rxrpc_connection and rxrpc_bundle David Howells
2022-11-23 10:07 ` [PATCH net-next 07/13] rxrpc: Extract the code from a received ABORT packet much earlier David Howells
2022-11-23 10:07 ` [PATCH net-next 08/13] rxrpc: trace: Don't use __builtin_return_address for rxrpc_local tracing David Howells
2022-11-23 10:07 ` [PATCH net-next 09/13] rxrpc: trace: Don't use __builtin_return_address for rxrpc_peer tracing David Howells
2022-11-23 10:07 ` [PATCH net-next 10/13] rxrpc: trace: Don't use __builtin_return_address for rxrpc_conn tracing David Howells
2022-11-23 10:07 ` [PATCH net-next 11/13] rxrpc: trace: Don't use __builtin_return_address for rxrpc_call tracing David Howells
2022-11-23 10:07 ` [PATCH net-next 12/13] rxrpc: Trace rxrpc_bundle refcount David Howells
2022-11-23 10:08 ` [PATCH net-next 13/13] rxrpc: trace: Don't use __builtin_return_address for sk_buff tracing David Howells
2022-11-24 3:23 ` [PATCH net-next 00/13] rxrpc: Increasing SACK size and moving away from softirq, part 2 Jakub Kicinski
2022-11-24 7:08 ` David Howells
2022-11-28 18:48 ` Jakub Kicinski
2022-11-28 20:16 ` David Howells
2022-11-28 20:28 ` Jakub Kicinski
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=166919800599.1256245.15876799628241612501.stgit@warthog.procyon.org.uk \
--to=dhowells@redhat.com \
--cc=linux-afs@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=marc.dionne@auristor.com \
--cc=netdev@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.