summaryrefslogtreecommitdiff
path: root/net/rxrpc/protocol.h
diff options
context:
space:
mode:
authorDavid Howells <dhowells@redhat.com>2019-09-02 11:43:44 +0100
committerDavid Howells <dhowells@redhat.com>2019-09-02 11:43:44 +0100
commitf16180739cd18a39a1a45516ac0e65d18a9f100e (patch)
tree22d1135650f8ddb25707c788cd4846c77b428ff0 /net/rxrpc/protocol.h
parent9f159ae07f07fc540290f21937231034f554bdd7 (diff)
parente1e54ec7fb55501c33b117c111cb0a045b8eded2 (diff)
Merge remote-tracking branch 'net/master' into afs-next
Diffstat (limited to 'net/rxrpc/protocol.h')
-rw-r--r--net/rxrpc/protocol.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/net/rxrpc/protocol.h b/net/rxrpc/protocol.h
index 99ce322d7caa..49bb972539aa 100644
--- a/net/rxrpc/protocol.h
+++ b/net/rxrpc/protocol.h
@@ -89,6 +89,15 @@ struct rxrpc_jumbo_header {
#define RXRPC_JUMBO_DATALEN 1412 /* non-terminal jumbo packet data length */
#define RXRPC_JUMBO_SUBPKTLEN (RXRPC_JUMBO_DATALEN + sizeof(struct rxrpc_jumbo_header))
+/*
+ * The maximum number of subpackets that can possibly fit in a UDP packet is:
+ *
+ * ((max_IP - IP_hdr - UDP_hdr) / RXRPC_JUMBO_SUBPKTLEN) + 1
+ * = ((65535 - 28 - 28) / 1416) + 1
+ * = 46 non-terminal packets and 1 terminal packet.
+ */
+#define RXRPC_MAX_NR_JUMBO 47
+
/*****************************************************************************/
/*
* on-the-wire Rx ACK packet data payload