Received: by 10.223.185.116 with SMTP id b49csp6358555wrg; Wed, 28 Feb 2018 08:07:47 -0800 (PST) X-Google-Smtp-Source: AH8x225sYU0CkauNxMmAEsrQXXV+kW7VWHFweCfL7TC2BtVrtV01IyTrtn9NntliYRockDPduJCc X-Received: by 10.98.61.133 with SMTP id x5mr18282040pfj.181.1519834067558; Wed, 28 Feb 2018 08:07:47 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1519834067; cv=none; d=google.com; s=arc-20160816; b=YHmi/B37ZBurWM7coausM1AO2jQmAj93HwvX5FXVOBhYQEjx4ie5fVpSSxJKMoRNR7 gQckyObOT2IlOklxKS0cWNiTkL1+E3nMw7pMUiaiQQk4UmfOihTHXqCXPc4+/iFMDkn7 GUHLLefAhSLOE73ScmxtMP/zz/c4QDFpcBB7gJeLhi8pIGvenmCU6x3RRBnOmg3F1y8M d+PFFdYyGRMYM2or0HczIfTflUA/72GMGlH69oluCwI4dvLU2oAvu02t9ggNQJ4t11Q1 UYlKnF7WBY3IZN//bt+O+8E63G3EB3n777YvOv50t0+nPEZdozBzwbT4zALR89Ij12qL mhUQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:subject:message-id:date:cc:to :from:mime-version:content-transfer-encoding:content-disposition :arc-authentication-results; bh=EzTwYMe0yLuC7SBE/C42zhpcAbWM2FMOhovddtQKxj4=; b=F9X+GNm1jQmslvNpuBYUa6iCda5h7fTY25SUZu7bViio0svt3zbnqx+bicFDgn1LnG jUiUfmryFHhpLN76c4Q86xKlkWMYW3hf7/e+2aZN6ejxL9SjzljWWYRkktagBcOxHDdK aKKbVin87nV/a5JxifhMMOuT7z2WlEg2EtfippL0s+atuozbN1Gy8r/QgWQUfEklG+6i YNp9WrJbQ1lYFcg0HbCgMTB0TpM6846tzXFxZ/rWzaEHN8X732d/lhNynczWUoo92HVJ IDjTtMT57+PIhH6S8tNvKfP4vAOqItmnEoQ0dRznXEkjWMkSF/c7XKQeSVuWSjfqvusY AMKw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 31-v6si1471809plk.699.2018.02.28.08.07.32; Wed, 28 Feb 2018 08:07:47 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934579AbeB1QGW (ORCPT + 99 others); Wed, 28 Feb 2018 11:06:22 -0500 Received: from shadbolt.e.decadent.org.uk ([88.96.1.126]:34900 "EHLO shadbolt.e.decadent.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752742AbeB1QFj (ORCPT ); Wed, 28 Feb 2018 11:05:39 -0500 Received: from [2a02:8011:400e:2:6f00:88c8:c921:d332] (helo=deadeye) by shadbolt.decadent.org.uk with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1er3Ys-0006Xf-HC; Wed, 28 Feb 2018 15:22:30 +0000 Received: from ben by deadeye with local (Exim 4.90_1) (envelope-from ) id 1er3Yh-00008J-Cv; Wed, 28 Feb 2018 15:22:19 +0000 Content-Type: text/plain; charset="UTF-8" Content-Disposition: inline Content-Transfer-Encoding: 8bit MIME-Version: 1.0 From: Ben Hutchings To: linux-kernel@vger.kernel.org, stable@vger.kernel.org CC: akpm@linux-foundation.org, "Saeed Mahameed" , "Moshe Shemesh" Date: Wed, 28 Feb 2018 15:20:18 +0000 Message-ID: X-Mailer: LinuxStableQueue (scripts by bwh) Subject: [PATCH 3.16 135/254] net/mlx5: Stay in polling mode when command EQ destroy fails In-Reply-To: X-SA-Exim-Connect-IP: 2a02:8011:400e:2:6f00:88c8:c921:d332 X-SA-Exim-Mail-From: ben@decadent.org.uk X-SA-Exim-Scanned: No (on shadbolt.decadent.org.uk); SAEximRunCond expanded to false Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 3.16.55-rc1 review patch. If anyone has any objections, please let me know. ------------------ From: Moshe Shemesh commit a2fba188fd5eadd6061bef4f2f2577a43231ebf3 upstream. During unload, on mlx5_stop_eqs we move command interface from events mode to polling mode, but if command interface EQ destroy fail we move back to events mode. That's wrong since even if we fail to destroy command interface EQ, we do release its irq, so no interrupts will be received. Fixes: e126ba97dba9 ("mlx5: Add driver for Mellanox Connect-IB adapters") Signed-off-by: Moshe Shemesh Signed-off-by: Saeed Mahameed Signed-off-by: Ben Hutchings --- drivers/net/ethernet/mellanox/mlx5/core/eq.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) --- a/drivers/net/ethernet/mellanox/mlx5/core/eq.c +++ b/drivers/net/ethernet/mellanox/mlx5/core/eq.c @@ -502,11 +502,9 @@ void mlx5_stop_eqs(struct mlx5_core_dev mlx5_cmd_use_polling(dev); err = mlx5_destroy_unmap_eq(dev, &table->cmd_eq); - if (err) { + if (err) mlx5_core_err(dev, "failed to destroy command eq, err(%d)\n", err); - mlx5_cmd_use_events(dev); - } } int mlx5_core_eq_query(struct mlx5_core_dev *dev, struct mlx5_eq *eq,