mbox series

[v2,0/2] add support for CB_RECALL_ANY and the delegation shrinker

Message ID 1666462150-11736-1-git-send-email-dai.ngo@oracle.com (mailing list archive)
Headers show
Series add support for CB_RECALL_ANY and the delegation shrinker | expand

Message

Dai Ngo Oct. 22, 2022, 6:09 p.m. UTC
This patch series adds:

    . support for sending the CB_RECALL_ANY op.
      There is only one nfsd4_callback, cl_recall_any, added for each
      nfs4_client. Access to it must be serialized. For now it's done
      by the cl_recall_any_busy flag since it's used only by the
      delegation shrinker. If there is another consumer of cl_recall_any
      then a spinlock must be used.

    . the delegation shrinker that sends the advisory CB_RECALL_ANY 
      to the clients to release unused delegations.

v2:
    . modify deleg_reaper to check and send CB_RECALL_ANY to client
      only once per 5 secs.
---

Dai Ngo (2):
     NFSD: add support for sending CB_RECALL_ANY
     NFSD: add delegation shrinker to react to low memory condition

 fs/nfsd/netns.h        |   3 ++
 fs/nfsd/nfs4callback.c |  64 ++++++++++++++++++++++++++++
 fs/nfsd/nfs4state.c    | 101 +++++++++++++++++++++++++++++++++++++++++++-
 fs/nfsd/state.h        |  10 +++++
 fs/nfsd/xdr4cb.h       |   6 +++
 5 files changed, 183 insertions(+), 1 deletion(-)