From: Ajit Khaparde Date: Thu, 28 Jun 2018 20:15:30 +0000 (-0700) Subject: net/bnxt: set descriptor rings limits X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=6a68c813fd16e42940b451cf8ee45dca05e2c602;p=dpdk.git net/bnxt: set descriptor rings limits Set MIN and MAX descriptor count for TX and RX rings. Signed-off-by: Ajit Khaparde --- diff --git a/drivers/net/bnxt/bnxt.h b/drivers/net/bnxt/bnxt.h index d19aea5694..9a70617fc8 100644 --- a/drivers/net/bnxt/bnxt.h +++ b/drivers/net/bnxt/bnxt.h @@ -24,6 +24,9 @@ #define VLAN_TAG_SIZE 4 #define BNXT_MAX_LED 4 #define BNXT_NUM_VLANS 2 +#define BNXT_MIN_RING_DESC 16 +#define BNXT_MAX_TX_RING_DESC 4096 +#define BNXT_MAX_RX_RING_DESC 8192 struct bnxt_led_info { uint8_t led_id; diff --git a/drivers/net/bnxt/bnxt_ethdev.c b/drivers/net/bnxt/bnxt_ethdev.c index f26461c42c..752c3481ad 100644 --- a/drivers/net/bnxt/bnxt_ethdev.c +++ b/drivers/net/bnxt/bnxt_ethdev.c @@ -450,6 +450,10 @@ static void bnxt_dev_info_get_op(struct rte_eth_dev *eth_dev, eth_dev->data->dev_conf.intr_conf.lsc = 1; eth_dev->data->dev_conf.intr_conf.rxq = 1; + dev_info->rx_desc_lim.nb_min = BNXT_MIN_RING_DESC; + dev_info->rx_desc_lim.nb_max = BNXT_MAX_RX_RING_DESC; + dev_info->tx_desc_lim.nb_min = BNXT_MIN_RING_DESC; + dev_info->tx_desc_lim.nb_max = BNXT_MAX_TX_RING_DESC; /* *INDENT-ON* */