Lines Matching +full:muti +full:- +full:function
1 /* SPDX-License-Identifier: GPL-2.0-only */
4 * Copyright (c) 2009-2013 QLogic Corporation
51 * 7:0 - major
52 * 15:8 - minor
53 * 31:16 - build (little endian)
65 (sizeof(struct rcv_desc) * (rds_ring)->num_desc)
67 (sizeof(struct qlcnic_rx_buffer) * rds_ring->num_desc)
69 (sizeof(struct status_desc) * (sds_ring)->num_desc)
71 (sizeof(struct qlcnic_cmd_buffer) * tx_ring->num_desc)
73 (sizeof(struct cmd_desc_type0) * tx_ring->num_desc)
100 /* Driver will use 1 Tx ring in INT-x/MSI/SRIOV mode. */
118 /* Virtual NIC function count */
129 /* Host writes the following to notify that it has done the init-handshake */
155 (((index) + 1) & ((length) - 1))
736 /* MUST BE 64-bit aligned.
738 - N hostrq_rds_rings
739 - N hostrq_sds_rings */
765 /* MUST BE 64-bit aligned.
767 - N cardrsp_rds_rings
768 - N cardrs_sds_rings */
884 * Driver --> Firmware
899 * Firmware --> Driver
961 * 63:58 - message type
962 * 57:56 - owner
963 * 55:53 - desc count
964 * 52:48 - reserved
965 * 47:40 - completion id
966 * 39:32 - opcode
967 * 31:16 - error code
968 * 15:00 - reserved
1029 ((adapter)->flags & (QLCNIC_MSI_ENABLED | QLCNIC_MSIX_ENABLED))
1031 ((adapter)->ahw->capabilities & QLCNIC_FW_CAPABILITY_TSO)
1261 __le16 id; /* pci function id */
1545 (adapter->ahw->hw_ops->read_reg)(adapter, off, err)
1548 adapter->ahw->hw_ops->write_reg(adapter, off, val)
1723 if (likely(tx_ring->producer < tx_ring->sw_consumer)) in qlcnic_tx_avail()
1724 return tx_ring->sw_consumer - tx_ring->producer; in qlcnic_tx_avail()
1726 return tx_ring->sw_consumer + tx_ring->num_desc - in qlcnic_tx_avail()
1727 tx_ring->producer; in qlcnic_tx_avail()
1831 return adapter->ahw->extra_capability[0] & in qlcnic_83xx_encap_tx_offload()
1837 return adapter->ahw->extra_capability[0] & in qlcnic_83xx_encap_rx_offload()
1853 return adapter->ahw->hw_ops->encap_rx_offload(adapter); in qlcnic_encap_rx_offload()
1858 return adapter->ahw->hw_ops->encap_tx_offload(adapter); in qlcnic_encap_tx_offload()
1863 return adapter->nic_ops->start_firmware(adapter); in qlcnic_start_firmware()
1869 adapter->ahw->hw_ops->read_crb(adapter, buf, offset, size); in qlcnic_read_crb()
1875 adapter->ahw->hw_ops->write_crb(adapter, buf, offset, size); in qlcnic_write_crb()
1879 u8 *mac, u8 function) in qlcnic_get_mac_address() argument
1881 return adapter->ahw->hw_ops->get_mac_address(adapter, mac, function); in qlcnic_get_mac_address()
1886 return adapter->ahw->hw_ops->setup_intr(adapter); in qlcnic_setup_intr()
1892 return adapter->ahw->hw_ops->alloc_mbx_args(mbx, adapter, arg); in qlcnic_alloc_mbx_args()
1898 if (adapter->ahw->hw_ops->mbx_cmd) in qlcnic_issue_cmd()
1899 return adapter->ahw->hw_ops->mbx_cmd(adapter, cmd); in qlcnic_issue_cmd()
1901 return -EIO; in qlcnic_issue_cmd()
1906 adapter->ahw->hw_ops->get_func_no(adapter); in qlcnic_get_func_no()
1911 return adapter->ahw->hw_ops->api_lock(adapter); in qlcnic_api_lock()
1916 adapter->ahw->hw_ops->api_unlock(adapter); in qlcnic_api_unlock()
1921 if (adapter->ahw->hw_ops->add_sysfs) in qlcnic_add_sysfs()
1922 adapter->ahw->hw_ops->add_sysfs(adapter); in qlcnic_add_sysfs()
1927 if (adapter->ahw->hw_ops->remove_sysfs) in qlcnic_remove_sysfs()
1928 adapter->ahw->hw_ops->remove_sysfs(adapter); in qlcnic_remove_sysfs()
1934 sds_ring->adapter->ahw->hw_ops->process_lb_rcv_ring_diag(sds_ring); in qlcnic_process_rcv_ring_diag()
1939 return adapter->ahw->hw_ops->create_rx_ctx(adapter); in qlcnic_fw_cmd_create_rx_ctx()
1946 return adapter->ahw->hw_ops->create_tx_ctx(adapter, ptr, ring); in qlcnic_fw_cmd_create_tx_ctx()
1951 return adapter->ahw->hw_ops->del_rx_ctx(adapter); in qlcnic_fw_cmd_del_rx_ctx()
1957 return adapter->ahw->hw_ops->del_tx_ctx(adapter, ptr); in qlcnic_fw_cmd_del_tx_ctx()
1963 return adapter->ahw->hw_ops->setup_link_event(adapter, enable); in qlcnic_linkevent_request()
1969 return adapter->ahw->hw_ops->get_nic_info(adapter, info, id); in qlcnic_get_nic_info()
1975 return adapter->ahw->hw_ops->get_pci_info(adapter, info); in qlcnic_get_pci_info()
1981 return adapter->ahw->hw_ops->set_nic_info(adapter, info); in qlcnic_set_nic_info()
1987 return adapter->ahw->hw_ops->change_macvlan(adapter, addr, id, cmd); in qlcnic_sre_macaddr_change()
1993 return adapter->nic_ops->napi_add(adapter, netdev); in qlcnic_napi_add()
1998 adapter->nic_ops->napi_del(adapter); in qlcnic_napi_del()
2003 adapter->ahw->hw_ops->napi_enable(adapter); in qlcnic_napi_enable()
2010 return adapter->nic_ops->shutdown(pdev); in __qlcnic_shutdown()
2015 return adapter->nic_ops->resume(adapter); in __qlcnic_resume()
2020 adapter->ahw->hw_ops->napi_disable(adapter); in qlcnic_napi_disable()
2026 return adapter->ahw->hw_ops->config_intr_coal(adapter, ethcoal); in qlcnic_config_intr_coalesce()
2031 return adapter->ahw->hw_ops->config_rss(adapter, enable); in qlcnic_config_rss()
2037 return adapter->ahw->hw_ops->config_hw_lro(adapter, enable); in qlcnic_config_hw_lro()
2042 return adapter->ahw->hw_ops->config_loopback(adapter, mode); in qlcnic_set_lb_mode()
2047 return adapter->ahw->hw_ops->clear_loopback(adapter, mode); in qlcnic_clear_lb_mode()
2053 return adapter->ahw->hw_ops->config_promisc_mode(adapter, mode); in qlcnic_nic_set_promisc()
2060 adapter->ahw->hw_ops->change_l2_filter(adapter, addr, vlan, tx_ring); in qlcnic_change_filter()
2065 return adapter->ahw->hw_ops->get_board_info(adapter); in qlcnic_get_board_info()
2070 return adapter->ahw->hw_ops->free_mac_list(adapter); in qlcnic_free_mac_list()
2075 if (adapter->ahw->hw_ops->set_mac_filter_count) in qlcnic_set_mac_filter_count()
2076 adapter->ahw->hw_ops->set_mac_filter_count(adapter); in qlcnic_set_mac_filter_count()
2081 adapter->ahw->hw_ops->get_beacon_state(adapter); in qlcnic_get_beacon_state()
2086 if (adapter->ahw->hw_ops->read_phys_port_id) in qlcnic_read_phys_port_id()
2087 adapter->ahw->hw_ops->read_phys_port_id(adapter); in qlcnic_read_phys_port_id()
2093 return adapter->ahw->hw_ops->get_saved_state(t_hdr, index); in qlcnic_get_saved_state()
2099 adapter->ahw->hw_ops->set_saved_state(t_hdr, index, value); in qlcnic_set_saved_state()
2105 adapter->ahw->hw_ops->cache_tmpl_hdr_values(fw_dump); in qlcnic_cache_tmpl_hdr_values()
2111 return adapter->ahw->hw_ops->get_cap_size(tmpl_hdr, index); in qlcnic_get_cap_size()
2117 adapter->ahw->hw_ops->set_sys_info(tmpl_hdr, idx, value); in qlcnic_set_sys_info()
2123 adapter->ahw->hw_ops->store_cap_mask(tmpl_hdr, mask); in qlcnic_store_cap_mask()
2129 if (adapter->nic_ops->request_reset) in qlcnic_dev_request_reset()
2130 adapter->nic_ops->request_reset(adapter, key); in qlcnic_dev_request_reset()
2135 if (adapter->nic_ops->cancel_idc_work) in qlcnic_cancel_idc_work()
2136 adapter->nic_ops->cancel_idc_work(adapter); in qlcnic_cancel_idc_work()
2142 return adapter->nic_ops->clear_legacy_intr(adapter); in qlcnic_clear_legacy_intr()
2148 return adapter->nic_ops->config_led(adapter, state, rate); in qlcnic_config_led()
2154 adapter->nic_ops->config_ipaddr(adapter, ip, cmd); in qlcnic_config_ipaddr()
2159 return test_bit(__QLCNIC_MULTI_TX_UNIQUE, &adapter->state); in qlcnic_check_multi_tx()
2167 !adapter->ahw->diag_test) in qlcnic_82xx_enable_tx_intr()
2168 writel(0x0, tx_ring->crb_intr_mask); in qlcnic_82xx_enable_tx_intr()
2176 !adapter->ahw->diag_test) in qlcnic_82xx_disable_tx_intr()
2177 writel(1, tx_ring->crb_intr_mask); in qlcnic_82xx_disable_tx_intr()
2184 writel(0, tx_ring->crb_intr_mask); in qlcnic_83xx_enable_tx_intr()
2191 writel(1, tx_ring->crb_intr_mask); in qlcnic_83xx_disable_tx_intr()
2194 /* Enable MSI-x and INT-x interrupts */
2199 writel(0, sds_ring->crb_intr_mask); in qlcnic_83xx_enable_sds_intr()
2202 /* Disable MSI-x and INT-x interrupts */
2207 writel(1, sds_ring->crb_intr_mask); in qlcnic_83xx_disable_sds_intr()
2212 test_and_clear_bit(__QLCNIC_MULTI_TX_UNIQUE, &adapter->state); in qlcnic_disable_multi_tx()
2213 adapter->drv_tx_rings = QLCNIC_SINGLE_RING; in qlcnic_disable_multi_tx()
2216 /* When operating in a muti tx mode, driver needs to write 0x1
2224 !adapter->ahw->diag_test && in qlcnic_82xx_disable_sds_intr()
2225 (adapter->flags & QLCNIC_MSIX_ENABLED)) in qlcnic_82xx_disable_sds_intr()
2226 writel(0x1, sds_ring->crb_intr_mask); in qlcnic_82xx_disable_sds_intr()
2228 writel(0, sds_ring->crb_intr_mask); in qlcnic_82xx_disable_sds_intr()
2234 if (adapter->ahw->hw_ops->enable_sds_intr) in qlcnic_enable_sds_intr()
2235 adapter->ahw->hw_ops->enable_sds_intr(adapter, sds_ring); in qlcnic_enable_sds_intr()
2242 if (adapter->ahw->hw_ops->disable_sds_intr) in qlcnic_disable_sds_intr()
2243 adapter->ahw->hw_ops->disable_sds_intr(adapter, sds_ring); in qlcnic_disable_sds_intr()
2249 if (adapter->ahw->hw_ops->enable_tx_intr) in qlcnic_enable_tx_intr()
2250 adapter->ahw->hw_ops->enable_tx_intr(adapter, tx_ring); in qlcnic_enable_tx_intr()
2256 if (adapter->ahw->hw_ops->disable_tx_intr) in qlcnic_disable_tx_intr()
2257 adapter->ahw->hw_ops->disable_tx_intr(adapter, tx_ring); in qlcnic_disable_tx_intr()
2260 /* When operating in a muti tx mode, driver needs to write 0x0
2268 !adapter->ahw->diag_test && in qlcnic_82xx_enable_sds_intr()
2269 (adapter->flags & QLCNIC_MSIX_ENABLED)) in qlcnic_82xx_enable_sds_intr()
2270 writel(0, sds_ring->crb_intr_mask); in qlcnic_82xx_enable_sds_intr()
2272 writel(0x1, sds_ring->crb_intr_mask); in qlcnic_82xx_enable_sds_intr()
2275 writel(0xfbff, adapter->tgt_mask_reg); in qlcnic_82xx_enable_sds_intr()
2280 return test_and_set_bit(__QLCNIC_DIAG_MODE, &adapter->state); in qlcnic_get_diag_lock()
2285 clear_bit(__QLCNIC_DIAG_MODE, &adapter->state); in qlcnic_release_diag_lock()
2290 return test_bit(__QLCNIC_DIAG_MODE, &adapter->state); in qlcnic_check_diag_status()
2298 if (NETIF_MSG_##lvl & adapter->ahw->msg_enable) \
2300 dev_name(&adapter->pdev->dev), \
2314 unsigned short device = adapter->pdev->device; in qlcnic_82xx_check()
2320 unsigned short device = adapter->pdev->device; in qlcnic_84xx_check()
2328 unsigned short device = adapter->pdev->device; in qlcnic_83xx_check()
2343 return (adapter->ahw->op_mode == QLCNIC_SRIOV_PF_FUNC) ? true : false; in qlcnic_sriov_pf_check()
2348 unsigned short device = adapter->pdev->device; in qlcnic_sriov_vf_check()
2360 unsigned short device = adapter->pdev->device; in qlcnic_83xx_pf_check()
2367 unsigned short device = adapter->pdev->device; in qlcnic_83xx_vf_check()