NFS: add a separate delegation return list

Searching for returnable delegations in the per-server delegations list
can be very expensive.  While commit e04bbf6b1b ("NFS: Avoid quadratic
search when freeing delegations.") reduced the overhead a bit, the
fact that all the non-returnable delegations have to be searched limits
the amount of optimizations that can be done.

Fix this by introducing a separate list that only contains delegations
scheduled for return.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Anna Schumaker <anna.schumaker@oracle.com>
This commit is contained in:
Christoph Hellwig 2026-01-07 08:27:13 +01:00 • committed by Anna Schumaker
commit 0ebe655bd0
5 changed files with 85 additions and 87 deletions