DPDK patches and discussions
 help / color / mirror / Atom feed
From: "Roberts, Lee A." <lee.roberts@hp.com>
To: "thomas.monjalon@6wind.com" <thomas.monjalon@6wind.com>
Cc: "dev@dpdk.org" <dev@dpdk.org>
Subject: [dpdk-dev] issue with ixgbevf speed/duplex introduced with commit 8ef32003772a14c61c70b540e41c259c482c2fb6
Date: Fri, 7 Nov 2014 16:36:08 +0000	[thread overview]
Message-ID: <D64EC45690EF85409BA6C4730E0162244E988E64@G4W3231.americas.hpqcorp.net> (raw)

Thomas,

I'm seeing an issue with ixgbevf speed/duplex reporting that appears to have been introduced with
commit 8ef32003772a14c61c70b540e41c259c482c2fb6 (http://www.dpdk.org/browse/dpdk/commit/lib/librte_pmd_ixgbe/ixgbe/ixgbe_vf.c?id=8ef32003772a14c61c70b540e41c259c482c2fb6)

The issue I'm seeing seems to involve the following code.  If I'm reading this correctly,
one sets "mac->get_link_status = true" if the port is not OK, where "true" means that one
still needs to get the link status.  Due to the added test "if (!mac->get_link_status)",
one branches to the early exit if mac->get_link_status is false---meaning we have already
obtained the link status---instead of continuing with the analysis in the function body.

-       if (!(hw->mbx.ops.check_for_rst(hw, 0))) {
-               *link_up = false;
-               *speed = 0;
-               return -1;
-       }
+       /* If we were hit with a reset drop the link */
+       if (!mbx->ops.check_for_rst(hw, 0) || !mbx->timeout)
+               mac->get_link_status = true;

-       links_reg = IXGBE_VFREAD_REG(hw, IXGBE_VFLINKS);
+       if (!mac->get_link_status)
+               goto out;

When I run "testpmd" on ixgbevf ports either in the host OS or passed
through to a virtual machine, "testpmd" reports that the ixgbevf ports
have "speed 100 Mbps - half-duplex".  With the previous code (or with
my patch), "testpmd" reports "speed 10000 Mbps - full-duplex".

-       Lee Roberts

             reply	other threads:[~2014-11-07 16:27 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-11-07 16:36 Roberts, Lee A. [this message]
2014-11-07 16:46 ` Thomas Monjalon
2014-11-27 17:36   ` Thomas Monjalon

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=D64EC45690EF85409BA6C4730E0162244E988E64@G4W3231.americas.hpqcorp.net \
    --to=lee.roberts@hp.com \
    --cc=dev@dpdk.org \
    --cc=thomas.monjalon@6wind.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).