]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
net: clarify SO_DEVMEM_DONTNEED behavior in documentation
authorMina Almasry <almasrymina@google.com>
Thu, 7 Nov 2024 21:03:31 +0000 (21:03 +0000)
committerJakub Kicinski <kuba@kernel.org>
Tue, 12 Nov 2024 02:11:46 +0000 (18:11 -0800)
Document new behavior when the number of frags passed is too big.

Signed-off-by: Mina Almasry <almasrymina@google.com>
Link: https://patch.msgid.link/20241107210331.3044434-2-almasrymina@google.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Documentation/networking/devmem.rst

index a55bf21f671c3cf7db50423117af81c4e85e088e..d953636453314949260f181102787742f3dbe9c7 100644 (file)
@@ -225,6 +225,15 @@ The user must ensure the tokens are returned to the kernel in a timely manner.
 Failure to do so will exhaust the limited dmabuf that is bound to the RX queue
 and will lead to packet drops.
 
+The user must pass no more than 128 tokens, with no more than 1024 total frags
+among the token->token_count across all the tokens. If the user provides more
+than 1024 frags, the kernel will free up to 1024 frags and return early.
+
+The kernel returns the number of actual frags freed. The number of frags freed
+can be less than the tokens provided by the user in case of:
+
+(a) an internal kernel leak bug.
+(b) the user passed more than 1024 frags.
 
 Implementation & Caveats
 ========================