git.droids-corp.org
/
dpdk.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
net/sfc: fence off 8 bits in Rx mark for tunnel offload
[dpdk.git]
/
drivers
/
net
/
bnxt
/
tf_ulp
/
ulp_port_db.c
diff --git
a/drivers/net/bnxt/tf_ulp/ulp_port_db.c
b/drivers/net/bnxt/tf_ulp/ulp_port_db.c
index
96fc456
..
7d9865b
100644
(file)
--- a/
drivers/net/bnxt/tf_ulp/ulp_port_db.c
+++ b/
drivers/net/bnxt/tf_ulp/ulp_port_db.c
@@
-7,9
+7,14
@@
#include "bnxt.h"
#include "bnxt_vnic.h"
#include "bnxt_tf_common.h"
#include "bnxt.h"
#include "bnxt_vnic.h"
#include "bnxt_tf_common.h"
+#include "bnxt_tf_pmd_shim.h"
#include "ulp_port_db.h"
#include "tfp.h"
#include "ulp_port_db.h"
#include "tfp.h"
+#ifdef RTE_LIBRTE_BNXT_TRUFLOW_DEBUG
+#include "ulp_tf_debug.h"
+#endif
+
static uint32_t
ulp_port_db_allocate_ifindex(struct bnxt_ulp_port_db *port_db)
{
static uint32_t
ulp_port_db_allocate_ifindex(struct bnxt_ulp_port_db *port_db)
{
@@
-148,59
+153,64
@@
int32_t ulp_port_db_dev_port_intf_update(struct bnxt_ulp_context *ulp_ctxt,
/* update the interface details */
intf = &port_db->ulp_intf_list[ifindex];
/* update the interface details */
intf = &port_db->ulp_intf_list[ifindex];
- intf->type = bnxt_get_interface_type(port_id);
- intf->drv_func_id = bnxt_get_fw_func_id(port_id,
+ intf->type = bnxt_
pmd_
get_interface_type(port_id);
+ intf->drv_func_id = bnxt_
pmd_
get_fw_func_id(port_id,
BNXT_ULP_INTF_TYPE_INVALID);
func = &port_db->ulp_func_id_tbl[intf->drv_func_id];
if (!func->func_valid) {
BNXT_ULP_INTF_TYPE_INVALID);
func = &port_db->ulp_func_id_tbl[intf->drv_func_id];
if (!func->func_valid) {
- func->func_svif = bnxt_get_svif(port_id, true,
+ func->func_svif = bnxt_
pmd_
get_svif(port_id, true,
BNXT_ULP_INTF_TYPE_INVALID);
BNXT_ULP_INTF_TYPE_INVALID);
- func->func_spif = bnxt_get_phy_port_id(port_id);
+ func->func_spif = bnxt_
pmd_
get_phy_port_id(port_id);
func->func_parif =
func->func_parif =
- bnxt_get_parif(port_id, BNXT_ULP_INTF_TYPE_INVALID);
+ bnxt_
pmd_
get_parif(port_id, BNXT_ULP_INTF_TYPE_INVALID);
func->func_vnic =
func->func_vnic =
- bnxt_get_vnic_id(port_id, BNXT_ULP_INTF_TYPE_INVALID);
- func->phy_port_id = bnxt_get_phy_port_id(port_id);
+ bnxt_
pmd_
get_vnic_id(port_id, BNXT_ULP_INTF_TYPE_INVALID);
+ func->phy_port_id = bnxt_
pmd_
get_phy_port_id(port_id);
func->func_valid = true;
func->ifindex = ifindex;
}
if (intf->type == BNXT_ULP_INTF_TYPE_VF_REP) {
intf->vf_func_id =
func->func_valid = true;
func->ifindex = ifindex;
}
if (intf->type == BNXT_ULP_INTF_TYPE_VF_REP) {
intf->vf_func_id =
- bnxt_get_fw_func_id(port_id, BNXT_ULP_INTF_TYPE_VF_REP);
+ bnxt_
pmd_
get_fw_func_id(port_id, BNXT_ULP_INTF_TYPE_VF_REP);
func = &port_db->ulp_func_id_tbl[intf->vf_func_id];
func->func_svif =
func = &port_db->ulp_func_id_tbl[intf->vf_func_id];
func->func_svif =
- bnxt_get_svif(port_id, true, BNXT_ULP_INTF_TYPE_VF_REP);
+ bnxt_
pmd_
get_svif(port_id, true, BNXT_ULP_INTF_TYPE_VF_REP);
func->func_spif =
func->func_spif =
- bnxt_get_phy_port_id(port_id);
+ bnxt_
pmd_
get_phy_port_id(port_id);
func->func_parif =
func->func_parif =
- bnxt_get_parif(port_id, BNXT_ULP_INTF_TYPE_INVALID);
+ bnxt_
pmd_
get_parif(port_id, BNXT_ULP_INTF_TYPE_INVALID);
func->func_vnic =
func->func_vnic =
- bnxt_get_vnic_id(port_id, BNXT_ULP_INTF_TYPE_VF_REP);
- func->phy_port_id = bnxt_get_phy_port_id(port_id);
+ bnxt_
pmd_
get_vnic_id(port_id, BNXT_ULP_INTF_TYPE_VF_REP);
+ func->phy_port_id = bnxt_
pmd_
get_phy_port_id(port_id);
func->ifindex = ifindex;
}
/* When there is no match, the default action is to send the packet to
* the kernel. And to send it to the kernel, we need the PF's vnic id.
*/
func->ifindex = ifindex;
}
/* When there is no match, the default action is to send the packet to
* the kernel. And to send it to the kernel, we need the PF's vnic id.
*/
- func->func_parent_vnic = bnxt_get_parent_vnic_id(port_id, intf->type);
+ func->func_parent_vnic = bnxt_
pmd_
get_parent_vnic_id(port_id, intf->type);
func->func_parent_vnic = tfp_cpu_to_be_16(func->func_parent_vnic);
func->func_parent_vnic = tfp_cpu_to_be_16(func->func_parent_vnic);
- bnxt_get_iface_mac(port_id, intf->type, func->func_mac,
+ bnxt_
pmd_
get_iface_mac(port_id, intf->type, func->func_mac,
func->func_parent_mac);
port_data = &port_db->phy_port_list[func->phy_port_id];
if (!port_data->port_valid) {
port_data->port_svif =
func->func_parent_mac);
port_data = &port_db->phy_port_list[func->phy_port_id];
if (!port_data->port_valid) {
port_data->port_svif =
- bnxt_get_svif(port_id, false, BNXT_ULP_INTF_TYPE_INVALID);
- port_data->port_spif = bnxt_get_phy_port_id(port_id);
+ bnxt_
pmd_
get_svif(port_id, false, BNXT_ULP_INTF_TYPE_INVALID);
+ port_data->port_spif = bnxt_
pmd_
get_phy_port_id(port_id);
port_data->port_parif =
port_data->port_parif =
- bnxt_get_parif(port_id, BNXT_ULP_INTF_TYPE_INVALID);
- port_data->port_vport = bnxt_get_vport(port_id);
+ bnxt_
pmd_
get_parif(port_id, BNXT_ULP_INTF_TYPE_INVALID);
+ port_data->port_vport = bnxt_
pmd_
get_vport(port_id);
port_data->port_valid = true;
}
port_data->port_valid = true;
}
+#ifdef RTE_LIBRTE_BNXT_TRUFLOW_DEBUG
+#ifdef RTE_LIBRTE_BNXT_TRUFLOW_DEBUG_PORT
+ ulp_port_db_dump(port_db, intf, port_id);
+#endif
+#endif
return 0;
}
return 0;
}