From: Andrew Boyer <aboyer@pensando.io>
To: dev@dpdk.org, Ferruh Yigit <ferruh.yigit@intel.com>
Subject: Re: [dpdk-dev] Q about testpmd and link speed settings
Date: Wed, 9 Dec 2020 14:32:24 -0500 [thread overview]
Message-ID: <ED626C63-6831-4A1A-9088-6263B0B189D9@pensando.io> (raw)
In-Reply-To: <F041DE53-0ABF-4A0A-974A-16167967ABD5@pensando.io>
Any replies to this? Am I understanding the API correctly?
-Andrew
> On Nov 25, 2020, at 3:55 PM, Andrew Boyer <aboyer@pensando.io> wrote:
>
> Almost every PMD seems to do something like this (igb in this example):
>
> autoneg = (*speeds & ETH_LINK_SPEED_FIXED) == 0;
>
> But testpmd’s parse_and_check_speed_duplex() doesn’t ever set the FIXED bit. It either sets AUTONEG (0) or the bit for one of the individual speeds.
>
> Thus when I run a testpmd command like this:
>
> testpmd> port config all speed 100000 duplex full
>
> The PMD gets a speed setting in eth_dev->data->dev_conf->link_speeds, but it doesn’t have the FIXED bit set.
>
> The patch below corrects this behavior for me. For some reason it breaks the testpmd link_bonding_autotest though - does anyone with an understanding of the internals of the unit tests care to take a look at why?
>
> + TestCase [51] : test_tlb_verify_promiscuous_enable_disable succeeded
> + TestCase [52] : test_tlb_verify_slave_link_status_change_failover failed
> Port 8 must be stopped to allow configuration
> + TestCase [53] : test_alb_change_mac_in_reply_sent failed
> Port 8 must be stopped to allow configuration
> + TestCase [54] : test_alb_reply_from_client failed
> Port 8 must be stopped to allow configuration
> + TestCase [55] : test_alb_receive_vlan_reply failed
> Port 8 must be stopped to allow configuration
> + TestCase [56] : test_alb_ipv4_tx failed
>
> Does this sound reasonable or am I way off track?
>
> Thank you,
> Andrew
>
> diff --git a/app/test-pmd/cmdline.c b/app/test-pmd/cmdline.c
> index a037a55c6a..075804b8b5 100644
> --- a/app/test-pmd/cmdline.c
> +++ b/app/test-pmd/cmdline.c
> @@ -1627,6 +1627,9 @@ parse_and_check_speed_duplex(char *speedstr, char *duplexstr, uint32_t *speed)
> }
> }
>
> + if (*speed != ETH_LINK_SPEED_AUTONEG)
> + *speed |= ETH_LINK_SPEED_FIXED;
> +
> return 0;
> }
>
>
>
prev parent reply other threads:[~2020-12-09 19:32 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-11-25 20:55 Andrew Boyer
2020-12-09 19:32 ` Andrew Boyer [this message]
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=ED626C63-6831-4A1A-9088-6263B0B189D9@pensando.io \
--to=aboyer@pensando.io \
--cc=dev@dpdk.org \
--cc=ferruh.yigit@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).