From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f68.google.com (mail-wm0-f68.google.com [74.125.82.68]) by dpdk.org (Postfix) with ESMTP id DCF741B3DA for ; Tue, 30 Jan 2018 10:40:11 +0100 (CET) Received: by mail-wm0-f68.google.com with SMTP id 141so38815034wme.3 for ; Tue, 30 Jan 2018 01:40:11 -0800 (PST) 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:in-reply-to; bh=TBFvH2gyPlMa9MmMin52BfjVxNm7HmMbbz3ygvPeiME=; b=WWr/vDsQ3nfc8p9TwOJhmuCI9KHYGa1ZKX5YAULXetev9bzKWL27vlnMliMAyI9Qxs Ts/I4YW57GZ/4bspvfX3+U3ZB8beFhqswkMwGXoOxn2srseTZEFN7ZZ4bXjT13OJMy0B mdRJ+wZYvbYsWs3iru9eapG4ivRsOUtLG6fQX7hyZQVUy0+4as4W9y3rIKJYPFMAw6rf aBLvrUwnk/OdHJCwsy7etLmseJHRN64GOKPGWYPbVUMtE2wpEsuxcpDEpfAPDnsqFEP2 Db/wzJWOkJH6JNBvtDlo1lnaoQvMv7XEHlUk6Ibk45F23ewf8ovkXEgkL/S9cAikNYDr oDUw== 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:in-reply-to; bh=TBFvH2gyPlMa9MmMin52BfjVxNm7HmMbbz3ygvPeiME=; b=r6Q14BA2aO13sWi5O/UF2/pJyNtdmu5YMctvFFCIK/xfInrLebfH94BYtZZ5p45Ixl lVWCOi15nhvyaQOg7Le2wiYxKl+ZqTfp1qs5ad3TX8LGIAG7lG6JmD79nFMMHxT7C122 Aie3kEK+7SGgOAs0LgoBSBmF6EnwYbh2qmub2G0UcBQ24YiJEKOryCooVK2udy28wZDh rTOnqLhRt0Gfa55ZW1++nF6ppM4zYqqqraElc2CmGAJk7AVjmFtXCNbnyckaHHJR8Ole y/r0rP/+WmbEoMOimKDPu+bqOIPjTJfV67nh99kYpLx5Lc773psNuclu7SNuYpXr6Hhl Rj3w== X-Gm-Message-State: AKwxytfo+5sZPX+wztoDlu3KV6L2bd29QAG/B7j+CcpPOyWV3uhbOIK/ xitUfTxFtRCso+rKvhobhI5wmA== X-Google-Smtp-Source: AH8x227KJbGvgoqS1qVkqYFR63OaGZgWOHe7jcnNqxsMn5EhLc4ZWHG/KD2X3qV8vi32by1tt7bRCw== X-Received: by 10.28.4.84 with SMTP id 81mr19159599wme.150.1517305211603; Tue, 30 Jan 2018 01:40:11 -0800 (PST) Received: from 6wind.com (host.78.145.23.62.rev.coltfrance.com. [62.23.145.78]) by smtp.gmail.com with ESMTPSA id u98sm1253805wrc.69.2018.01.30.01.40.10 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 30 Jan 2018 01:40:10 -0800 (PST) Date: Tue, 30 Jan 2018 10:39:58 +0100 From: Adrien Mazarguil To: Shahaf Shuler Cc: Mordechay Haimovsky , "dev@dpdk.org" , "stable@dpdk.org" Message-ID: <20180130093958.GE4256@6wind.com> References: <1516357009-15463-1-git-send-email-motih@mellanox.com> <1517214877-126768-1-git-send-email-motih@mellanox.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Subject: Re: [dpdk-dev] [PATCH v3] net/mlx4: fix dev rmv not detected after port stop 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, 30 Jan 2018 09:40:12 -0000 Hi, On Mon, Jan 29, 2018 at 10:54:16AM +0000, Shahaf Shuler wrote: > Mordechay Haimovsky, Monday, January 29, 2018 10:35 AM: > > In failsafe device start can be called for ports/devices that had been plugged > > out. > > The mlx4 PMD detects device removal by listening to the device RMV events, > > when the mlx4 port is being stopped, the PMD no longer listens to these > > events causing the PMD to stop detecting device removals. > > This patch fixes this issue by moving installation of the interrupt handler to > > device configuration, and toggle only the Rx-queue interrupts on start/stop. > > > > Fixes: a6e8b01c3c26 ("net/mlx4: compact interrupt functions") > > Cc: stable@dpdk.org > > > > Signed-off-by: Moti Haimovsky > > --- > > V3: > > Modifications according to review inputs from Shahaf Shuler > > See: 1516357009-15463-1-git-send-email-motih@mellanox.com > > > > V2: > > Fixed commit message. > > --- > > > > drivers/net/mlx4/mlx4.c | 10 ++++++++-- > > drivers/net/mlx4/mlx4.h | 2 ++ > > drivers/net/mlx4/mlx4_intr.c | 41 > > ++++++++++++++++++++++++++++++++++++++--- > > 3 files changed, 48 insertions(+), 5 deletions(-) > > > > Acked-by: Shahaf Shuler > > Adrien - let me know if you see issues with this patch, I want to include it on RC2. Unfortunately I didn't get a chance to review this patch before it was applied. I'm not sure a stopped port is supposed to report events (interrupts). Will applications expect them to occur at this point? In my opinion it's not a fix, as in, it doesn't address an issue introduced by the mentioned patch whose behavior was correct. It's probably too late to change it now and it does address an issue seen with a use case involving this PMD, however I think the fail-safe PMD could as well poll using the recently-added rte_eth_dev_is_removed() when it's aware the underlying port is stopped instead of expecting interrupts. -- Adrien Mazarguil 6WIND