From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f66.google.com (mail-wm0-f66.google.com [74.125.82.66]) by dpdk.org (Postfix) with ESMTP id E29E21B758 for ; Tue, 10 Apr 2018 10:17:37 +0200 (CEST) Received: by mail-wm0-f66.google.com with SMTP id b127so24314922wmf.5 for ; Tue, 10 Apr 2018 01:17:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6wind-com.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:content-transfer-encoding:in-reply-to :user-agent; bh=KWvnLmepE9of5b89NpDbTMt3ehfe09BRR/HsbRyUE9g=; b=WQ6flv0SZcisz+zhFnZAMef2u7VFo4PFcENiOxJJmrViiSHDOnk6H1y5uu0MGqa6rR quGMHltmR/oAhE264CZhyaHgxr6ZFyMlgB1ZHA+2BFroZ00VwbihyNZqvIfQzfY7Oa4Y sf1DvqvWDN7r3nLsmY5LlMG3y+AbEEUqSJCDMhEPJxLAIOV6/ib4+9woY4DIPPwJiuQ3 PKvAGIWPJmu7YlH9CPM2t9XIjQIG6OwxL+RvZRGd0jJ6a537nk0ngJOoHD8EgqoamZ7R aO+t1iF+2FR3NV0KoBdAU9BIpv3pi9Qr6OMkdFngwAkVVFfzZmaQGCBqGZZGaCE80zP1 IqjA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:content-transfer-encoding :in-reply-to:user-agent; bh=KWvnLmepE9of5b89NpDbTMt3ehfe09BRR/HsbRyUE9g=; b=gkzYzI3kdEYBzbYJk9Go4GWfUq+j7XK+gbNmzAxbuOP1DHJ4SpOUW1orIe+1zzTVG9 K1XtA4eZdbXlCh5PeZPe6UNEmnlxQGikAPxFaY4IVDhTmqr0+xwPwVBlT+HtGdb0Zecf 8Mp/eDZkWBy7LZX//cQvC4jVuvAfSOUsHznZDSGdhgWBdthtyr4VwAKAEJZEGVzAqOXh SU62Smkfa+YHB8aijRwUQEUXkZK+RTqDKnzP5AzRF2DMwjNe7oIVedDQvplTeTnJaR4B VhmQtohAtIIsAV6eZagVjQYGKvR50TciQG1k3JlmuJZKQCy30rOxCMZjGYhOopGWq736 3SfQ== X-Gm-Message-State: ALQs6tDNo2V4lXMFWmbeqIGz3LT75ss/SIWZaZYi9NIDXObCt5qIgDPh /izbcd/KudZMc+rElx+4I7rK X-Google-Smtp-Source: AIpwx48Ajuu651YDhDDRDUHoFtEDA8KR9UniOufNUEacxAsPeH6A8UBb0dL9t1OvjX/GkFKG9FsCoA== X-Received: by 10.28.103.10 with SMTP id b10mr843396wmc.132.1523348257707; Tue, 10 Apr 2018 01:17:37 -0700 (PDT) Received: from laranjeiro-vm.dev.6wind.com (host.78.145.23.62.rev.coltfrance.com. [62.23.145.78]) by smtp.gmail.com with ESMTPSA id c15sm2961208wrc.64.2018.04.10.01.17.36 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 10 Apr 2018 01:17:37 -0700 (PDT) Date: Tue, 10 Apr 2018 10:17:54 +0200 From: =?iso-8859-1?Q?N=E9lio?= Laranjeiro To: Shahaf Shuler Cc: adrien.mazarguil@6wind.com, yskoh@mellanox.com, dev@dpdk.org Message-ID: <20180410081754.byft4mcgqa7wbmvx@laranjeiro-vm.dev.6wind.com> References: <20180403044817.27457-1-shahafs@mellanox.com> <20180410061336.49844-1-shahafs@mellanox.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20180410061336.49844-1-shahafs@mellanox.com> User-Agent: NeoMutt/20170113 (1.7.2) Subject: Re: [dpdk-dev] [PATCH v2] net/mlx5: fix link status initialization X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 10 Apr 2018 08:17:38 -0000 On Tue, Apr 10, 2018 at 09:13:36AM +0300, Shahaf Shuler wrote: > Following commit 7ba5320baa32 ("net/mlx5: fix link status behavior") > The initial link status is no longer set as part of the port start. > > When LSC interrupts are enabled, ethdev layer reads the link status > directly from the device data instead of using the PMD callback. > This may cause application to query the link as down while in fact it was > already up before the DPDK application start (and no interrupt to fix > it). > > Fixes: 7ba5320baa32 ("net/mlx5: fix link status behavior") > Cc: nelio.laranjeiro@6wind.com > > Signed-off-by: Shahaf Shuler > Acked-by: Yongseok Koh > --- > > On v2: > - Reworded commit log. > - Cleared the wait_to_complete on the link update call. > > --- > drivers/net/mlx5/mlx5.c | 6 ++++++ > 1 file changed, 6 insertions(+) > > diff --git a/drivers/net/mlx5/mlx5.c b/drivers/net/mlx5/mlx5.c > index cfab558979..3d222df707 100644 > --- a/drivers/net/mlx5/mlx5.c > +++ b/drivers/net/mlx5/mlx5.c > @@ -991,6 +991,12 @@ mlx5_pci_probe(struct rte_pci_driver *pci_drv __rte_unused, > DRV_LOG(DEBUG, "port %u forcing Ethernet interface up", > eth_dev->data->port_id); > mlx5_set_link_up(eth_dev); > + /* > + * Even though the interrupt handler is not installed yet, > + * interrupts will still trigger on the asyn_fd from > + * Verbs context returned by ibv_open_device(). > + */ > + mlx5_link_update(eth_dev, 0); > /* Store device configuration on private structure. */ > priv->config = config; > continue; > -- > 2.12.0 You should have linked this patch with the ethdev one[1], if the ethdev is refused, this patch won't solve anything. With a reserves of acceptance of [1]: Acked-by: Nelio Laranjeiro Thanks, [1] https://dpdk.org/ml/archives/dev/2018-April/096387.html -- Nélio Laranjeiro 6WIND