Home
last modified time | relevance | path

Searched refs:ahw (Results 1 – 22 of 22) sorted by relevance

/drivers/net/ethernet/qlogic/qlcnic/
Dqlcnic_83xx_vnic.c17 QLCWRX(adapter->ahw, QLC_83XX_VNIC_STATE, QLCNIC_DEV_NPAR_OPER); in qlcnic_83xx_enable_vnic_mode()
26 struct qlcnic_hardware_context *ahw = adapter->ahw; in qlcnic_83xx_disable_vnic_mode() local
33 QLCWRX(adapter->ahw, QLC_83XX_VNIC_STATE, QLCNIC_DEV_NPAR_NON_OPER); in qlcnic_83xx_disable_vnic_mode()
34 ahw->idc.vnic_state = QLCNIC_DEV_NPAR_NON_OPER; in qlcnic_83xx_disable_vnic_mode()
47 struct qlcnic_hardware_context *ahw = adapter->ahw; in qlcnic_83xx_set_vnic_opmode() local
52 id = ahw->pci_func; in qlcnic_83xx_set_vnic_opmode()
53 data = QLCRDX(adapter->ahw, QLC_83XX_DRV_OP_MODE); in qlcnic_83xx_set_vnic_opmode()
57 QLCWRX(adapter->ahw, QLC_83XX_DRV_OP_MODE, data); in qlcnic_83xx_set_vnic_opmode()
67 struct qlcnic_hardware_context *ahw = adapter->ahw; in qlcnic_83xx_config_vnic_buff_descriptors() local
69 if (ahw->port_type == QLCNIC_XGBE) { in qlcnic_83xx_config_vnic_buff_descriptors()
[all …]
Dqlcnic_83xx_init.c137 val = QLCRDX(adapter->ahw, QLC_83XX_IDC_DRV_PRESENCE); in qlcnic_83xx_idc_check_driver_presence_reg()
147 cur = adapter->ahw->idc.curr_state; in qlcnic_83xx_idc_log_state_history()
148 prev = adapter->ahw->idc.prev_state; in qlcnic_83xx_idc_log_state_history()
152 adapter->ahw->idc.name[cur], in qlcnic_83xx_idc_log_state_history()
153 adapter->ahw->idc.name[prev]); in qlcnic_83xx_idc_log_state_history()
167 val = QLCRDX(adapter->ahw, QLC_83XX_IDC_DRV_AUDIT); in qlcnic_83xx_idc_update_audit_reg()
171 seconds = jiffies / HZ - adapter->ahw->idc.sec_counter; in qlcnic_83xx_idc_update_audit_reg()
176 QLCWRX(adapter->ahw, QLC_83XX_IDC_DRV_AUDIT, val); in qlcnic_83xx_idc_update_audit_reg()
177 adapter->ahw->idc.sec_counter = jiffies / HZ; in qlcnic_83xx_idc_update_audit_reg()
189 val = QLCRDX(adapter->ahw, QLC_83XX_IDC_MIN_VERSION); in qlcnic_83xx_idc_update_minor_version()
[all …]
Dqlcnic_83xx_hw.c260 void qlcnic_83xx_register_map(struct qlcnic_hardware_context *ahw) in qlcnic_83xx_register_map() argument
262 ahw->hw_ops = &qlcnic_83xx_hw_ops; in qlcnic_83xx_register_map()
263 ahw->reg_tbl = (u32 *)qlcnic_83xx_reg_tbl; in qlcnic_83xx_register_map()
264 ahw->ext_reg_tbl = (u32 *)qlcnic_83xx_ext_reg_tbl; in qlcnic_83xx_register_map()
288 base = adapter->ahw->pci_base0 + in __qlcnic_set_win_base()
289 QLC_83XX_CRB_WIN_FUNC(adapter->ahw->pci_func); in __qlcnic_set_win_base()
301 struct qlcnic_hardware_context *ahw = adapter->ahw; in qlcnic_83xx_rd_reg_indirect() local
305 return QLCRDX(ahw, QLCNIC_WILDCARD); in qlcnic_83xx_rd_reg_indirect()
317 struct qlcnic_hardware_context *ahw = adapter->ahw; in qlcnic_83xx_wrt_reg_indirect() local
321 QLCWRX(ahw, QLCNIC_WILDCARD, data); in qlcnic_83xx_wrt_reg_indirect()
[all …]
Dqlcnic_main.c95 struct qlcnic_hardware_context *ahw = adapter->ahw; in qlcnic_vlan_tx_check() local
98 return ahw->capabilities & QLCNIC_FW_CAPABILITY_FVLANTX; in qlcnic_vlan_tx_check()
307 adapter->ahw->pci_func); in qlcnic_read_mac_addr()
420 if (netdev_uc_count(netdev) < adapter->ahw->max_uc_count) in qlcnic_fdb_add()
465 struct qlcnic_hardware_context *ahw = adapter->ahw; in qlcnic_get_phys_port_id() local
470 ppid->id_len = sizeof(ahw->phys_port_id); in qlcnic_get_phys_port_id()
471 memcpy(ppid->id, ahw->phys_port_id, ppid->id_len); in qlcnic_get_phys_port_id()
480 struct qlcnic_hardware_context *ahw = adapter->ahw; in qlcnic_add_vxlan_port() local
490 if (!ahw->vxlan_port_count) { in qlcnic_add_vxlan_port()
491 ahw->vxlan_port_count = 1; in qlcnic_add_vxlan_port()
[all …]
Dqlcnic_sriov_common.c155 adapter->ahw->sriov = sriov; in qlcnic_sriov_init()
232 kfree(adapter->ahw->sriov); in qlcnic_sriov_init()
260 struct qlcnic_sriov *sriov = adapter->ahw->sriov; in __qlcnic_sriov_cleanup()
284 kfree(adapter->ahw->sriov); in __qlcnic_sriov_cleanup()
311 struct qlcnic_hardware_context *ahw = adapter->ahw; in qlcnic_sriov_post_bc_msg() local
312 struct qlcnic_mailbox *mbx = ahw->mailbox; in qlcnic_sriov_post_bc_msg()
329 __func__, cmd.cmd_op, cmd.type, ahw->pci_func, in qlcnic_sriov_post_bc_msg()
330 ahw->op_mode); in qlcnic_sriov_post_bc_msg()
337 __func__, cmd.cmd_op, cmd.type, ahw->pci_func, in qlcnic_sriov_post_bc_msg()
338 ahw->op_mode); in qlcnic_sriov_post_bc_msg()
[all …]
Dqlcnic_ethtool.c291 struct qlcnic_hardware_context *ahw = adapter->ahw; in qlcnic_82xx_get_settings() local
294 u16 pcifn = ahw->pci_func; in qlcnic_82xx_get_settings()
297 if (adapter->ahw->port_type == QLCNIC_GBE) { in qlcnic_82xx_get_settings()
310 ethtool_cmd_speed_set(ecmd, adapter->ahw->link_speed); in qlcnic_82xx_get_settings()
311 ecmd->duplex = adapter->ahw->link_duplex; in qlcnic_82xx_get_settings()
312 ecmd->autoneg = adapter->ahw->link_autoneg; in qlcnic_82xx_get_settings()
314 } else if (adapter->ahw->port_type == QLCNIC_XGBE) { in qlcnic_82xx_get_settings()
326 if (netif_running(adapter->netdev) && ahw->has_link_events) { in qlcnic_82xx_get_settings()
327 if (ahw->linkup) { in qlcnic_82xx_get_settings()
331 ahw->link_speed = speed * P3P_LINK_SPEED_MHZ; in qlcnic_82xx_get_settings()
[all …]
Dqlcnic_ctx.c46 static inline u32 qlcnic_get_cmd_signature(struct qlcnic_hardware_context *ahw) in qlcnic_get_cmd_signature() argument
48 return (ahw->pci_func & 0xff) | ((ahw->fw_hal_version & 0xff) << 8) | in qlcnic_get_cmd_signature()
118 struct qlcnic_hardware_context *ahw = adapter->ahw; in qlcnic_82xx_issue_cmd() local
121 signature = qlcnic_get_cmd_signature(ahw); in qlcnic_82xx_issue_cmd()
237 struct qlcnic_hardware_context *ahw = adapter->ahw; in qlcnic_82xx_fw_cmd_create_rx_ctx() local
287 !adapter->ahw->diag_test) { in qlcnic_82xx_fw_cmd_create_rx_ctx()
331 !adapter->ahw->diag_test) in qlcnic_82xx_fw_cmd_create_rx_ctx()
332 prq_sds[i].msi_index = cpu_to_le16(ahw->intr_tbl[i].id); in qlcnic_82xx_fw_cmd_create_rx_ctx()
358 rds_ring->crb_rcv_producer = ahw->pci_base0 + reg; in qlcnic_82xx_fw_cmd_create_rx_ctx()
367 if (qlcnic_check_multi_tx(adapter) && !adapter->ahw->diag_test) in qlcnic_82xx_fw_cmd_create_rx_ctx()
[all …]
Dqlcnic_hw.c367 qlcnic_read_window_reg(addr, adapter->ahw->pci_base0, &data); in qlcnic_ind_rd()
381 qlcnic_write_window_reg(addr, adapter->ahw->pci_base0, data); in qlcnic_ind_wr()
543 struct qlcnic_hardware_context *ahw = adapter->ahw; in __qlcnic_set_multi() local
561 (netdev_mc_count(netdev) > ahw->max_mc_count)) { in __qlcnic_set_multi()
573 if (netdev_uc_count(netdev) > ahw->max_uc_count) { in __qlcnic_set_multi()
770 adapter->ahw->physical_port); in qlcnic_82xx_read_phys_port_id()
774 memcpy(adapter->ahw->phys_port_id, mac, ETH_ALEN); in qlcnic_82xx_read_phys_port_id()
792 req.words[0] = cpu_to_le64(((u64) adapter->ahw->coal.flag) << 32); in qlcnic_82xx_set_rx_coalesce()
793 req.words[2] = cpu_to_le64(adapter->ahw->coal.rx_packets | in qlcnic_82xx_set_rx_coalesce()
794 ((u64) adapter->ahw->coal.rx_time_us) << 16); in qlcnic_82xx_set_rx_coalesce()
[all …]
Dqlcnic.h1037 ((adapter)->ahw->capabilities & QLCNIC_FW_CAPABILITY_TSO)
1106 struct qlcnic_hardware_context *ahw; member
1551 (adapter->ahw->hw_ops->read_reg)(adapter, off, err)
1554 adapter->ahw->hw_ops->write_reg(adapter, off, val)
1833 return adapter->ahw->extra_capability[0] & in qlcnic_encap_tx_offload()
1839 return adapter->ahw->extra_capability[0] & in qlcnic_encap_rx_offload()
1851 adapter->ahw->hw_ops->read_crb(adapter, buf, offset, size); in qlcnic_read_crb()
1857 adapter->ahw->hw_ops->write_crb(adapter, buf, offset, size); in qlcnic_write_crb()
1863 return adapter->ahw->hw_ops->write_reg(adapter, off, data); in qlcnic_hw_write_wx_2M()
1869 return adapter->ahw->hw_ops->get_mac_address(adapter, mac, function); in qlcnic_get_mac_address()
[all …]
Dqlcnic_sysfs.c44 if (!(adapter->ahw->capabilities & QLCNIC_FW_CAPABILITY_BDG)) in qlcnic_store_bridged_mode()
67 if (adapter->ahw->capabilities & QLCNIC_FW_CAPABILITY_BDG) in qlcnic_show_bridged_mode()
120 struct qlcnic_hardware_context *ahw = adapter->ahw; in qlcnic_83xx_store_beacon() local
132 if (ahw->beacon_state == h_beacon) in qlcnic_83xx_store_beacon()
136 if (!ahw->beacon_state) { in qlcnic_83xx_store_beacon()
148 ahw->beacon_state = h_beacon; in qlcnic_83xx_store_beacon()
150 if (!ahw->beacon_state) in qlcnic_83xx_store_beacon()
160 struct qlcnic_hardware_context *ahw = adapter->ahw; in qlcnic_82xx_store_beacon() local
175 if (ahw->beacon_state == b_state) in qlcnic_82xx_store_beacon()
179 if (!ahw->beacon_state) { in qlcnic_82xx_store_beacon()
[all …]
Dqlcnic_hw.h40 readl(((a)->ahw->pci_base0) + ((a)->ahw->reg_tbl[addr]))
44 writel(value, ((a)->ahw->pci_base0) + ((a)->ahw->reg_tbl[addr]))
47 #define QLCRDX(ahw, addr) \ argument
48 readl(((ahw)->pci_base0) + ((ahw)->ext_reg_tbl[addr]))
51 #define QLCWRX(ahw, addr, value) \ argument
52 writel(value, (((ahw)->pci_base0) + ((ahw)->ext_reg_tbl[addr])))
Dqlcnic_sriov_pf.c71 struct qlcnic_sriov *sriov = adapter->ahw->sriov; in qlcnic_sriov_pf_cal_res_limit()
92 if (adapter->ahw->pci_func == func) { in qlcnic_sriov_pf_cal_res_limit()
140 struct qlcnic_resources *ff_max = &adapter->ahw->sriov->ff_max; in qlcnic_sriov_pf_set_ff_max_res()
159 struct qlcnic_sriov *sriov = adapter->ahw->sriov; in qlcnic_sriov_set_vf_max_vlan()
236 struct qlcnic_sriov *sriov = adapter->ahw->sriov; in qlcnic_sriov_pf_reset_vport_handle()
240 if (adapter->ahw->pci_func == func) { in qlcnic_sriov_pf_reset_vport_handle()
254 struct qlcnic_sriov *sriov = adapter->ahw->sriov; in qlcnic_sriov_pf_set_vport_handle()
258 if (adapter->ahw->pci_func == func) { in qlcnic_sriov_pf_set_vport_handle()
272 struct qlcnic_sriov *sriov = adapter->ahw->sriov; in qlcnic_sriov_pf_get_vport_handle()
276 if (adapter->ahw->pci_func == func) { in qlcnic_sriov_pf_get_vport_handle()
[all …]
Dqlcnic_minidump.c406 void *hdr = adapter->ahw->fw_dump.tmpl_hdr; in qlcnic_dump_ctrl()
550 addr = adapter->ahw->pci_base0 + ocm->read_addr; in qlcnic_dump_ocm()
576 adapter->ahw->pci_func); in qlcnic_read_rom()
679 mutex_lock(&adapter->ahw->mem_lock); in qlcnic_read_memory_test_agent()
708 mutex_unlock(&adapter->ahw->mem_lock); in qlcnic_read_memory_test_agent()
728 tmpl_hdr = adapter->ahw->fw_dump.tmpl_hdr; in qlcnic_start_pex_dma()
771 struct qlcnic_fw_dump *fw_dump = &adapter->ahw->fw_dump; in qlcnic_read_memory_pexdma()
811 temp |= (adapter->ahw->pci_func & 0xf) << 4; in qlcnic_read_memory_pexdma()
857 struct qlcnic_fw_dump *fw_dump = &adapter->ahw->fw_dump; in qlcnic_read_memory()
1208 struct qlcnic_hardware_context *ahw; in qlcnic_fw_cmd_get_minidump_temp() local
[all …]
Dqlcnic_init.c216 if (adapter->ahw->capabilities & in qlcnic_alloc_sw_resources()
250 !adapter->ahw->diag_test) in qlcnic_alloc_sw_resources()
635 adapter->ahw->physical_port = (val >> 2); in qlcnic_setup_idc_param()
706 if (adapter->ahw->revision_id == QLCNIC_P3P_C0) in qlcnic_check_flash_fw_ver()
889 u8 chiprev = adapter->ahw->revision_id; in qlcnic_validate_product_offs()
976 if (adapter->ahw->fw_type == QLCNIC_UNIFIED_ROMIMAGE) in qlcnic_get_bootld_offs()
990 if (adapter->ahw->fw_type == QLCNIC_UNIFIED_ROMIMAGE) in qlcnic_get_fw_offs()
1004 if (adapter->ahw->fw_type == QLCNIC_UNIFIED_ROMIMAGE) in qlcnic_get_fw_size()
1019 if (adapter->ahw->fw_type != QLCNIC_UNIFIED_ROMIMAGE) { in qlcnic_get_fw_version()
1050 if (adapter->ahw->fw_type != QLCNIC_UNIFIED_ROMIMAGE) { in qlcnic_get_bios_version()
[all …]
Dqlcnic_io.c792 if (adapter->ahw->linkup && !linkup) { in qlcnic_advert_link_change()
794 adapter->ahw->linkup = 0; in qlcnic_advert_link_change()
796 } else if (!adapter->ahw->linkup && linkup) { in qlcnic_advert_link_change()
797 adapter->ahw->linkup = 1; in qlcnic_advert_link_change()
802 if (qlcnic_83xx_check(adapter) && adapter->ahw->lb_mode) { in qlcnic_advert_link_change()
1038 adapter->ahw->has_link_events = 1; in qlcnic_handle_linkevent()
1060 adapter->ahw->loopback_state |= QLCNIC_LINKEVENT; in qlcnic_handle_linkevent()
1065 adapter->ahw->link_duplex = DUPLEX_FULL; in qlcnic_handle_linkevent()
1067 adapter->ahw->link_duplex = DUPLEX_HALF; in qlcnic_handle_linkevent()
1069 adapter->ahw->module_type = module; in qlcnic_handle_linkevent()
[all …]
Dqlcnic_83xx_hw.h351 #define QLCNIC_MBX_HOST(ahw, i) ((ahw)->pci_base0 + ((i) * 4)) argument
352 #define QLCNIC_MBX_FW(ahw, i) ((ahw)->pci_base0 + 0x800 + ((i) * 4)) argument
/drivers/net/ethernet/qlogic/netxen/
Dnetxen_nic_hw.c63 ((adapter)->ahw.pci_base0 + (off))
65 ((adapter)->ahw.pci_base1 + (off) - SECOND_PAGE_GROUP_START)
67 ((adapter)->ahw.pci_base2 + (off) - THIRD_PAGE_GROUP_START)
349 if (NX_IS_REVISION_P2(adapter->ahw.revision_id)) { in netxen_niu_xg_init_port()
363 if (NX_IS_REVISION_P3(adapter->ahw.revision_id)) in netxen_niu_disable_xg_port()
391 u16 board_type = adapter->ahw.board_type; in netxen_p2_nic_set_promisc()
993 if (NX_IS_REVISION_P3(adapter->ahw.revision_id)) in netxen_nic_change_mtu()
1071 int pci_func = adapter->ahw.pci_func; in netxen_p3_get_mac_addr()
1096 u8 func = adapter->ahw.pci_func; in netxen_nic_pci_set_crbwindow_128M()
1098 if (adapter->ahw.crb_win == window) in netxen_nic_pci_set_crbwindow_128M()
[all …]
Dnetxen_nic_main.c256 if (NX_IS_REVISION_P2(adapter->ahw.revision_id)) { in nx_set_dma_mask()
288 if (NX_IS_REVISION_P3(adapter->ahw.revision_id) && (shift > 9)) in nx_update_dma_mask()
290 else if ((adapter->ahw.revision_id == NX_P2_C1) && (shift <= 4)) in nx_update_dma_mask()
303 if (NX_IS_REVISION_P3(adapter->ahw.revision_id)) { in nx_update_dma_mask()
329 if (!NX_IS_REVISION_P2(adapter->ahw.revision_id)) in netxen_check_hw_init()
368 val = adapter->ahw.board_type; in netxen_set_port_mode()
431 if (adapter->ahw.revision_id == NX_P3_B0) in netxen_pcie_strap_init()
486 if (NX_IS_REVISION_P3(adapter->ahw.revision_id)) { in netxen_read_mac_addr()
611 if (adapter->ahw.revision_id >= NX_P3_B0) in netxen_initialize_interrupt_registers()
612 legacy_intrp = &legacy_intr[adapter->ahw.pci_func]; in netxen_initialize_interrupt_registers()
[all …]
Dnetxen_nic_ethtool.c105 if (adapter->ahw.port_type == NETXEN_NIC_GBE) { in netxen_nic_get_settings()
124 } else if (adapter->ahw.port_type == NETXEN_NIC_XGBE) { in netxen_nic_get_settings()
145 if (NX_IS_REVISION_P3(adapter->ahw.revision_id)) { in netxen_nic_get_settings()
146 u16 pcifn = adapter->ahw.pci_func; in netxen_nic_get_settings()
163 switch (adapter->ahw.board_type) { in netxen_nic_get_settings()
179 ecmd->autoneg = (adapter->ahw.board_type == in netxen_nic_get_settings()
208 if (adapter->ahw.port_type == NETXEN_NIC_XGBE) { in netxen_nic_get_settings()
225 adapter->ahw.board_type); in netxen_nic_get_settings()
247 if (!netif_running(dev) || !adapter->ahw.linkup) { in netxen_nic_get_settings()
262 if (adapter->ahw.port_type != NETXEN_NIC_GBE) in netxen_nic_set_settings()
[all …]
Dnetxen_nic_init.c235 if (adapter->ahw.cut_through) { in netxen_alloc_sw_resources()
241 if (NX_IS_REVISION_P3(adapter->ahw.revision_id)) in netxen_alloc_sw_resources()
254 if (NX_IS_REVISION_P3(adapter->ahw.revision_id)) in netxen_alloc_sw_resources()
445 if (NX_IS_REVISION_P3(adapter->ahw.revision_id)) { in netxen_pinit_from_rom()
505 if (NX_IS_REVISION_P3(adapter->ahw.revision_id)) { in netxen_pinit_from_rom()
522 !NX_IS_REVISION_P3P(adapter->ahw.revision_id)) in netxen_pinit_from_rom()
538 if (NX_IS_REVISION_P2(adapter->ahw.revision_id)) { in netxen_pinit_from_rom()
554 if (NX_IS_REVISION_P2(adapter->ahw.revision_id)) { in netxen_pinit_from_rom()
702 int mn_present = (NX_IS_REVISION_P2(adapter->ahw.revision_id)) ? in netxen_nic_validate_product_offs()
724 u8 chiprev = adapter->ahw.revision_id; in netxen_nic_validate_product_offs()
[all …]
Dnetxen_nic_ctx.c55 signature = NX_CDRP_SIGNATURE_MAKE(adapter->ahw.pci_func, in netxen_issue_cmd()
815 if (NX_IS_REVISION_P2(adapter->ahw.revision_id)) in netxen_alloc_hw_resources()
836 if (NX_IS_REVISION_P2(adapter->ahw.revision_id)) { in netxen_alloc_hw_resources()
848 if (!NX_IS_REVISION_P2(adapter->ahw.revision_id)) { in netxen_alloc_hw_resources()
881 if (!NX_IS_REVISION_P2(adapter->ahw.revision_id)) { in netxen_free_hw_resources()
Dnetxen_nic.h110 (adapter->ahw.db_base + (off))
1601 struct netxen_hardware_context ahw; member