Skip to content

Commit cd3fd3f

Browse files
Sangtani Parag Satishbhaiajitkhaparde
authored andcommitted
net/bnxt: remove devarg mpc
Now as the mpc is initialized for P7 platform regardless of mpc=1 devarg, RTE and bnxt argument processing APIs for mpc devarg are redundant. This patch removes such RTE and bnxt APIs. The "mpc=1" devarg is now invalid and should not be used while launching an application. Before: ./dpdk-testpmd -c 0xff -a 0000:0a:00.0,mpc=1,app-id=0 After: ./dpdk-testpmd -c 0xff -a 0000:0a:00.0,app-id=0 Signed-off-by: Sangtani Parag Satishbhai <[email protected]> Reviewed-by: Ajit Khaparde <[email protected]>
1 parent 4dc67b2 commit cd3fd3f

File tree

2 files changed

+4
-18
lines changed

2 files changed

+4
-18
lines changed

drivers/net/bnxt/bnxt.h

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -854,9 +854,6 @@ struct bnxt {
854854
((bp)->flags2 & BNXT_FLAGS2_MULTIROOT_EN)
855855

856856
#define BNXT_FLAGS2_COMPRESSED_RX_CQE BIT(5)
857-
#define BNXT_FLAGS2_USE_MPC BIT(6)
858-
#define BNXT_USE_MPC(bp) \
859-
((bp)->flags2 & BNXT_FLAGS2_USE_MPC)
860857
#define BNXT_FLAGS2_REP_MODE BIT(7)
861858
#define BNXT_REP_MODE_EN(bp) \
862859
((bp)->flags2 & BNXT_FLAGS2_REP_MODE)

drivers/net/bnxt/bnxt_ethdev.c

Lines changed: 4 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -152,11 +152,6 @@ static const struct rte_eth_speed_lanes_capa speed_lanes_capa_tbl[] = {
152152
*/
153153
#define BNXT_DEVARG_CQE_MODE_INVALID(val) ((val) > 1)
154154

155-
/*
156-
* mpc = an non-negative 8-bit number
157-
*/
158-
#define BNXT_DEVARG_MPC_INVALID(val) ((val) > 1)
159-
160155
/*
161156
* app-id = an non-negative 8-bit number
162157
*/
@@ -207,7 +202,6 @@ static const struct rte_eth_speed_lanes_capa speed_lanes_capa_tbl[] = {
207202
#define BNXT_DEVARG_REP_FC_F2R_INVALID(rep_fc_f2r) ((rep_fc_f2r) > 1)
208203

209204
int bnxt_cfa_code_dynfield_offset = -1;
210-
unsigned long mpc;
211205

212206
/*
213207
* max_num_kflows must be >= 32
@@ -1759,8 +1753,7 @@ static int bnxt_dev_stop(struct rte_eth_dev *eth_dev)
17591753
/* Process any remaining notifications in default completion queue */
17601754
bnxt_int_handler(eth_dev);
17611755

1762-
if (mpc != 0)
1763-
bnxt_mpc_close(bp);
1756+
bnxt_mpc_close(bp);
17641757

17651758
bnxt_shutdown_nic(bp);
17661759
bnxt_hwrm_if_change(bp, false);
@@ -1856,11 +1849,9 @@ int bnxt_dev_start_op(struct rte_eth_dev *eth_dev)
18561849
if (rc)
18571850
goto error;
18581851

1859-
if (mpc != 0) {
1860-
rc = bnxt_mpc_open(bp);
1861-
if (rc != 0)
1862-
PMD_DRV_LOG_LINE(DEBUG, "MPC open failed");
1863-
}
1852+
rc = bnxt_mpc_open(bp);
1853+
if (rc != 0)
1854+
PMD_DRV_LOG_LINE(DEBUG, "MPC open failed");
18641855

18651856
rc = bnxt_alloc_prev_ring_stats(bp);
18661857
if (rc)
@@ -7208,8 +7199,6 @@ static bool bnxt_enable_ulp(struct bnxt *bp)
72087199
/* not enabling ulp for cli and no truflow apps */
72097200
if (BNXT_TRUFLOW_EN(bp) && bp->app_id != 254 &&
72107201
bp->app_id != 255) {
7211-
if (BNXT_CHIP_P7(bp) && !mpc)
7212-
return false;
72137202
return true;
72147203
}
72157204
return false;

0 commit comments

Comments
 (0)