HomeFreeBSD

nfsd: Add VNET_SYSUNINIT() macros for vnet cleanup

Description

nfsd: Add VNET_SYSUNINIT() macros for vnet cleanup

Commit ed03776ca7f4 enabled the vnet front end macros.
As such, for kernels built with the VIMAGE option will malloc
data and initialize locks on a per-vnet basis, typically
via a VNET_SYSINIT().

This patch adds VNET_SYSUNINIT() macros to do the frees
of the per-vnet malloc'd data and destroys of per-vnet
locks. It also removes the mtx_lock/mtx_unlock calls
from nfsrvd_cleancache(), since they are not needed.

(cherry picked from commit ef6fcc5e2b0714c859d2e4ba23a55b1fd12f8a4e)

Details

Provenance
rmacklemAuthored on Feb 20 2023, 9:11 PM
Parents
rG56b45bf5f6e1: nfsd: Enable the NFSD_VNET vnet front end macros
Branches
Unknown
Tags
Unknown