Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp1485104rwd; Wed, 31 May 2023 14:51:28 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7kYvqRocL8JtlIlbsc52+MTsmRPbBqZ9DC2N/Rb7UOz1jcjBM/rT7eY/uRGuUS0HzpmTMw X-Received: by 2002:a05:6808:2219:b0:398:5d75:c0ac with SMTP id bd25-20020a056808221900b003985d75c0acmr5710080oib.14.1685569888518; Wed, 31 May 2023 14:51:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1685569888; cv=none; d=google.com; s=arc-20160816; b=ekfEHcmaXKQltwo8+Ogjp4z8rQPfRSAfidSucMIfSKrhNlp9eZjbduZTllQCWzGPq3 pD0dbTzPd+LXwyXm6G1eIUqRh2MdRelgxL/jCAb23zddMFK2Qld6ughjm7Kok8xbFvGh I0axqt02F2qmEQKz7Om9R87QYdhc5NgpL6Y7B2qXELL+CzZbt7DUjr12qL9ZlLg6mtcp aGNB7mC7C+HMAE8f94QyDmNmFq3BP+QYnXBrJnCYZNKynDLE5ux4EbVArDeqGpxEwFJL p95ZAc+dEhAU1DYSeFDmsMCs17pQKj5SOT1TVUY8Cmz6tN1pP0UQandDFq68m4T9Ic7b 3lbw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=9MOHMGqYowSARRL7i3fom3rYAl0jSs14LoZMBmaRh8E=; b=NHTe8dSQ7BNknPzSayIWoRl53y2DlcZnXN0+UltW1ixPo7u98BmCSH2vg/mUm3yo01 8/pZ6xNyOMGnOg0ggLSn/LBcX/aJ8Qw0+Hha12rHDEZW055+Ju834SPMROP37OPZ9GzD 7RU/ERjmPuVdqR+JrnYm//lmJVM/DHw/C2L//ObjfLSlvvPk2WLV7o73sNNjuLakvk94 kl8fVkvC3WnifGrav5C5GPXUNrdar/XB3TUeSjnlYJBnXKjyMqI7emYDGWgWa5DOW6xF LTxGeC5pznBZl0TUwxByCxJl8Vz4JvihpLK2WgdZus3Rxdfkc1VfUx9aNaYw3acAIHtx gpIg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=FwdoOeCB; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id q4-20020a17090311c400b001aaf6228a70si500429plh.325.2023.05.31.14.50.49; Wed, 31 May 2023 14:51:28 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=FwdoOeCB; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229612AbjEaVtw (ORCPT + 99 others); Wed, 31 May 2023 17:49:52 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49432 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229714AbjEaVtt (ORCPT ); Wed, 31 May 2023 17:49:49 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 55049A0; Wed, 31 May 2023 14:49:48 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id DEBB763F6A; Wed, 31 May 2023 21:49:47 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 2AD04C433EF; Wed, 31 May 2023 21:49:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1685569787; bh=aGfdDi3uZnFkx6zkAyqIM68qZh/YHY0DCRpb2p1GQbk=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=FwdoOeCB63lBeSMjLIqrU3Yyd+wOuPyWsYHkQHketH1muZb8vLLUrsTZEAJyq9wo1 psA9yX89HZl14Mu0KftmkiiwfYtx5IAYOnTAbZAz8nrJw4A9uXwosaC9EXXeDkLvFR M8yykpXyL1+bJRYak6xkEFefjCcZURTSBxao+TyK+E0n84nKTSGMInWSBBELvzCvQ2 BuK6j1EuVAQlgHOeKgzV07VLd2QLhdmiJrv9p3sNOnl//7mnvIhBl78pho/Nm29zkA SWO7TSy+W8u7YOfi04pSpFbZzNleaRJ3+am9v1zmCoHpCQnS5ENFNcraZScor/kO/2 rE3wl1GtVe21g== Date: Wed, 31 May 2023 14:49:46 -0700 From: Saeed Mahameed To: =?iso-8859-1?Q?C=E9dric?= Le Goater Cc: Niklas Schnelle , Shay Drory , Saeed Mahameed , Eli Cohen , Leon Romanovsky , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , netdev@vger.kernel.org, linux-kernel@vger.kernel.org, linux-s390@vger.kernel.org, Mark Brown , Simon Horman , linux-rdma@vger.kernel.org Subject: Re: [PATCH net v2] net/mlx5: Fix setting of irq->map.index for static IRQ case Message-ID: References: <20230531084856.2091666-1-schnelle@linux.ibm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1; format=flowed Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: X-Spam-Status: No, score=-4.6 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 31 May 11:38, C?dric Le Goater wrote: >On 5/31/23 10:48, Niklas Schnelle wrote: >>When dynamic IRQ allocation is not supported all IRQs are allocated up >>front in mlx5_irq_table_create() instead of dynamically as part of >>mlx5_irq_alloc(). In the latter dynamic case irq->map.index is set >>via the mapping returned by pci_msix_alloc_irq_at(). In the static case >>and prior to commit 1da438c0ae02 ("net/mlx5: Fix indexing of mlx5_irq") >>irq->map.index was set in mlx5_irq_alloc() twice once initially to 0 and >>then to the requested index before storing in the xarray. After this >>commit it is only set to 0 which breaks all other IRQ mappings. >> >>Fix this by setting irq->map.index to the requested index together with >>irq->map.virq and improve the related comment to make it clearer which >>cases it deals with. >> >>Tested-by: Mark Brown >>Reviewed-by: Mark Brown >>Reviewed-by: Simon Horman >>Reviewed-by: Eli Cohen >>Fixes: 1da438c0ae02 ("net/mlx5: Fix indexing of mlx5_irq") >>Signed-off-by: Niklas Schnelle > Applied to net-mlx5. Thanks.