Lines Matching refs:p_hwfn

135 static int qed_sp_vport_start(struct qed_hwfn *p_hwfn,  in qed_sp_vport_start()  argument
150 rc = qed_fw_vport(p_hwfn, vport_id, &abs_vport_id); in qed_sp_vport_start()
158 rc = qed_sp_init_request(p_hwfn, &p_ent, in qed_sp_vport_start()
159 qed_spq_get_cid(p_hwfn), in qed_sp_vport_start()
184 p_ramrod->sw_fid = qed_concrete_to_sw_fid(p_hwfn->cdev, in qed_sp_vport_start()
187 return qed_spq_post(p_hwfn, p_ent, NULL); in qed_sp_vport_start()
191 qed_sp_vport_update_rss(struct qed_hwfn *p_hwfn, in qed_sp_vport_update_rss() argument
207 rc = qed_fw_rss_eng(p_hwfn, p_params->rss_eng_id, &rss->rss_id); in qed_sp_vport_update_rss()
242 DP_VERBOSE(p_hwfn, NETIF_MSG_IFUP, in qed_sp_vport_update_rss()
250 rc = qed_fw_l2_queue(p_hwfn, in qed_sp_vport_update_rss()
257 DP_VERBOSE(p_hwfn, NETIF_MSG_IFUP, "i= %d, queue = %d\n", in qed_sp_vport_update_rss()
268 qed_sp_update_accept_mode(struct qed_hwfn *p_hwfn, in qed_sp_update_accept_mode() argument
302 DP_VERBOSE(p_hwfn, QED_MSG_SP, in qed_sp_update_accept_mode()
329 DP_VERBOSE(p_hwfn, QED_MSG_SP, in qed_sp_update_accept_mode()
335 qed_sp_update_mcast_bin(struct qed_hwfn *p_hwfn, in qed_sp_update_mcast_bin() argument
356 qed_sp_vport_update(struct qed_hwfn *p_hwfn, in qed_sp_vport_update() argument
369 rc = qed_fw_vport(p_hwfn, p_params->vport_id, &abs_vport_id); in qed_sp_vport_update()
378 rc = qed_sp_init_request(p_hwfn, &p_ent, in qed_sp_vport_update()
379 qed_spq_get_cid(p_hwfn), in qed_sp_vport_update()
397 rc = qed_sp_vport_update_rss(p_hwfn, p_ramrod, p_rss_params); in qed_sp_vport_update()
400 qed_spq_return_entry(p_hwfn, p_ent); in qed_sp_vport_update()
405 qed_sp_update_mcast_bin(p_hwfn, p_ramrod, p_params); in qed_sp_vport_update()
407 qed_sp_update_accept_mode(p_hwfn, p_ramrod, p_params->accept_flags); in qed_sp_vport_update()
408 return qed_spq_post(p_hwfn, p_ent, NULL); in qed_sp_vport_update()
411 static int qed_sp_vport_stop(struct qed_hwfn *p_hwfn, in qed_sp_vport_stop() argument
421 rc = qed_fw_vport(p_hwfn, vport_id, &abs_vport_id); in qed_sp_vport_stop()
429 rc = qed_sp_init_request(p_hwfn, &p_ent, in qed_sp_vport_stop()
430 qed_spq_get_cid(p_hwfn), in qed_sp_vport_stop()
441 return qed_spq_post(p_hwfn, p_ent, NULL); in qed_sp_vport_stop()
459 struct qed_hwfn *p_hwfn = &cdev->hwfns[i]; in qed_filter_accept_cmd() local
461 vport_update_params.opaque_fid = p_hwfn->hw_info.opaque_fid; in qed_filter_accept_cmd()
463 rc = qed_sp_vport_update(p_hwfn, &vport_update_params, in qed_filter_accept_cmd()
470 DP_VERBOSE(p_hwfn, QED_MSG_SP, in qed_filter_accept_cmd()
480 struct qed_hwfn *p_hwfn, in qed_sp_release_queue_cid() argument
486 qed_cxt_release_cid(p_hwfn, p_cid_data->cid); in qed_sp_release_queue_cid()
494 qed_sp_eth_rxq_start_ramrod(struct qed_hwfn *p_hwfn, in qed_sp_eth_rxq_start_ramrod() argument
513 p_rx_cid = &p_hwfn->p_rx_cids[params->queue_id]; in qed_sp_eth_rxq_start_ramrod()
518 rc = qed_fw_vport(p_hwfn, params->vport_id, &abs_vport_id); in qed_sp_eth_rxq_start_ramrod()
522 rc = qed_fw_l2_queue(p_hwfn, params->queue_id, &abs_rx_q_id); in qed_sp_eth_rxq_start_ramrod()
526 DP_VERBOSE(p_hwfn, QED_MSG_SP, in qed_sp_eth_rxq_start_ramrod()
535 rc = qed_sp_init_request(p_hwfn, &p_ent, in qed_sp_eth_rxq_start_ramrod()
561 rc = qed_spq_post(p_hwfn, p_ent, NULL); in qed_sp_eth_rxq_start_ramrod()
567 qed_sp_eth_rx_queue_start(struct qed_hwfn *p_hwfn, in qed_sp_eth_rx_queue_start() argument
582 rc = qed_fw_l2_queue(p_hwfn, params->queue_id, &abs_l2_queue); in qed_sp_eth_rx_queue_start()
586 rc = qed_fw_vport(p_hwfn, params->vport_id, &abs_stats_id); in qed_sp_eth_rx_queue_start()
590 *pp_prod = (u8 __iomem *)p_hwfn->regview + in qed_sp_eth_rx_queue_start()
595 __internal_ram_wr(p_hwfn, *pp_prod, sizeof(u64), in qed_sp_eth_rx_queue_start()
599 p_rx_cid = &p_hwfn->p_rx_cids[params->queue_id]; in qed_sp_eth_rx_queue_start()
600 rc = qed_cxt_acquire_cid(p_hwfn, PROTOCOLID_ETH, in qed_sp_eth_rx_queue_start()
603 DP_NOTICE(p_hwfn, "Failed to acquire cid\n"); in qed_sp_eth_rx_queue_start()
608 rc = qed_sp_eth_rxq_start_ramrod(p_hwfn, in qed_sp_eth_rx_queue_start()
619 qed_sp_release_queue_cid(p_hwfn, p_rx_cid); in qed_sp_eth_rx_queue_start()
624 static int qed_sp_eth_rx_queue_stop(struct qed_hwfn *p_hwfn, in qed_sp_eth_rx_queue_stop() argument
629 struct qed_hw_cid_data *p_rx_cid = &p_hwfn->p_rx_cids[rx_queue_id]; in qed_sp_eth_rx_queue_stop()
640 rc = qed_sp_init_request(p_hwfn, &p_ent, in qed_sp_eth_rx_queue_stop()
651 qed_fw_vport(p_hwfn, p_rx_cid->vport_id, &p_ramrod->vport_id); in qed_sp_eth_rx_queue_stop()
652 qed_fw_l2_queue(p_hwfn, rx_queue_id, &abs_rx_q_id); in qed_sp_eth_rx_queue_stop()
659 (!!(p_rx_cid->opaque_fid == p_hwfn->hw_info.opaque_fid) && in qed_sp_eth_rx_queue_stop()
662 !(p_rx_cid->opaque_fid == p_hwfn->hw_info.opaque_fid) || in qed_sp_eth_rx_queue_stop()
665 rc = qed_spq_post(p_hwfn, p_ent, NULL); in qed_sp_eth_rx_queue_stop()
669 return qed_sp_release_queue_cid(p_hwfn, p_rx_cid); in qed_sp_eth_rx_queue_stop()
673 qed_sp_eth_txq_start_ramrod(struct qed_hwfn *p_hwfn, in qed_sp_eth_txq_start_ramrod() argument
691 p_tx_cid = &p_hwfn->p_tx_cids[p_params->queue_id]; in qed_sp_eth_txq_start_ramrod()
695 rc = qed_fw_vport(p_hwfn, p_params->vport_id, &abs_vport_id); in qed_sp_eth_txq_start_ramrod()
703 rc = qed_sp_init_request(p_hwfn, &p_ent, cid, in qed_sp_eth_txq_start_ramrod()
723 pq_id = qed_get_qm_pq(p_hwfn, in qed_sp_eth_txq_start_ramrod()
728 return qed_spq_post(p_hwfn, p_ent, NULL); in qed_sp_eth_txq_start_ramrod()
732 qed_sp_eth_tx_queue_start(struct qed_hwfn *p_hwfn, in qed_sp_eth_tx_queue_start() argument
744 rc = qed_fw_vport(p_hwfn, p_params->vport_id, &abs_stats_id); in qed_sp_eth_tx_queue_start()
748 p_tx_cid = &p_hwfn->p_tx_cids[p_params->queue_id]; in qed_sp_eth_tx_queue_start()
753 rc = qed_cxt_acquire_cid(p_hwfn, PROTOCOLID_ETH, in qed_sp_eth_tx_queue_start()
756 DP_NOTICE(p_hwfn, "Failed to acquire cid\n"); in qed_sp_eth_tx_queue_start()
761 DP_VERBOSE(p_hwfn, QED_MSG_SP, in qed_sp_eth_tx_queue_start()
766 rc = qed_sp_eth_txq_start_ramrod(p_hwfn, in qed_sp_eth_tx_queue_start()
775 *pp_doorbell = (u8 __iomem *)p_hwfn->doorbells + in qed_sp_eth_tx_queue_start()
779 qed_sp_release_queue_cid(p_hwfn, p_tx_cid); in qed_sp_eth_tx_queue_start()
784 static int qed_sp_eth_tx_queue_stop(struct qed_hwfn *p_hwfn, in qed_sp_eth_tx_queue_stop() argument
787 struct qed_hw_cid_data *p_tx_cid = &p_hwfn->p_tx_cids[tx_queue_id]; in qed_sp_eth_tx_queue_stop()
796 rc = qed_sp_init_request(p_hwfn, &p_ent, in qed_sp_eth_tx_queue_stop()
805 rc = qed_spq_post(p_hwfn, p_ent, NULL); in qed_sp_eth_tx_queue_stop()
809 return qed_sp_release_queue_cid(p_hwfn, p_tx_cid); in qed_sp_eth_tx_queue_stop()
849 qed_filter_ucast_common(struct qed_hwfn *p_hwfn, in qed_filter_ucast_common() argument
865 rc = qed_fw_vport(p_hwfn, p_filter_cmd->vport_to_remove_from, in qed_filter_ucast_common()
870 rc = qed_fw_vport(p_hwfn, p_filter_cmd->vport_to_add_to, in qed_filter_ucast_common()
880 rc = qed_sp_init_request(p_hwfn, pp_ent, in qed_filter_ucast_common()
881 qed_spq_get_cid(p_hwfn), in qed_filter_ucast_common()
969 DP_NOTICE(p_hwfn, in qed_filter_ucast_common()
985 static int qed_sp_eth_filter_ucast(struct qed_hwfn *p_hwfn, in qed_sp_eth_filter_ucast() argument
996 rc = qed_filter_ucast_common(p_hwfn, opaque_fid, p_filter_cmd, in qed_sp_eth_filter_ucast()
1000 DP_ERR(p_hwfn, "Uni. filter command failed %d\n", rc); in qed_sp_eth_filter_ucast()
1006 rc = qed_spq_post(p_hwfn, p_ent, NULL); in qed_sp_eth_filter_ucast()
1008 DP_ERR(p_hwfn, in qed_sp_eth_filter_ucast()
1014 DP_VERBOSE(p_hwfn, QED_MSG_SP, in qed_sp_eth_filter_ucast()
1027 DP_VERBOSE(p_hwfn, QED_MSG_SP, in qed_sp_eth_filter_ucast()
1096 qed_sp_eth_filter_mcast(struct qed_hwfn *p_hwfn, in qed_sp_eth_filter_mcast() argument
1110 rc = qed_fw_vport(p_hwfn, p_filter_cmd->vport_to_add_to, in qed_sp_eth_filter_mcast()
1115 rc = qed_fw_vport(p_hwfn, p_filter_cmd->vport_to_remove_from, in qed_sp_eth_filter_mcast()
1126 rc = qed_sp_init_request(p_hwfn, &p_ent, in qed_sp_eth_filter_mcast()
1127 qed_spq_get_cid(p_hwfn), in qed_sp_eth_filter_mcast()
1128 p_hwfn->hw_info.opaque_fid, in qed_sp_eth_filter_mcast()
1134 DP_ERR(p_hwfn, "Multi-cast command failed %d\n", rc); in qed_sp_eth_filter_mcast()
1169 return qed_spq_post(p_hwfn, p_ent, NULL); in qed_sp_eth_filter_mcast()
1188 struct qed_hwfn *p_hwfn = &cdev->hwfns[i]; in qed_filter_mcast_cmd() local
1195 opaque_fid = p_hwfn->hw_info.opaque_fid; in qed_filter_mcast_cmd()
1197 rc = qed_sp_eth_filter_mcast(p_hwfn, in qed_filter_mcast_cmd()
1215 struct qed_hwfn *p_hwfn = &cdev->hwfns[i]; in qed_filter_ucast_cmd() local
1221 opaque_fid = p_hwfn->hw_info.opaque_fid; in qed_filter_ucast_cmd()
1223 rc = qed_sp_eth_filter_ucast(p_hwfn, in qed_filter_ucast_cmd()
1279 struct qed_hwfn *p_hwfn = &cdev->hwfns[i]; in qed_start_vport() local
1281 rc = qed_sp_vport_start(p_hwfn, in qed_start_vport()
1282 p_hwfn->hw_info.concrete_fid, in qed_start_vport()
1283 p_hwfn->hw_info.opaque_fid, in qed_start_vport()
1294 qed_hw_start_fastpath(p_hwfn); in qed_start_vport()
1312 struct qed_hwfn *p_hwfn = &cdev->hwfns[i]; in qed_stop_vport() local
1314 rc = qed_sp_vport_stop(p_hwfn, in qed_stop_vport()
1315 p_hwfn->hw_info.opaque_fid, in qed_stop_vport()
1402 struct qed_hwfn *p_hwfn = &cdev->hwfns[i]; in qed_update_vport() local
1404 sp_params.opaque_fid = p_hwfn->hw_info.opaque_fid; in qed_update_vport()
1405 rc = qed_sp_vport_update(p_hwfn, &sp_params, in qed_update_vport()
1431 struct qed_hwfn *p_hwfn; in qed_start_rxq() local
1434 p_hwfn = &cdev->hwfns[hwfn_index]; in qed_start_rxq()
1439 rc = qed_sp_eth_rx_queue_start(p_hwfn, in qed_start_rxq()
1440 p_hwfn->hw_info.opaque_fid, in qed_start_rxq()
1465 struct qed_hwfn *p_hwfn; in qed_stop_rxq() local
1468 p_hwfn = &cdev->hwfns[hwfn_index]; in qed_stop_rxq()
1470 rc = qed_sp_eth_rx_queue_stop(p_hwfn, in qed_stop_rxq()
1488 struct qed_hwfn *p_hwfn; in qed_start_txq() local
1492 p_hwfn = &cdev->hwfns[hwfn_index]; in qed_start_txq()
1497 rc = qed_sp_eth_tx_queue_start(p_hwfn, in qed_start_txq()
1498 p_hwfn->hw_info.opaque_fid, in qed_start_txq()
1528 struct qed_hwfn *p_hwfn; in qed_stop_txq() local
1532 p_hwfn = &cdev->hwfns[hwfn_index]; in qed_stop_txq()
1534 rc = qed_sp_eth_tx_queue_stop(p_hwfn, in qed_stop_txq()