Received: by 10.223.185.116 with SMTP id b49csp1082378wrg; Wed, 21 Feb 2018 11:48:08 -0800 (PST) X-Google-Smtp-Source: AH8x225DTg1KL8MBDZSyzK1OpM5ZJ3ScCPHgg9GOsqURkE1KijcvsHMJYpwTQgRJIdYkCSwkWg5P X-Received: by 10.101.93.82 with SMTP id e18mr3526419pgt.371.1519242488065; Wed, 21 Feb 2018 11:48:08 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1519242488; cv=none; d=google.com; s=arc-20160816; b=EpPp/ZY/OOJZnYjLmHNcZKjFnefFOVCxzZc6Eyru2AZEUrx4EiLFuhmectAUPeijBW eUBOK2V6AtP7hCapandnos2F5NZP2fZwMSjgBiFAFswmwbPhUEJhuFrpH3BGTWfw1vTY revApc0681p01y3ChwFkM6w+c46+s3qWKZfVhdT6zR8tjN4i/X81emF+zHG21tD6kR2G t4GImCNZg5zwtANkXgo0TnYVgdJEez9Dp+jdNb32f/hYedzARFX8EDHSzRTOYKcqcOce EMYi6gSK8ZakgaASEo7HP/B7r5MueN53S5fAEQ/C7C+r+K8qTgs2AXed+IZ/DQcUiwGM StkQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:message-id:date:subject:cc:to:from :arc-authentication-results; bh=6b1yBe1TzyaBojziohlHxfHf4w6L1r9JX3Dpdpa3jrA=; b=uLX9i+1IWU7uW0qnGvbnX4o1ILcctyMRHrqa8CWSWT9vCDfyVvYISGi113bQ2S3ypb lXYm3Mllt7Ik+60+2rKHtvzBdwetcSC5XCtBfeESNsGNKrQRYUg16FpVlRAORsJbRAbb dqhCPzoKwYV/Cj/ZuRKQsFT11aXP3tkjFY+D8XfrJI3CiD0ZjbvVsoBjY4osibeefWhO iI4v0fNAnthHzXT8l4kic+qsMIhWCWO1KE9YGAUPwLLiLv9WPhVc0h9HrM+5tJYv7ali 1mAQq+Ix4IrCTTHmqH4WvgfCnYzbQFhi/Kjsvf11BFkaHLhX/MG3oFyotjpqYzT71oSn sdqA== 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 8si2628862pfn.80.2018.02.21.11.47.54; Wed, 21 Feb 2018 11:48:08 -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 S936288AbeBUNLD (ORCPT + 99 others); Wed, 21 Feb 2018 08:11:03 -0500 Received: from mail.linuxfoundation.org ([140.211.169.12]:44244 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S936274AbeBUNK7 (ORCPT ); Wed, 21 Feb 2018 08:10:59 -0500 Received: from localhost (LFbn-1-12258-90.w90-92.abo.wanadoo.fr [90.92.71.90]) by mail.linuxfoundation.org (Postfix) with ESMTPSA id 42C0F1060; Wed, 21 Feb 2018 13:10:17 +0000 (UTC) From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Logan Gunthorpe , Max Gurtovoy , Sagi Grimberg , Doug Ledford Subject: [PATCH 4.15 104/163] mlx5: fix mlx5_get_vector_affinity to start from completion vector 0 Date: Wed, 21 Feb 2018 13:48:53 +0100 Message-Id: <20180221124536.020253137@linuxfoundation.org> X-Mailer: git-send-email 2.16.2 In-Reply-To: <20180221124529.931834518@linuxfoundation.org> References: <20180221124529.931834518@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.15-stable review patch. If anyone has any objections, please let me know. ------------------ From: Sagi Grimberg commit 2572cf57d75a7f91835d9a38771e9e76d575d122 upstream. The consumers of this routine expects the affinity map of of vector index relative to the first completion vector. The upper layers are not aware of internal/private completion vectors that mlx5 allocates for its own usage. Hence, return the affinity map of vector index relative to the first completion vector. Fixes: 05e0cc84e00c ("net/mlx5: Fix get vector affinity helper function") Reported-by: Logan Gunthorpe Tested-by: Max Gurtovoy Reviewed-by: Max Gurtovoy Cc: # v4.15 Signed-off-by: Sagi Grimberg Signed-off-by: Doug Ledford Signed-off-by: Greg Kroah-Hartman --- include/linux/mlx5/driver.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/include/linux/mlx5/driver.h +++ b/include/linux/mlx5/driver.h @@ -1238,7 +1238,7 @@ mlx5_get_vector_affinity(struct mlx5_cor int eqn; int err; - err = mlx5_vector2eqn(dev, vector, &eqn, &irq); + err = mlx5_vector2eqn(dev, MLX5_EQ_VEC_COMP_BASE + vector, &eqn, &irq); if (err) return NULL;