DPDK patches and discussions
 help / color / mirror / Atom feed
From: Chas Williams <3chas3@gmail.com>
To: Beilei Xing <beilei.xing@intel.com>,
	Qi Zhang <qi.z.zhang@intel.com>,
	dev@dpdk.org
Subject: [dpdk-dev] i40e VMDQ behavior
Date: Mon, 6 Aug 2018 15:46:00 -0400	[thread overview]
Message-ID: <CAG2-Gkk-TxtZPK0y+=dfH+PwXqMmVi1DysgC2Qr5rdKQ_JxP_w@mail.gmail.com> (raw)

How is VMDQ supposed to work?

The i40e .dev_infos_get doesn't seem to look for the VMDQ enabled flag and
just goes ahead and modifies the queue counts to include the VMDQ queues:

        if (pf->flags & I40E_FLAG_VMDQ) {
                dev_info->max_vmdq_pools = pf->max_nb_vmdq_vsi;
                dev_info->vmdq_queue_base = dev_info->max_rx_queues;
                dev_info->vmdq_queue_num = pf->vmdq_nb_qps *
                                                pf->max_nb_vmdq_vsi;
                dev_info->vmdq_pool_base = I40E_VMDQ_POOL_BASE;
                dev_info->max_rx_queues += dev_info->vmdq_queue_num;
                dev_info->max_tx_queues += dev_info->vmdq_queue_num;
        }

[Note that I40E_FLAG_VMDQ is whether or not the i40e supports VMDQ
apparently.]  This inflates the values of max_rx_queues and max_tx_queues.
But since I am not using VMDQ, I later an error from:

static struct i40e_vsi*
i40e_pf_get_vsi_by_qindex(struct i40e_pf *pf, uint16_t queue_idx)
{
        /* the queue in MAIN VSI range */
        if (queue_idx < pf->main_vsi->nb_qps)
                return pf->main_vsi;

        queue_idx -= pf->main_vsi->nb_qps;

        /* queue_idx is greater than VMDQ VSIs range */
        if (queue_idx > pf->nb_cfg_vmdq_vsi * pf->vmdq_nb_qps - 1) {
                PMD_INIT_LOG(ERR, "queue_idx out of range. VMDQ
configured?");
                return NULL;
        }

as I try to setup the VMDQ queues that the PMD told me I could use.

It's not clear what the right thing to do is.  Should I be
using dev_info->vmdq_queue_num as the PF queue count
if dev_info->vmdq_queue_num is set to anything other than 0?  Even when I
am not using VMDQ?

The examples imply:

examples/vmdq/main.c: num_pf_queues = dev_info.max_rx_queues -
dev_info.vmdq_queue_num;

But that doesn't make sense to me since I am not using VMDQ and in some
cases, like ixgbe, sets vmdq_queue_num to the number of PF queues:

        dev_info->vmdq_queue_num = dev_info->max_rx_queues;

So, in VMDQ mode I would have no PF queues (which sort of make sense) but
if I am not in VMDQ mode, then I still have no PF queues.

                 reply	other threads:[~2018-08-06 19:46 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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='CAG2-Gkk-TxtZPK0y+=dfH+PwXqMmVi1DysgC2Qr5rdKQ_JxP_w@mail.gmail.com' \
    --to=3chas3@gmail.com \
    --cc=beilei.xing@intel.com \
    --cc=dev@dpdk.org \
    --cc=qi.z.zhang@intel.com \
    /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).