• M
    nfsd41: sessionid hashing · 5282fd72
    Marc Eshel 提交于
    Simple sessionid hashing using its monotonically increasing sequence number.
    
    Locking considerations:
    sessionid_hashtbl access is controlled by the sessionid_lock spin lock.
    It must be taken for insert, delete, and lookup.
    nfsd4_sequence looks up the session id and if the session is found,
    it calls nfsd4_get_session (still under the sessionid_lock).
    nfsd4_destroy_session calls nfsd4_put_session after unhashing
    it, so when the session's kref reaches zero it's going to get freed.
    Signed-off-by: NBenny Halevy <bhalevy@panasas.com>
    [we don't use a prime for sessionid hash table size]
    [use sessionid_lock spin lock]
    Signed-off-by: NBenny Halevy <bhalevy@panasas.com>
    Signed-off-by: NJ. Bruce Fields <bfields@citi.umich.edu>
    5282fd72
state.h 11.6 KB