From: Olivier MATZ <olivier.matz@6wind.com>
To: Christos Ricudis <ricudis.christos@gmail.com>
Cc: dev@dpdk.org, helin.zhang@intel.com, jingjing.wu@intel.com
Subject: Re: i40e_aq_get_phy_capabilities() fails when using SFP+ with no link
Date: Tue, 10 Jan 2017 16:28:49 +0100 [thread overview]
Message-ID: <20170110162849.2256dc6e@glumotte.dev.6wind.com> (raw)
In-Reply-To: <2BF7FCC7-B2DF-43EE-B5F8-2F3271FB3DA1@gmail.com>
Hi Christos,
+CC i40e maintainers
On Tue, 10 Jan 2017 20:32:26 +0800, Christos Ricudis
<ricudis.christos@gmail.com> wrote:
> Hello,
>
> Using a X710 based 4-port 4x10Gbit NIC, I have came across the
> following issue on the i40e PMD:
>
> When an optical SFP+ (Finisar FTLX8571D3BCL) is used with no active
> link partner on the other end of the link (or fiber completely
> disconnected from the SFP+), i40e_aq_get_phy_capabilities() (called
> by i40e_dev_sync_phy_type() on port initialization), fails with a
> 0x05 return value (EIO) on the AQ response structure. The struct
> i40e_aq_get_phy_abilities_resp buffer passed to the Get Phy Abilities
> command is unmodified upon return.
>
> This prevents DPDK 16.11 from initializing the port, and ultimately
> fails with the following error:
>
> PMD: eth_i40e_dev_init(): Failed to sync phy type: -95
>
> The change introducing this issue was
> http://dpdk.org/ml/archives/dev/2016-September/047663.html
>
> Reading the X710 datasheet, I notice that no specific mention is
> given on the meaning of EIO as a response to Get PHY Abilities
> command (opcode 0x0600), whereas in most other commands, an explicit
> mention of the meaning of the possible error status responses is
> given.
>
> This behaviour is the same across the following NVM releases:
>
> FW 4.33 API 1.2 NVM 04.04.02 eetrack 800018a6
> FW 4.40 API 1.4 NVM 04.05.03 eetrack 80001cd8
> FW 5.0 API 1.5 NVM 05.00.04 eetrack 800024da
>
> I will try to get around the issue by falling back to PHY
> capabilities detection using the device ID in the case
> i40e_aq_get_phy_capabilities() fails, but conceptually the
> capabilities of the PHY should not be dependent on whether PHY
> detects an active link or not.
>
> I’d be happy to do more testing on this issue per your
> recommendations.
>
> Moreover, while trying to debug this issue, I managed to get both 3
> NIC adapters on my test system on a state where the PHY has
> apparently died - no link indication at all on any ports. A reboot
> solved this, and I am now trying to replicate this behaviour under
> more controlled conditions.
>
I'm currently running into a similar issue (I think). I can reproduce
it with testpmd with the following case:
set link_check off
port stop 0
# don't wait between these 2 commands
port start 0
I added some logs that are displayed after the port start:
PMD: i40e_set_tx_function(): Vector tx finally be used.
PMD: i40e_set_rx_function(): Vector rx enabled, please make sure RX
burst size no less than 4 (port=0).
PMD: i40e_dev_rx_queue_start(): >>
PMD: i40e_dev_tx_queue_start(): >>
PMD: i40e_dev_start(): applying link settings...
PMD: i40e_apply_link_speed(): abilities = 38, speed = 0
PMD: i40e_phy_conf_link(): i40e_aq_get_phy_capabilities failed -7
PMD: i40e_dev_start(): Fail to apply link setting
PMD: i40e_dev_clear_queues(): >>
The -7 corresponds to I40E_ERR_UNKNOWN_PHY. This happens in
i40e_aq_get_phy_capabilities() in the following code, which makes me
think it's the same problem than yours:
if (hw->aq.asq_last_status == I40E_AQ_RC_EIO)
status = I40E_ERR_UNKNOWN_PHY;
A workaround in my usecase is to wait a bit between the stop and the
start.
Any help is welcome.
Regards,
Olivier
next prev parent reply other threads:[~2017-01-10 15:28 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-01-10 12:32 i40e_aq_get_phy_capabilities() fails when using SFP+ with no link Christos Ricudis
2017-01-10 15:28 ` Olivier MATZ [this message]
2017-01-11 1:08 ` Zhang, Helin
2017-01-11 3:00 ` Christos Ricudis
[not found] ` <FC7A99FCE8F15942AB8D6F91FF66D8F694836A60@ORSMSX112.amr.corp.intel.com>
2017-01-12 13:55 ` Olivier MATZ
2017-01-13 13:24 ` Olivier Matz
2017-01-17 12:50 ` Wu, Jingjing
2017-01-18 10:15 ` Christos Ricudis
2017-02-05 15:30 ` Ivan Nardi
2017-02-05 20:19 ` Ivan Nardi
2017-02-06 1:04 ` Zhang, Qi Z
2017-02-06 1:36 ` Zhang, Helin
2017-02-07 14:56 ` Olivier MATZ
2017-02-07 14:58 ` Zhang, Helin
2017-02-12 16:13 ` Ivan Nardi
2017-02-06 21:06 ` Ivan Nardi
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=20170110162849.2256dc6e@glumotte.dev.6wind.com \
--to=olivier.matz@6wind.com \
--cc=dev@dpdk.org \
--cc=helin.zhang@intel.com \
--cc=jingjing.wu@intel.com \
--cc=ricudis.christos@gmail.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.