From: Amedeo Sapio <amedeo.sapio@gmail.com>
To: dev@dpdk.org
Subject: [dpdk-dev] MLX5 driver - number of descriptors overflow
Date: Wed, 21 Nov 2018 12:01:28 +0300 [thread overview]
Message-ID: <CAMkTTJPkjXtctwm9JhgbmBFVDNMr15pwg4WkS9qHy68KDGk+UQ@mail.gmail.com> (raw)
Hello,
I experienced a problem with the MLX5 driver running a code that is working
fine with an Intel card. I have found that the reason of this error is an
overflow of the uint16_t number of descriptors in the mlx driver.
Here the details:
- The NIC is a Mellanox ConnectX-5 100G.
- This is a summary code that I run to initialize the port:
ret = rte_eth_dev_configure(dpdk_par.portid, 1, 1, &port_conf);
dpdk_par.port_rx_ring_size = dev_info.rx_desc_lim.nb_max;
dpdk_par.port_tx_ring_size = dev_info.tx_desc_lim.nb_max;
ret = rte_eth_dev_adjust_nb_rx_tx_desc(dpdk_par.portid,
&dpdk_par.port_rx_ring_size, &dpdk_par.port_tx_ring_size);
ret = rte_eth_rx_queue_setup(dpdk_par.portid, 0,
dpdk_par.port_rx_ring_size, rte_eth_dev_socket_id(dpdk_par.portid),
&rx_conf, dpdk_data.pool);
ret = rte_eth_tx_queue_setup(dpdk_par.portid, 0,
dpdk_par.port_tx_ring_size, rte_eth_dev_socket_id(dpdk_par.portid),
&tx_conf);
ret = rte_eth_dev_start(dpdk_par.portid);
- The "rte_eth_dev_start" function returns -ENOMEM = -12 (Out of memory)
- I see that "dev_info.rx_desc_lim.nb_max" is 65535. This value is rounded
to the next power of 2 in "mlx5_rx_queue_setup", which overflows and
becomes 0.
I thought that "rte_eth_dev_adjust_nb_rx_tx_desc" should have adjusted the
value, but clearly it has not.
Thanks,
---
Amedeo
next reply other threads:[~2018-11-21 9:01 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-11-21 9:01 Amedeo Sapio [this message]
2018-11-25 23:40 ` Yongseok Koh
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAMkTTJPkjXtctwm9JhgbmBFVDNMr15pwg4WkS9qHy68KDGk+UQ@mail.gmail.com \
--to=amedeo.sapio@gmail.com \
--cc=dev@dpdk.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).