Lines Matching refs:handle

102 i_dladm_vnic_create_sys(dladm_handle_t handle, dladm_vnic_attr_t *attr)
127 rc = ioctl(dladm_dld_fd(handle), VNIC_IOC_CREATE, &ioc);
155 i_dladm_vnic_info_active(dladm_handle_t handle, datalink_id_t linkid,
167 rc = ioctl(dladm_dld_fd(handle), VNIC_IOC_INFO, &ioc);
190 i_dladm_vnic_info_persist(dladm_handle_t handle, datalink_id_t linkid,
201 if ((status = dladm_getsnap_conf(handle, linkid, &conf)) !=
205 status = dladm_get_conf_field(handle, conf, FLINKOVER, linkover,
214 if ((status = dladm_name2info(handle, linkover,
219 if ((status = dladm_datalink_id2info(handle, linkid, NULL, &class,
231 status = dladm_get_conf_field(handle, conf, FMADDRTYPE, &u64,
238 if ((status = dladm_get_conf_field(handle, conf, FVRID,
245 if ((status = dladm_get_conf_field(handle, conf, FVRAF,
252 status = dladm_get_conf_field(handle, conf, FMADDRLEN, &u64,
257 status = dladm_get_conf_field(handle, conf, FMADDRSLOT, &u64,
262 status = dladm_get_conf_field(handle, conf, FMADDRPREFIXLEN,
267 status = dladm_get_conf_field(handle, conf, FMACADDR, macstr,
277 status = dladm_get_conf_field(handle, conf, FVLANID, &u64,
283 dladm_destroy_conf(handle, conf);
288 dladm_vnic_info(dladm_handle_t handle, datalink_id_t linkid,
292 return (i_dladm_vnic_info_active(handle, linkid, attrp));
294 return (i_dladm_vnic_info_persist(handle, linkid, attrp));
303 i_dladm_vnic_delete_sys(dladm_handle_t handle, datalink_id_t linkid)
311 rc = ioctl(dladm_dld_fd(handle), VNIC_IOC_DELETE, &ioc);
396 dladm_vnic_create(dladm_handle_t handle, const char *vnic, datalink_id_t linkid,
431 if ((status = dladm_datalink_id2info(handle, linkid, NULL,
499 if ((status = dladm_create_datalink_id(handle, name, class,
512 status = dladm_link_proplist_extract(handle, proplist,
534 status = i_dladm_vnic_create_sys(handle, &attr);
543 status = dladm_vnic_persist_conf(handle, name, &attr, class);
552 status = dladm_set_linkprop(handle, vnic_id,
563 (void) dladm_remove_conf(handle, vnic_id);
565 (void) i_dladm_vnic_delete_sys(handle, vnic_id);
566 (void) dladm_destroy_datalink_id(handle, vnic_id, flags);
577 stat2 = dladm_bridge_refresh(handle, linkid);
588 dladm_vnic_delete(dladm_handle_t handle, datalink_id_t linkid, uint32_t flags)
596 if ((dladm_datalink_id2info(handle, linkid, NULL, &class, NULL, NULL, 0)
610 status = i_dladm_vnic_delete_sys(handle, linkid);
612 (void) dladm_set_linkprop(handle, linkid, NULL, NULL, 0,
614 (void) dladm_destroy_datalink_id(handle, linkid,
622 (void) dladm_remove_conf(handle, linkid);
623 (void) dladm_destroy_datalink_id(handle, linkid,
626 return (dladm_bridge_refresh(handle, linkid));
661 dladm_vnic_persist_conf(dladm_handle_t handle, const char *name,
670 if ((status = dladm_create_conf(handle, name, attrp->va_vnic_id,
675 status = dladm_datalink_id2info(handle, attrp->va_link_id, NULL,
679 status = dladm_set_conf_field(handle, conf, FLINKOVER,
687 status = dladm_set_conf_field(handle, conf, FMADDRTYPE,
693 status = dladm_set_conf_field(handle, conf, FVRID,
699 status = dladm_set_conf_field(handle, conf, FVRAF,
706 status = dladm_set_conf_field(handle, conf, FMADDRLEN,
714 status = dladm_set_conf_field(handle, conf,
723 status = dladm_set_conf_field(handle, conf,
730 status = dladm_set_conf_field(handle, conf, FMACADDR,
738 status = dladm_set_conf_field(handle, conf, FVLANID,
747 status = dladm_write_conf(handle, conf);
750 dladm_destroy_conf(handle, conf);
760 i_dladm_vnic_up(dladm_handle_t handle, datalink_id_t linkid, void *arg)
769 status = dladm_vnic_info(handle, linkid, &attr, DLADM_OPT_PERSIST);
774 status = dladm_link_get_proplist(handle, linkid, &proplist);
779 status = dladm_link_proplist_extract(handle, proplist,
783 status = i_dladm_vnic_create_sys(handle, &attr);
785 status = dladm_up_datalink_id(handle, linkid);
787 (void) i_dladm_vnic_delete_sys(handle, linkid);
796 dladm_vnic_up(dladm_handle_t handle, datalink_id_t linkid, uint32_t flags)
805 (void) dladm_walk_datalink_id(i_dladm_vnic_up, handle,
810 (void) i_dladm_vnic_up(handle, linkid, &vnic_arg);