Home
last modified time | relevance | path

Searched refs:mac (Results 1 – 25 of 379) sorted by relevance

12345678910>>...16

/onnv-gate/usr/src/uts/common/io/fcoe/
H A Dfcoe_eth.c60 fcoe_open_mac(fcoe_mac_t *mac, int force_promisc, fcoeio_stat_t *err_detail) in fcoe_open_mac() argument
73 ret = mac_open_by_linkid(mac->fm_linkid, &mac->fm_handle); in fcoe_open_mac()
76 mac->fm_linkid, ret); in fcoe_open_mac()
80 (void) sprintf(cli_name, "%s-%d", "fcoe", mac->fm_linkid); in fcoe_open_mac()
82 ret = mac_client_open(mac->fm_handle, in fcoe_open_mac()
83 &mac->fm_cli_handle, cli_name, fm_open_flag); in fcoe_open_mac()
85 (void) fcoe_close_mac(mac); in fcoe_open_mac()
92 mac_unicast_primary_get(mac->fm_handle, mac->fm_primary_addr); in fcoe_open_mac()
93 bcopy(mac->fm_primary_addr, mac->fm_current_addr, in fcoe_open_mac()
96 if (mac_unicast_add(mac->fm_cli_handle, NULL, MAC_UNICAST_PRIMARY, in fcoe_open_mac()
[all …]
H A Dfcoe_fc.c72 fcoe_mac_t *mac; in fcoe_register_client() local
85 for (mac = list_head(&fcoe_global_ss->ss_mac_list); mac; in fcoe_register_client()
86 mac = list_next(&fcoe_global_ss->ss_mac_list, mac)) { in fcoe_register_client()
87 if (client->ect_channelid == mac->fm_linkid) { in fcoe_register_client()
92 if (mac == NULL) { in fcoe_register_client()
97 if (mac->fm_flags & FCOE_MAC_FLAG_BOUND) { in fcoe_register_client()
102 atomic_or_32(&mac->fm_flags, FCOE_MAC_FLAG_BOUND); in fcoe_register_client()
103 bcopy(client, &mac->fm_client, sizeof (fcoe_client_t)); in fcoe_register_client()
108 eport = &mac->fm_eport; in fcoe_register_client()
110 eport->eport_fcoe_private = mac; in fcoe_register_client()
[all …]
H A Dfcoe.c117 static void fcoe_init_wwn_from_mac(uint8_t *wwn, uint8_t *mac,
943 fcoe_mac_t *mac = NULL; in fcoe_lookup_mac_by_id() local
946 for (mac = list_head(&fcoe_global_ss->ss_mac_list); mac; in fcoe_lookup_mac_by_id()
947 mac = list_next(&fcoe_global_ss->ss_mac_list, mac)) { in fcoe_lookup_mac_by_id()
948 if (linkid != mac->fm_linkid) { in fcoe_lookup_mac_by_id()
951 return (mac); in fcoe_lookup_mac_by_id()
962 fcoe_mac_t *mac = NULL; in fcoe_mac_existed() local
965 for (mac = list_head(&fcoe_global_ss->ss_mac_list); mac; in fcoe_mac_existed()
966 mac = list_next(&fcoe_global_ss->ss_mac_list, mac)) { in fcoe_mac_existed()
967 if (mac == pmac) { in fcoe_mac_existed()
[all …]
/onnv-gate/usr/src/uts/intel/io/dnet/
H A Ddnet_mii.c61 static struct phydata *mii_get_valid_phydata(mii_handle_t mac, int phy);
62 static void mii_portmon(mii_handle_t mac);
71 static void postreset_ICS1890(mii_handle_t mac, int phy);
72 static void postreset_NS83840(mii_handle_t mac, int phy);
88 mii_handle_t mac; in mii_create() local
91 if ((mac = (mii_handle_t) in mii_create()
95 mac->mii_write = writefunc; in mii_create()
96 mac->mii_read = readfunc; in mii_create()
97 mac->mii_dip = dip; in mii_create()
98 *macp = mac; in mii_create()
[all …]
/onnv-gate/usr/src/uts/common/io/chxge/com/
H A Dixf1010.c156 #define MACREG(mac, mac_reg) ((mac)->instance->mac_base + (mac_reg)) argument
165 static void disable_port(struct cmac *mac) in disable_port() argument
169 (void) t1_tpi_read(mac->adapter, REG_PORT_ENABLE, &val); in disable_port()
170 val &= ~(1 << mac->instance->index); in disable_port()
171 (void) t1_tpi_write(mac->adapter, REG_PORT_ENABLE, val); in disable_port()
174 #define RMON_UPDATE(mac, name, stat_name) \ argument
175 (void) t1_tpi_read((mac)->adapter, MACREG(mac, REG_##name), &val); \
176 (mac)->stats.stat_name += val;
182 static void port_stats_update(struct cmac *mac) in port_stats_update() argument
187 RMON_UPDATE(mac, RxOctetsTotalOK, RxOctetsOK); in port_stats_update()
[all …]
H A Dch_mac.c80 static int mac_intr_enable(struct cmac *mac) in mac_intr_enable() argument
84 if (t1_is_asic(mac->adapter)) { in mac_intr_enable()
92 mac_intr = t1_read_reg_4(mac->adapter, A_PL_ENABLE); in mac_intr_enable()
94 t1_write_reg_4(mac->adapter, A_PL_ENABLE, mac_intr); in mac_intr_enable()
96 mac_intr = t1_read_reg_4(mac->adapter, in mac_intr_enable()
98 mac_intr |= static_aPorts[mac->instance->index]; in mac_intr_enable()
99 t1_write_reg_4(mac->adapter, in mac_intr_enable()
106 static int mac_intr_disable(struct cmac *mac) in mac_intr_disable() argument
110 if (t1_is_asic(mac->adapter)) { in mac_intr_disable()
118 mac_intr = t1_read_reg_4(mac->adapter, A_PL_ENABLE); in mac_intr_disable()
[all …]
H A Dvsc7326.c384 static int mac_intr_handler(struct cmac *mac) in mac_intr_handler() argument
390 static int mac_intr_enable(struct cmac *mac) in mac_intr_enable() argument
396 static int mac_intr_disable(struct cmac *mac) in mac_intr_disable() argument
402 static int mac_intr_clear(struct cmac *mac) in mac_intr_clear() argument
408 static int mac_set_address(struct cmac* mac, u8 addr[6]) in mac_set_address() argument
411 int port = mac->instance->index; in mac_set_address()
413 vsc_write(mac->adapter, REG_MAC_LOW_ADDR(port), in mac_set_address()
415 vsc_write(mac->adapter, REG_MAC_HIGH_ADDR(port), in mac_set_address()
418 vsc_read(mac->adapter, REG_ING_FFILT_UM_EN, &val); in mac_set_address()
420 vsc_write(mac->adapter, REG_ING_FFILT_UM_EN, val | (port << 28)); in mac_set_address()
[all …]
H A Dvsc7321.c242 struct cmac *mac; in vsc7321_mac_create() local
246 mac = t1_os_malloc_wait_zero(sizeof(*mac) + sizeof(cmac_instance)); in vsc7321_mac_create()
247 if (!mac) return NULL; in vsc7321_mac_create()
249 mac->ops = &vsc7321_ops; in vsc7321_mac_create()
250 mac->instance = (cmac_instance *)(mac + 1); in vsc7321_mac_create()
252 mac->adapter = adapter; in vsc7321_mac_create()
253 mac->instance->index = index; in vsc7321_mac_create()
275 t1_os_free((void *)mac, sizeof(*mac) + sizeof(cmac_instance)); in vsc7321_mac_create()
279 mac->instance->version = (val >> 16) & 0xf; in vsc7321_mac_create()
282 return mac; in vsc7321_mac_create()
[all …]
/onnv-gate/usr/src/cmd/ssh/libssh/common/
H A Dmac.c59 mac_setup_by_id(Mac *mac, int which) in mac_setup_by_id() argument
62 mac->type = macs[which].type; in mac_setup_by_id()
63 if (mac->type == SSH_EVP) { in mac_setup_by_id()
64 mac->evp_md = (*macs[which].mdfunc)(); in mac_setup_by_id()
65 if ((evp_len = EVP_MD_size(mac->evp_md)) <= 0) in mac_setup_by_id()
66 fatal("mac %s len %d", mac->name, evp_len); in mac_setup_by_id()
67 mac->key_len = mac->mac_len = (u_int)evp_len; in mac_setup_by_id()
69 fatal("wrong MAC type (%d)", mac->type); in mac_setup_by_id()
71 mac->mac_len = macs[which].truncatebits / 8; in mac_setup_by_id()
75 mac_setup(Mac *mac, char *name) in mac_setup() argument
[all …]
/onnv-gate/usr/src/uts/common/io/e1000g/
H A De1000_mac.c43 struct e1000_mac_info *mac = &hw->mac; in e1000_init_mac_ops_generic() local
47 mac->ops.init_params = e1000_null_ops_generic; in e1000_init_mac_ops_generic()
48 mac->ops.init_hw = e1000_null_ops_generic; in e1000_init_mac_ops_generic()
49 mac->ops.reset_hw = e1000_null_ops_generic; in e1000_init_mac_ops_generic()
50 mac->ops.setup_physical_interface = e1000_null_ops_generic; in e1000_init_mac_ops_generic()
51 mac->ops.get_bus_info = e1000_null_ops_generic; in e1000_init_mac_ops_generic()
52 mac->ops.set_lan_id = e1000_set_lan_id_multi_port_pcie; in e1000_init_mac_ops_generic()
53 mac->ops.read_mac_addr = e1000_read_mac_addr_generic; in e1000_init_mac_ops_generic()
54 mac->ops.config_collision_dist = e1000_config_collision_dist_generic; in e1000_init_mac_ops_generic()
55 mac->ops.clear_hw_cntrs = e1000_null_mac_generic; in e1000_init_mac_ops_generic()
[all …]
H A De1000_api.c44 if (hw->mac.ops.init_params) { in e1000_init_mac_params()
45 ret_val = hw->mac.ops.init_params(hw); in e1000_init_mac_params()
125 struct e1000_mac_info *mac = &hw->mac; in e1000_set_mac_type() local
132 mac->type = e1000_82542; in e1000_set_mac_type()
136 mac->type = e1000_82543; in e1000_set_mac_type()
142 mac->type = e1000_82544; in e1000_set_mac_type()
149 mac->type = e1000_82540; in e1000_set_mac_type()
153 mac->type = e1000_82545; in e1000_set_mac_type()
158 mac->type = e1000_82545_rev_3; in e1000_set_mac_type()
163 mac->type = e1000_82546; in e1000_set_mac_type()
[all …]
H A De1000_82540.c90 switch (hw->mac.type) { in e1000_init_phy_params_82540()
157 struct e1000_mac_info *mac = &hw->mac; in e1000_init_mac_params_82540() local
180 mac->mta_reg_count = 128; in e1000_init_mac_params_82540()
182 mac->rar_entry_count = E1000_RAR_ENTRIES; in e1000_init_mac_params_82540()
187 mac->ops.get_bus_info = e1000_get_bus_info_pci_generic; in e1000_init_mac_params_82540()
189 mac->ops.set_lan_id = e1000_set_lan_id_multi_port_pci; in e1000_init_mac_params_82540()
191 mac->ops.reset_hw = e1000_reset_hw_82540; in e1000_init_mac_params_82540()
193 mac->ops.init_hw = e1000_init_hw_82540; in e1000_init_mac_params_82540()
195 mac->ops.setup_link = e1000_setup_link_generic; in e1000_init_mac_params_82540()
197 mac->ops.setup_physical_interface = in e1000_init_mac_params_82540()
[all …]
H A De1000_82571.c113 switch (hw->mac.type) { in e1000_init_phy_params_82571()
212 switch (hw->mac.type) { in e1000_init_nvm_params_82571()
264 struct e1000_mac_info *mac = &hw->mac; in e1000_init_mac_params_82571() local
291 mac->mta_reg_count = 128; in e1000_init_mac_params_82571()
293 mac->rar_entry_count = E1000_RAR_ENTRIES; in e1000_init_mac_params_82571()
295 mac->asf_firmware_present = true; in e1000_init_mac_params_82571()
297 mac->arc_subsystem_valid = in e1000_init_mac_params_82571()
304 mac->ops.get_bus_info = e1000_get_bus_info_pcie_generic; in e1000_init_mac_params_82571()
306 switch (hw->mac.type) { in e1000_init_mac_params_82571()
310 mac->ops.set_lan_id = e1000_set_lan_id_single_port; in e1000_init_mac_params_82571()
[all …]
H A De1000_82542.c100 struct e1000_mac_info *mac = &hw->mac; in e1000_init_mac_params_82542() local
108 mac->mta_reg_count = 128; in e1000_init_mac_params_82542()
110 mac->rar_entry_count = E1000_RAR_ENTRIES; in e1000_init_mac_params_82542()
115 mac->ops.get_bus_info = e1000_get_bus_info_82542; in e1000_init_mac_params_82542()
117 mac->ops.set_lan_id = e1000_set_lan_id_multi_port_pci; in e1000_init_mac_params_82542()
119 mac->ops.reset_hw = e1000_reset_hw_82542; in e1000_init_mac_params_82542()
121 mac->ops.init_hw = e1000_init_hw_82542; in e1000_init_mac_params_82542()
123 mac->ops.setup_link = e1000_setup_link_82542; in e1000_init_mac_params_82542()
125 mac->ops.setup_physical_interface = in e1000_init_mac_params_82542()
128 mac->ops.check_for_link = e1000_check_for_fiber_link_generic; in e1000_init_mac_params_82542()
[all …]
H A De1000_82543.c105 phy->ops.read_reg = (hw->mac.type == e1000_82543) in e1000_init_phy_params_82543()
108 phy->ops.reset = (hw->mac.type == e1000_82543) in e1000_init_phy_params_82543()
111 phy->ops.write_reg = (hw->mac.type == e1000_82543) in e1000_init_phy_params_82543()
135 switch (hw->mac.type) { in e1000_init_phy_params_82543()
191 struct e1000_mac_info *mac = &hw->mac; in e1000_init_mac_params_82543() local
207 mac->mta_reg_count = 128; in e1000_init_mac_params_82543()
209 mac->rar_entry_count = E1000_RAR_ENTRIES; in e1000_init_mac_params_82543()
214 mac->ops.get_bus_info = e1000_get_bus_info_pci_generic; in e1000_init_mac_params_82543()
216 mac->ops.set_lan_id = e1000_set_lan_id_multi_port_pci; in e1000_init_mac_params_82543()
218 mac->ops.reset_hw = e1000_reset_hw_82543; in e1000_init_mac_params_82543()
[all …]
H A De1000_82541.c224 struct e1000_mac_info *mac = &hw->mac; in e1000_init_mac_params_82541() local
231 mac->mta_reg_count = 128; in e1000_init_mac_params_82541()
233 mac->rar_entry_count = E1000_RAR_ENTRIES; in e1000_init_mac_params_82541()
235 mac->asf_firmware_present = true; in e1000_init_mac_params_82541()
240 mac->ops.get_bus_info = e1000_get_bus_info_pci_generic; in e1000_init_mac_params_82541()
242 mac->ops.set_lan_id = e1000_set_lan_id_single_port; in e1000_init_mac_params_82541()
244 mac->ops.reset_hw = e1000_reset_hw_82541; in e1000_init_mac_params_82541()
246 mac->ops.init_hw = e1000_init_hw_82541; in e1000_init_mac_params_82541()
248 mac->ops.setup_link = e1000_setup_link_generic; in e1000_init_mac_params_82541()
250 mac->ops.setup_physical_interface = e1000_setup_copper_link_82541; in e1000_init_mac_params_82541()
[all …]
/onnv-gate/usr/src/uts/common/io/igb/
H A Digb_mac.c49 struct e1000_mac_info *mac = &hw->mac; in e1000_init_mac_ops_generic() local
53 mac->ops.init_params = e1000_null_ops_generic; in e1000_init_mac_ops_generic()
54 mac->ops.init_hw = e1000_null_ops_generic; in e1000_init_mac_ops_generic()
55 mac->ops.reset_hw = e1000_null_ops_generic; in e1000_init_mac_ops_generic()
56 mac->ops.setup_physical_interface = e1000_null_ops_generic; in e1000_init_mac_ops_generic()
57 mac->ops.get_bus_info = e1000_null_ops_generic; in e1000_init_mac_ops_generic()
58 mac->ops.set_lan_id = e1000_set_lan_id_multi_port_pcie; in e1000_init_mac_ops_generic()
59 mac->ops.read_mac_addr = e1000_read_mac_addr_generic; in e1000_init_mac_ops_generic()
60 mac->ops.config_collision_dist = e1000_config_collision_dist_generic; in e1000_init_mac_ops_generic()
61 mac->ops.clear_hw_cntrs = e1000_null_mac_generic; in e1000_init_mac_ops_generic()
[all …]
H A Digb_api.c46 if (hw->mac.ops.init_params) { in e1000_init_mac_params()
47 ret_val = hw->mac.ops.init_params(hw); in e1000_init_mac_params()
127 struct e1000_mac_info *mac = &hw->mac; in e1000_set_mac_type() local
136 mac->type = e1000_82575; in e1000_set_mac_type()
145 mac->type = e1000_82576; in e1000_set_mac_type()
152 mac->type = e1000_82580; in e1000_set_mac_type()
206 switch (hw->mac.type) { in e1000_setup_init_funcs()
252 if (hw->mac.ops.get_bus_info) in e1000_get_bus_info()
253 return (hw->mac.ops.get_bus_info(hw)); in e1000_get_bus_info()
268 if (hw->mac.ops.clear_vfta) in e1000_clear_vfta()
[all …]
H A Digb_82575.c121 } else if (hw->mac.type == e1000_82580) { in e1000_init_phy_params_82575()
235 struct e1000_mac_info *mac = &hw->mac; in e1000_init_mac_params_82575() local
274 if ((ctrl_ext & E1000_CTRL_I2C_ENA) && (hw->mac.type == e1000_82580)) in e1000_init_mac_params_82575()
278 mac->mta_reg_count = 128; in e1000_init_mac_params_82575()
280 mac->uta_reg_count = (hw->mac.type == e1000_82575) ? 0 : 128; in e1000_init_mac_params_82575()
282 mac->rar_entry_count = E1000_RAR_ENTRIES_82575; in e1000_init_mac_params_82575()
283 if (mac->type == e1000_82576) in e1000_init_mac_params_82575()
284 mac->rar_entry_count = E1000_RAR_ENTRIES_82576; in e1000_init_mac_params_82575()
285 if (mac->type == e1000_82580) in e1000_init_mac_params_82575()
286 mac->rar_entry_count = E1000_RAR_ENTRIES_82580; in e1000_init_mac_params_82575()
[all …]
/onnv-gate/usr/src/cmd/checknr/
H A Dchecknr.c158 static void chkcmd(char *line, char *mac);
159 static void nomatch(char *mac);
162 static void checkknown(char *mac);
164 static void addmac(char *mac);
165 static int binsrch(char *mac);
281 char mac[5]; /* The current macro or nroff command */ in process() local
290 (void) strncpy(mac, line+1, 4); in process()
291 if (isspace(mac[0])) { in process()
294 } else if (isspace(mac[1])) { in process()
295 mac[1] = 0; in process()
[all …]
/onnv-gate/usr/src/common/openssl/crypto/pkcs12/
H A Dp12_mutl.c68 unsigned char *mac, unsigned int *maclen) in PKCS12_gen_mac() argument
81 salt = p12->mac->salt->data; in PKCS12_gen_mac()
82 saltlen = p12->mac->salt->length; in PKCS12_gen_mac()
83 if (!p12->mac->iter) iter = 1; in PKCS12_gen_mac()
84 else iter = ASN1_INTEGER_get (p12->mac->iter); in PKCS12_gen_mac()
86 EVP_get_digestbyobj (p12->mac->dinfo->algor->algorithm))) { in PKCS12_gen_mac()
99 HMAC_Final(&hmac, mac, maclen); in PKCS12_gen_mac()
107 unsigned char mac[EVP_MAX_MD_SIZE]; in PKCS12_verify_mac() local
109 if(p12->mac == NULL) { in PKCS12_verify_mac()
113 if (!PKCS12_gen_mac (p12, pass, passlen, mac, &maclen)) { in PKCS12_verify_mac()
[all …]
/onnv-gate/usr/src/uts/common/io/ixgbe/
H A Dixgbe_api.c63 switch (hw->mac.type) { in ixgbe_init_shared_code()
106 hw->mac.type = ixgbe_mac_82598EB; in ixgbe_set_mac_type()
117 hw->mac.type = ixgbe_mac_82599EB; in ixgbe_set_mac_type()
128 hw->mac.type, ret_val); in ixgbe_set_mac_type()
142 return ixgbe_call_func(hw, hw->mac.ops.init_hw, (hw), in ixgbe_init_hw()
156 return ixgbe_call_func(hw, hw->mac.ops.reset_hw, (hw), in ixgbe_reset_hw()
173 return ixgbe_call_func(hw, hw->mac.ops.start_hw, (hw), in ixgbe_start_hw()
188 if (hw->mac.ops.enable_relaxed_ordering) in ixgbe_enable_relaxed_ordering()
189 hw->mac.ops.enable_relaxed_ordering(hw); in ixgbe_enable_relaxed_ordering()
202 return ixgbe_call_func(hw, hw->mac.ops.clear_hw_cntrs, (hw), in ixgbe_clear_hw_cntrs()
[all …]
H A Dixgbe_82598.c128 if (hw->mac.msix_vectors_from_pcie) { in ixgbe_get_pcie_msix_count_82598()
152 struct ixgbe_mac_info *mac = &hw->mac; in ixgbe_init_ops_82598() local
165 mac->ops.start_hw = &ixgbe_start_hw_82598; in ixgbe_init_ops_82598()
166 mac->ops.enable_relaxed_ordering = &ixgbe_enable_relaxed_ordering_82598; in ixgbe_init_ops_82598()
167 mac->ops.reset_hw = &ixgbe_reset_hw_82598; in ixgbe_init_ops_82598()
168 mac->ops.get_media_type = &ixgbe_get_media_type_82598; in ixgbe_init_ops_82598()
169 mac->ops.get_supported_physical_layer = in ixgbe_init_ops_82598()
171 mac->ops.read_analog_reg8 = &ixgbe_read_analog_reg8_82598; in ixgbe_init_ops_82598()
172 mac->ops.write_analog_reg8 = &ixgbe_write_analog_reg8_82598; in ixgbe_init_ops_82598()
173 mac->ops.set_lan_id = &ixgbe_set_lan_id_multi_port_pcie_82598; in ixgbe_init_ops_82598()
[all …]
/onnv-gate/usr/src/lib/libpp/common/
H A Dppcontrol.c260 register struct ppmacro* mac; in ppcontrol() local
655 mac = sym->macro; in ppcontrol()
656 if ((pp.option & ALLPOSSIBLE) && !pp.in->prev->prev && mac->value) in ppcontrol()
660 old = *mac; in ppcontrol()
667 mac->arity = 0; in ppcontrol()
668 mac->formals = 0; in ppcontrol()
669 mac->value = 0; in ppcontrol()
681 p = mac->formals = oldof(0, char, 0, n); in ppcontrol()
684 if (mac->arity < MAXFORMALS) in ppcontrol()
686 if (mac->arity) p++; in ppcontrol()
[all …]
/onnv-gate/usr/src/uts/common/io/nxge/
H A Dnxge_hw.c103 nxgep->mac.is_jumbo = B_FALSE; in nxge_hw_id_init()
109 nxgep->mac.minframesize = NXGE_MIN_MAC_FRAMESIZE; /* 64 */ in nxge_hw_id_init()
110 nxgep->mac.maxframesize = NXGE_MAX_MAC_FRAMESIZE; /* 1522 */ in nxge_hw_id_init()
113 nxgep->mac.maxframesize)); in nxge_hw_id_init()
333 portn = nxgep->mac.portnum; in nxge_check_xaui_xfp()
364 } else if (nxgep->mac.portmode == PORT_10G_FIBER) { in nxge_check_xaui_xfp()
435 } else if (estat.bits.ldw.mac) { in nxge_syserr_intr()
493 if (nxgep->mac.portmode == PORT_10G_FIBER || in nxge_syserr_intr()
494 nxgep->mac.portmode == PORT_10G_COPPER || in nxge_syserr_intr()
495 nxgep->mac.portmode == PORT_10G_TN1010 || in nxge_syserr_intr()
[all …]

12345678910>>...16