From mboxrd@z Thu Jan 1 00:00:00 1970 From: Chas Williams <3chas3@gmail.com> Subject: Re: [PATCH v3 27/27] net/ena: set link speed as none Date: Sat, 9 Jun 2018 21:35:10 -0400 Message-ID: References: <20180607094322.14312-1-mk@semihalf.com> <20180607094322.14312-27-mk@semihalf.com> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Cc: mk@semihalf.com, mw@semihalf.com, gtzalik@amazon.com, evgenys@amazon.com, dev@dpdk.org, matua@amazon.com, rk@semihalf.com To: Ferruh Yigit Return-path: Received: from mail-io0-f195.google.com (mail-io0-f195.google.com [209.85.223.195]) by dpdk.org (Postfix) with ESMTP id 620FF1EFAB for ; Sun, 10 Jun 2018 03:35:22 +0200 (CEST) Received: by mail-io0-f195.google.com with SMTP id l19-v6so20058658ioj.5 for ; Sat, 09 Jun 2018 18:35:22 -0700 (PDT) In-Reply-To: List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On Fri, Jun 8, 2018 at 3:37 PM Ferruh Yigit wrote: > On 6/7/2018 10:43 AM, Michal Krawczyk wrote: > > From: Rafal Kozik > > > > Link speed should is not limited to 10Gb/s and it shouldn't be hardcoded. > > > > They link speed is set to none instead and the applications shouldn't > > rely on this value when using ENA PMD. > > Why not able to set link speed? > > And what is the link_autoneg, ETH_LINK_FIXED? What is the point of setting > link > speed FIXED and later speed value NONE? > The link speed is part of the spanning tree path computation. I don't think picking 0 (or undefined) is the appropriate choice. For virtual interfaces link speed is a troublesome quantity but advertising undefined seems worse then just use some constant value. > > > > > Fixes: 1173fca ("ena: add polling-mode driver") > > For next time can you please use git alias to have consistent Fixes format > > > > > Signed-off-by: Rafal Kozik > > Acked-by: Michal Krawczyk > > --- > > drivers/net/ena/ena_ethdev.c | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > diff --git a/drivers/net/ena/ena_ethdev.c b/drivers/net/ena/ena_ethdev.c > > index 5c3b6494f..9ae73e331 100644 > > --- a/drivers/net/ena/ena_ethdev.c > > +++ b/drivers/net/ena/ena_ethdev.c > > @@ -848,7 +848,7 @@ static int ena_link_update(struct rte_eth_dev *dev, > > adapter = (struct ena_adapter *)(dev->data->dev_private); > > > > link->link_status = adapter->link_status ? ETH_LINK_UP : > ETH_LINK_DOWN; > > - link->link_speed = ETH_SPEED_NUM_10G; > > + link->link_speed = ETH_SPEED_NUM_NONE; > > link->link_duplex = ETH_LINK_FULL_DUPLEX; > > > > return 0; > > > >