Lines Matching defs:pg
1233 const char *instance, const char *pg)
1244 (pg != NULL)? "/:properties/" : "", (pg != NULL)? pg : "");
2297 general_enable_id(tx_commit_data_t *tx_data, size_t cmd_no, const char *pg,
2324 if (strcmp(pg, SCF_PG_GENERAL) == 0) {
2327 } else if (strcmp(pg, SCF_PG_GENERAL_OVR) == 0) {
2541 * If the propname property exists in pg, and it is of type string, add its
2542 * values as authorizations to pcp. pg must not be locked on entry, and it is
2544 * _DELETED - pg was deleted
2546 * _NOT_FOUND - pg has no property named propname
2550 perm_add_pg_prop_values(permcheck_t *pcp, rc_node_t *pg, const char *propname)
2558 assert(!MUTEX_HELD(&pg->rn_lock));
2559 assert(pg->rn_id.rl_type == REP_PROTOCOL_ENTITY_PROPERTYGRP);
2561 (void) pthread_mutex_lock(&pg->rn_lock);
2562 result = rc_node_find_named_child(pg, propname,
2564 (void) pthread_mutex_unlock(&pg->rn_lock);
2592 (pg->rn_id.rl_ids[ID_INSTANCE]) ? PC_AUTH_INST :
2613 * _NOT_FOUND - ent does not have pgname pg or propname property
2620 rc_node_t *pg;
2626 REP_PROTOCOL_ENTITY_PROPERTYGRP, &pg);
2641 if (pg == NULL)
2644 if (pgtype == NULL || strcmp(pg->rn_type, pgtype) == 0) {
2645 r = perm_add_pg_prop_values(pcp, pg, propname);
2661 rc_node_rele(pg);
2667 * If pg has a property named propname, and is string typed, add its values as
2668 * authorizations to pcp. If pg has no such property, and its parent is an
2673 * _DELETED - pg (or an ancestor) was deleted
2676 perm_add_enabling_values(permcheck_t *pcp, rc_node_t *pg, const char *propname)
2683 r = perm_add_pg_prop_values(pcp, pg, propname);
2688 assert(!MUTEX_HELD(&pg->rn_lock));
2690 if (pg->rn_id.rl_ids[ID_INSTANCE] == 0)
2693 sz = strlcpy(pgname, pg->rn_name, sizeof (pgname));
2697 * If pg is a child of an instance or snapshot, we want to compose the
2700 * cases, the pg's parent will be the instance.
2702 r = rc_node_find_ancestor(pg, REP_PROTOCOL_ENTITY_SERVICE, &svc);
4069 * create the actions pg and the general_ovr pg.
4166 rc_node_t *pg = NULL;
4181 assert(pg == NULL);
4182 pg = np;
4208 pg != NULL ? pg->rn_name : NULL);
4223 } else if (pg != NULL) {
4224 np = pg;
4225 pg = NULL;
5585 rc_node_t *pg = NULL, *spg = NULL, *svc, *prop;
5591 REP_PROTOCOL_ENTITY_PROPERTYGRP, &pg);
5611 if (pg != NULL)
5612 rc_node_rele(pg);
5630 if (pg != NULL)
5631 rc_node_rele(pg);
5639 if (pg != NULL &&
5640 pgtype != NULL && strcmp(pg->rn_type, pgtype) != 0) {
5641 rc_node_rele(pg);
5642 pg = NULL;
5651 if (pg == NULL) {
5654 pg = spg;
5659 * At this point, pg is non-NULL, and is a property group node of the
5661 * the correct type. Check for the property in pg first, then spg
5664 (void) pthread_mutex_lock(&pg->rn_lock);
5665 ret = rc_node_find_named_child(pg, propname,
5667 (void) pthread_mutex_unlock(&pg->rn_lock);
5668 rc_node_rele(pg);
5697 pg = spg;
5699 (void) pthread_mutex_lock(&pg->rn_lock);
5700 ret = rc_node_find_named_child(pg, propname,
5702 (void) pthread_mutex_unlock(&pg->rn_lock);
5703 rc_node_rele(pg);
6468 rc_node_t *pg;
6476 &pg);
6477 if (rc == REP_PROTOCOL_SUCCESS && pg != NULL)
6478 rc_node_rele(pg);
6493 if (pg != NULL)
6503 * at the bottom level, check to see if there's a pg at lower
6510 rc_node_t *pg;
6518 &pg);
6519 /* holds pg if not NULL */
6531 if (pg != NULL)
6532 rc_node_rele(pg);
6537 if (pg == NULL) {
6557 rc_node_rele(pg);
6562 switch (rc_node_setup_cpg(cpg, res, pg)) {
6572 rc_node_rele(pg);
6591 rc_node_rele(pg);
6691 if (np->rn_id.rl_ids[ID_INSTANCE] != 0 && /* instance pg */
6826 tx_allow_value(const void *cmds_arg, size_t cmds_sz, rc_node_t *pg)
6834 assert(!MUTEX_HELD(&pg->rn_lock));
6858 (void) pthread_mutex_lock(&pg->rn_lock);
6860 if (rc_node_find_named_child(pg,
6875 (void) pthread_mutex_unlock(&pg->rn_lock);
7094 /* Add pg-specific modify_authorization auths. */