1RPC_MALLOC(9)                  Linux Networking                  RPC_MALLOC(9)
2
3
4

NAME

6       rpc_malloc - allocate RPC buffer resources
7

SYNOPSIS

9       int rpc_malloc(struct rpc_task * task);
10

ARGUMENTS

12       task
13           RPC task
14

DESCRIPTION

16       A single memory region is allocated, which is split between the RPC
17       call and RPC reply that this task is being used for. When this RPC is
18       retired, the memory is released by calling rpc_free.
19
20       To prevent rpciod from hanging, this allocator never sleeps, returning
21       -ENOMEM and suppressing warning if the request cannot be serviced
22       immediately. The caller can arrange to sleep in a way that is safe for
23       rpciod.
24
25       Most requests are 'small' (under 2KiB) and can be serviced from a
26       mempool, ensuring that NFS reads and writes can always proceed, and
27       that there is good locality of reference for these buffers.
28
29       In order to avoid memory starvation triggering more writebacks of NFS
30       requests, we avoid using GFP_KERNEL.
31
33Kernel Hackers Manual 3.10         June 2019                     RPC_MALLOC(9)
Impressum