Hi NFS experts,
I'm planning to enhance zone reference counting in the kernel (see CR
6906740). My enhancement will add pointers to a new structure,
zone_ref_crumb, to NFS' mntinfo and mntinfo4 structures:
---8<---
typedef struct zone_ref_crumb {
struct zone *zone; /* the zone to which the reference
refers */
zone_hold_subsys_t subsys; /* the subsystem that acquired the
ref */
} *zone_ref_crumb_t;
---8<---
The zones subsystem will provide two new functions, zone_tracked_hold()
and zone_tracked_rele(), to allocate and destroy zone_ref_crumb
structures. The functions also increment and decrement the specified
zone's reference count, respectively.
I will change nfsrootvp() and nfs4rootvp() to hold a zone via
zone_tracked_hold() rather than zone_hold() and nfs_free_mi(),
nfs4_mi_shutdown(), nfs4_unmount(), and nfs4_free_mount() to release the
references acquired by nfsrootvp() and nfs4rootvp() via
zone_tracked_rele() rather than zone_rele().
mntinfo and mntinfo4 already have pointers to zones, mi_zone, but such
pointers will be unnecessary after I add zone_ref_crumb pointers because
of zone_ref_crumb::zone. I'd like to replace mi_zone, but I don't know
if any threads access mntinfo::mi_zone or mntinfo4::mi_zone after
nfs_free_mi(), nfs4_mi_shutdown(), nfs4_unmount(), and nfs4_free_mount()
are called. Do any threads do this?
Thanks,
Jordan
_______________________________________________
nfs-discuss mailing list
[email protected]