Lines Matching defs:ipr
321 ipsec_policy_root_t *ipr = &iph->iph_root[dir];
323 if (ipr->ipr_hash == NULL)
326 for (i = 0; i < ipr->ipr_nchains; i++) {
327 ASSERT(ipr->ipr_hash[i].hash_head == NULL);
329 kmem_free(ipr->ipr_hash, ipr->ipr_nchains *
331 ipr->ipr_hash = NULL;
344 ipsec_policy_root_t *ipr = &iph->iph_root[dir];
347 for (chain = 0; chain < ipr->ipr_nchains; chain++)
348 mutex_destroy(&(ipr->ipr_hash[chain].hash_lock));
482 ipsec_policy_root_t *ipr = &iph->iph_root[dir];
484 ipr->ipr_nchains = nchains;
485 ipr->ipr_hash = kmem_zalloc(nchains *
487 if (ipr->ipr_hash == NULL)
537 ipsec_policy_root_t *ipr = &iph->iph_root[dir];
538 ipr->ipr_nchains = nchains;
541 mutex_init(&(ipr->ipr_hash[chain].hash_lock),
3850 ipsec_ipr_flush(ipsec_policy_head_t *php, ipsec_policy_root_t *ipr)
3856 for (ip = ipr->ipr_nonhash[af]; ip != NULL; ip = nip) {
3860 ipr->ipr_nonhash[af] = NULL;
3862 nchain = ipr->ipr_nchains;
3865 for (ip = ipr->ipr_hash[chain].hash_head; ip != NULL;
3870 ipr->ipr_hash[chain].hash_head = NULL;
3924 ipsec_policy_root_t *ipr = &php->iph_root[dir];
3927 for (chain = 0; chain < ipr->ipr_nchains; chain++)
3928 mutex_destroy(&(ipr->ipr_hash[chain].hash_lock));
3936 ipsec_ipr_init(ipsec_policy_root_t *ipr)
3940 ipr->ipr_nchains = 0;
3941 ipr->ipr_hash = NULL;
3944 ipr->ipr_nonhash[af] = NULL;