Lines Matching refs:sap
54 const struct sockaddr *sap; /* address to search for */ member
73 static unsigned int __nlm_hash_addr4(const struct sockaddr *sap) in __nlm_hash_addr4() argument
75 const struct sockaddr_in *sin = (struct sockaddr_in *)sap; in __nlm_hash_addr4()
79 static unsigned int __nlm_hash_addr6(const struct sockaddr *sap) in __nlm_hash_addr6() argument
81 const struct sockaddr_in6 *sin6 = (struct sockaddr_in6 *)sap; in __nlm_hash_addr6()
89 static unsigned int nlm_hash_address(const struct sockaddr *sap) in nlm_hash_address() argument
93 switch (sap->sa_family) { in nlm_hash_address()
95 hash = __nlm_hash_addr4(sap); in nlm_hash_address()
98 hash = __nlm_hash_addr6(sap); in nlm_hash_address()
119 nsm = nsm_get_handle(ni->net, ni->sap, ni->salen, in nlm_alloc_host()
135 memcpy(nlm_addr(host), ni->sap, ni->salen); in nlm_alloc_host()
210 struct nlm_host *nlmclnt_lookup_host(const struct sockaddr *sap, in nlmclnt_lookup_host() argument
220 .sap = sap, in nlmclnt_lookup_host()
240 chain = &nlm_client_hosts[nlm_hash_address(sap)]; in nlmclnt_lookup_host()
244 if (!rpc_cmp_addr(nlm_addr(host), sap)) in nlmclnt_lookup_host()
333 .sap = svc_addr(rqstp), in nlmsvc_lookup_host()
352 chain = &nlm_server_hosts[nlm_hash_address(ni.sap)]; in nlmsvc_lookup_host()
356 if (!rpc_cmp_addr(nlm_addr(host), ni.sap)) in nlmsvc_lookup_host()