Received: by 2002:a05:6a10:413:0:0:0:0 with SMTP id 19csp1796989pxp; Mon, 7 Mar 2022 02:33:31 -0800 (PST) X-Google-Smtp-Source: ABdhPJwVcGg5tq4R2bfVVY1oMGY3DUlJpgThAsO+4hancikOn65oSesgM/2P6JyVj2ttYjBvTOP8 X-Received: by 2002:a17:90a:348f:b0:1be:d738:9736 with SMTP id p15-20020a17090a348f00b001bed7389736mr24369115pjb.65.1646649211335; Mon, 07 Mar 2022 02:33:31 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1646649211; cv=none; d=google.com; s=arc-20160816; b=sxSQEg4jICdycNxpBp4f/bydn/yl95RAOwwEW7Nm1pfTfJEj5ruSMNbc1XcXesN1Pt +NFCZ7PSMZScqqeDK13sSnIymgmiC2725RuuyJiLVHwqFcOSmxwLQFEm+mIRqJhnA3G5 tHX3U7r7Oo1m1towSSSAea/xdmnDBr8OiIMaf3aXCmjUmPge5uhkBKP/txbx5go+bVgK oUHtFCgP6K+szLtTN+tAmJrSfQB6mV4+HSvQ0NSbs72NJ3AcNna8t8bRHLtgxygBItkc B+1BEez5IWJMXDyRJHfRhvnsuJDM/EqHmlK+Im3jSJKOLt072Ac9oGKoiI5pnbXjoPP3 whMg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=8taKngi0S/Eq4+V/UxTcL4CkGsUsqAAiMbEGv4jEGKU=; b=Pd5moYmK4C0jGkyqNrG8+HdOEkLdQh+sAaFYPPoUyc8hjkHX9mVffjm8lSFejsrQap efx7sIRll2lpdwn/EW837E9sfXz2CIxrv5GqW4X12IwZKSLbgCu3RHP3cOVBXXvuPS4P hxN2FHVDlZYYjt4i7qx2wU9WamYQlf3OyUUuybqtWEuJ90ZcTwglwb3I+nOklIsUdg6o 7avUxPPLLcub+/uGUeJQ96HlwfifSQ3+6trI645CnSf5FMyIw4gCTtZvWRWhwwaoMDg+ aQ31xUY92uq9QVkBHXcpFYrVrUuL1o1kpgKQiVVzX/MQYdTH2XIyrS1RGSTGObhkcAI+ ViaA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=WuQMm6qa; 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=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id bg14-20020a056a001f8e00b004f6bf5efabbsi6865674pfb.198.2022.03.07.02.33.16; Mon, 07 Mar 2022 02:33:31 -0800 (PST) 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=@linuxfoundation.org header.s=korg header.b=WuQMm6qa; 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=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236741AbiCGKGD (ORCPT + 99 others); Mon, 7 Mar 2022 05:06:03 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57946 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238303AbiCGJpB (ORCPT ); Mon, 7 Mar 2022 04:45:01 -0500 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6EC7C65432; Mon, 7 Mar 2022 01:41:44 -0800 (PST) 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 EC64F612C9; Mon, 7 Mar 2022 09:41:43 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id E4053C340F3; Mon, 7 Mar 2022 09:41:42 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1646646103; bh=ZRudVY4cCl8/MQQO5V8VjUC2mo62hikaH/uo7E/qylE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=WuQMm6qa3dqfBS5uEaTT7yYFViHRx2O/T5d7UIL8aYlmRFDHC0E68bM8mKwWhXjsb 7YOeUPgUfDaCWigEJaZIfZTqV/rcPVQmUyv9u0ubH7YWoRGkw8KL+Q3Osmt86HaHLt n0y5l5NG1+XIR4pqqhqUU+Y//dBxSTzp7BuPXxUY= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Jeremy Pallotta , Kelvin Cao , Jon Mason , Sasha Levin Subject: [PATCH 5.15 084/262] ntb_hw_switchtec: Fix pff ioread to read into mmio_part_cfg_all Date: Mon, 7 Mar 2022 10:17:08 +0100 Message-Id: <20220307091704.855171721@linuxfoundation.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20220307091702.378509770@linuxfoundation.org> References: <20220307091702.378509770@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.6 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, 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 From: Jeremy Pallotta [ Upstream commit 32c3d375b0ed84b6acb51ae5ebef35ff0d649d85 ] Array mmio_part_cfg_all holds the partition configuration of all partitions, with partition number as index. Fix this by reading into mmio_part_cfg_all for pff. Fixes: 0ee28f26f378 ("NTB: switchtec_ntb: Add link management") Signed-off-by: Jeremy Pallotta Signed-off-by: Kelvin Cao Signed-off-by: Jon Mason Signed-off-by: Sasha Levin --- drivers/ntb/hw/mscc/ntb_hw_switchtec.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/ntb/hw/mscc/ntb_hw_switchtec.c b/drivers/ntb/hw/mscc/ntb_hw_switchtec.c index 4c6eb61a6ac62..6603c77c0a848 100644 --- a/drivers/ntb/hw/mscc/ntb_hw_switchtec.c +++ b/drivers/ntb/hw/mscc/ntb_hw_switchtec.c @@ -419,8 +419,8 @@ static void switchtec_ntb_part_link_speed(struct switchtec_ntb *sndev, enum ntb_width *width) { struct switchtec_dev *stdev = sndev->stdev; - - u32 pff = ioread32(&stdev->mmio_part_cfg[partition].vep_pff_inst_id); + u32 pff = + ioread32(&stdev->mmio_part_cfg_all[partition].vep_pff_inst_id); u32 linksta = ioread32(&stdev->mmio_pff_csr[pff].pci_cap_region[13]); if (speed) -- 2.34.1