Lines Matching defs:pdp

83 typedef dladm_status_t	pd_getf_t(dladm_handle_t, prop_desc_t *pdp,
116 typedef dladm_status_t pd_checkf_t(dladm_handle_t, prop_desc_t *pdp,
874 check_prop(dladm_handle_t handle, prop_desc_t *pdp, datalink_id_t linkid,
883 for (i = 0; i < pdp->pd_noptval; i++) {
885 pdp->pd_optval[i].vd_name) == 0) {
889 if (i == pdp->pd_noptval)
892 (void) memcpy(&vdp[j], &pdp->pd_optval[i], sizeof (val_desc_t));
899 datalink_class_t class, uint32_t media, prop_desc_t *pdp, char **prop_val,
907 if (!(pdp->pd_class & class))
910 if (!DATALINK_MEDIA_ACCEPTED(pdp->pd_dmedia, media))
913 if ((flags & DLADM_OPT_PERSIST) && (pdp->pd_flags & PD_TEMPONLY))
919 if (pdp->pd_set == NULL)
927 if (pdp->pd_check != NULL) {
928 needfree = ((pdp->pd_flags & PD_CHECK_ALLOC) != 0);
929 status = pdp->pd_check(handle, pdp, linkid, prop_val,
931 } else if (pdp->pd_optval != NULL) {
932 status = check_prop(handle, pdp, linkid, prop_val,
945 if (pdp->pd_defval.vd_name == NULL)
949 defval = (strlen(pdp->pd_defval.vd_name) > 0);
950 if ((pdp->pd_flags & PD_CHECK_ALLOC) != 0 || defval) {
955 (void) memcpy(vdp, &pdp->pd_defval,
957 } else if (pdp->pd_check != NULL) {
958 status = pdp->pd_check(handle, pdp, linkid,
964 status = i_dladm_getset_defval(handle, pdp, linkid,
969 if (pdp->pd_flags & PD_AFTER_PERM)
973 status = pdp->pd_set(handle, pdp, linkid, vdp, cnt, flags,
1000 prop_desc_t *pdp = &prop_table[i];
1004 (strcasecmp(prop_name, pdp->pd_name) != 0))
1007 s = i_dladm_set_single_prop(handle, linkid, class, media, pdp,
1061 prop_desc_t *pdp = prop_table;
1064 for (i = 0; i < DLADM_MAX_PROPS; i++, pdp++) {
1065 if (!(pdp->pd_flags & PD_AFTER_PERM))
1068 strcasecmp(prop_name, pdp->pd_name) != 0)
1070 status = pdp->pd_set(handle, pdp, linkid, NULL,
1134 prop_desc_t *pdp;
1169 pdp = &prop_table[i];
1176 if (!(pdp->pd_class & class))
1179 if (!DATALINK_MEDIA_ACCEPTED(pdp->pd_dmedia, media))
1184 status = pdp->pd_get(handle, pdp, linkid, prop_val, val_cntp,
1189 if (pdp->pd_set == NULL) {
1192 status = pdp->pd_get(handle, pdp, linkid, prop_val,
1210 if (pdp->pd_defval.vd_name == NULL) {
1215 if (strlen(pdp->pd_defval.vd_name) == 0) {
1216 status = pdp->pd_get(handle, pdp, linkid, prop_val,
1219 (void) strcpy(*prop_val, pdp->pd_defval.vd_name);
1225 if (pdp->pd_getmod != NULL) {
1226 status = pdp->pd_getmod(handle, pdp, linkid, prop_val,
1230 cnt = pdp->pd_noptval;
1238 pdp->pd_optval[i].vd_name);
1244 if (pdp->pd_flags & PD_TEMPONLY)
1270 prop_desc_t *pdp;
1280 for (pdp = prop_table; pdp < prop_table + DLADM_MAX_PROPS; pdp++)
1281 if (strcasecmp(prop_name, pdp->pd_name) == 0)
1284 if (pdp == prop_table + DLADM_MAX_PROPS)
1287 if (pdp->pd_flags & PD_CHECK_ALLOC)
1295 if (!(pdp->pd_class & class))
1298 if (!DATALINK_MEDIA_ACCEPTED(pdp->pd_dmedia, media))
1313 status = pdp->pd_get(handle, pdp, linkid, prop_val, val_cntp,
1325 if (pdp->pd_defval.vd_name == NULL) {
1330 if (pdp->pd_defval.vd_name[0] != '\0') {
1332 *ret_val = pdp->pd_defval.vd_val;
1336 status = pdp->pd_get(handle, pdp, linkid, prop_val, val_cntp,
1341 if (pdp->pd_flags & PD_TEMPONLY)
1354 if (pdp->pd_check != NULL) {
1361 status = pdp->pd_check(handle, pdp, linkid,
1370 for (i = 0; i < pdp->pd_noptval; i++) {
1371 if (strcmp(pdp->pd_optval[i].vd_name,
1374 pdp->pd_optval[i].vd_val;
1378 if (i == pdp->pd_noptval) {
1483 get_zone(dladm_handle_t handle, prop_desc_t *pdp, datalink_id_t linkid,
1494 status = i_dladm_get_public_prop(handle, linkid, pdp->pd_name, flags,
1583 set_zone(dladm_handle_t handle, prop_desc_t *pdp, datalink_id_t linkid,
1595 status = i_dladm_get_public_prop(handle, linkid, pdp->pd_name, flags,
1604 if ((status = set_public_prop(handle, pdp, linkid, vdp, val_cnt,
1624 check_zone(dladm_handle_t handle, prop_desc_t *pdp, datalink_id_t linkid,
1677 get_maxbw(dladm_handle_t handle, prop_desc_t *pdp, datalink_id_t linkid,
1701 check_maxbw(dladm_handle_t handle, prop_desc_t *pdp, datalink_id_t linkid,
1750 get_cpus(dladm_handle_t handle, prop_desc_t *pdp, datalink_id_t linkid,
1759 if (strcmp(pdp->pd_name, "cpus-effective") == 0) {
1800 check_cpus(dladm_handle_t handle, prop_desc_t *pdp, datalink_id_t linkid,
1931 get_pool(dladm_handle_t handle, prop_desc_t *pdp, datalink_id_t linkid,
1938 if (strcmp(pdp->pd_name, "pool-effective") == 0) {
1963 check_pool(dladm_handle_t handle, prop_desc_t *pdp, datalink_id_t linkid,
2045 get_priority(dladm_handle_t handle, prop_desc_t *pdp,
2109 check_rings(dladm_handle_t handle, prop_desc_t *pdp,
2132 get_rings_range(dladm_handle_t handle, prop_desc_t *pdp,
2144 if ((dip = i_dladm_buf_alloc_by_name(sz, linkid, pdp->pd_name, flags,
2187 get_rxrings(dladm_handle_t handle, prop_desc_t *pdp, datalink_id_t linkid,
2198 if (strcmp(pdp->pd_name, "rxrings-effective") == 0) {
2253 get_txrings(dladm_handle_t handle, prop_desc_t *pdp, datalink_id_t linkid,
2265 if (strcmp(pdp->pd_name, "txrings-effective") == 0) {
2323 get_cntavail(dladm_handle_t handle, prop_desc_t *pdp, datalink_id_t linkid,
2330 return (get_uint32(handle, pdp, linkid, prop_val, val_cnt, media,
2336 set_resource(dladm_handle_t handle, prop_desc_t *pdp,
2355 if (strcmp(pdp->pd_name, rp->rp_name) != 0)
2375 get_protection(dladm_handle_t handle, prop_desc_t *pdp,
2407 get_allowedips(dladm_handle_t handle, prop_desc_t *pdp,
2583 check_allowedips(dladm_handle_t handle, prop_desc_t *pdp,
2868 get_allowedcids(dladm_handle_t handle, prop_desc_t *pdp,
2921 check_allowedcids(dladm_handle_t handle, prop_desc_t *pdp,
2957 get_secondary_macs(dladm_handle_t handle, prop_desc_t *pdp,
2965 status = i_dladm_get_public_prop(handle, linkid, pdp->pd_name, flags,
2987 check_secondary_macs(dladm_handle_t handle, prop_desc_t *pdp,
3057 get_autopush(dladm_handle_t handle, prop_desc_t *pdp, datalink_id_t linkid,
3068 status = i_dladm_get_public_prop(handle, linkid, pdp->pd_name, flags,
3136 check_autopush(dladm_handle_t handle, prop_desc_t *pdp, datalink_id_t linkid,
3178 get_rate_common(dladm_handle_t handle, prop_desc_t *pdp,
3220 get_rate(dladm_handle_t handle, prop_desc_t *pdp, datalink_id_t linkid,
3225 return (get_speed(handle, pdp, linkid, prop_val,
3229 return (get_rate_common(handle, pdp, linkid, prop_val, val_cnt,
3235 get_rate_mod(dladm_handle_t handle, prop_desc_t *pdp, datalink_id_t linkid,
3248 return (get_rate_common(handle, pdp, linkid, prop_val,
3284 set_rate(dladm_handle_t handle, prop_desc_t *pdp, datalink_id_t linkid,
3309 check_rate(dladm_handle_t handle, prop_desc_t *pdp, datalink_id_t linkid,
3367 get_channel(dladm_handle_t handle, prop_desc_t *pdp,
3392 get_powermode(dladm_handle_t handle, prop_desc_t *pdp,
3427 set_powermode(dladm_handle_t handle, prop_desc_t *pdp,
3458 get_radio(dladm_handle_t handle, prop_desc_t *pdp, datalink_id_t linkid,
3490 set_radio(dladm_handle_t handle, prop_desc_t *pdp, datalink_id_t linkid,
3515 check_hoplimit(dladm_handle_t handle, prop_desc_t *pdp,
3538 check_encaplim(dladm_handle_t handle, prop_desc_t *pdp, datalink_id_t linkid,
3746 set_public_prop(dladm_handle_t handle, prop_desc_t *pdp,
3757 dip = i_dladm_buf_alloc_by_name(0, linkid, pdp->pd_name, 0, &status);
3761 if (pdp->pd_flags & PD_CHECK_ALLOC)
3839 check_uint32(dladm_handle_t handle, prop_desc_t *pdp,
3854 get_duplex(dladm_handle_t handle, prop_desc_t *pdp,
3882 get_speed(dladm_handle_t handle, prop_desc_t *pdp, datalink_id_t linkid,
3907 get_link_state(dladm_handle_t handle, prop_desc_t *pdp,
3936 get_binary(dladm_handle_t handle, prop_desc_t *pdp,
3943 status = i_dladm_get_public_prop(handle, linkid, pdp->pd_name, flags,
3955 get_uint32(dladm_handle_t handle, prop_desc_t *pdp,
3962 status = i_dladm_get_public_prop(handle, linkid, pdp->pd_name, flags,
3974 get_range(dladm_handle_t handle, prop_desc_t *pdp,
3993 if ((dip = i_dladm_buf_alloc_by_name(sz, linkid, pdp->pd_name, flags,
4053 get_tagmode(dladm_handle_t handle, prop_desc_t *pdp,
4060 status = i_dladm_get_public_prop(handle, linkid, pdp->pd_name, flags,
4081 get_flowctl(dladm_handle_t handle, prop_desc_t *pdp,
4088 status = i_dladm_get_public_prop(handle, linkid, pdp->pd_name, flags,
4229 i_dladm_getset_defval(dladm_handle_t handle, prop_desc_t *pdp,
4255 * For properties which have pdp->pd_defval.vd_name as a non-empty
4258 * libdladm can copy pdp->pd_defval over to the val_desc_t passed
4264 status = pdp->pd_get(handle, pdp, linkid, prop_vals, &cnt, media,
4269 pdp->pd_class, media, pdp, prop_vals, cnt, flags);
4645 prop_desc_t *pdp = &prop_table[i];
4652 if (strcasecmp(aip->ai_name, pdp->pd_name) != 0)
4659 if (pdp->pd_check != NULL) {
4660 status = pdp->pd_check(handle, pdp, 0, aip->ai_val,
4816 get_linkmode_prop(dladm_handle_t handle, prop_desc_t *pdp,
4824 status = i_dladm_get_public_prop(handle, linkid, pdp->pd_name, flags,
4848 get_promisc_filtered(dladm_handle_t handle, prop_desc_t *pdp,
4856 status = i_dladm_get_public_prop(handle, linkid, pdp->pd_name, flags,
4873 set_promisc_filtered(dladm_handle_t handle, prop_desc_t *pdp,
4880 dip = i_dladm_buf_alloc_by_name(0, linkid, pdp->pd_name,