Received: by 2002:a05:6a10:af89:0:0:0:0 with SMTP id iu9csp3721973pxb; Mon, 24 Jan 2022 16:19:20 -0800 (PST) X-Google-Smtp-Source: ABdhPJw1TFM83A4/PHONNNC128VqHBRqKhInNE8d6ljlCBX0lrBEnKXgX6WnIIjd1A1djmiaB9Xf X-Received: by 2002:a05:6a00:8c5:b0:4bc:4c7e:7742 with SMTP id s5-20020a056a0008c500b004bc4c7e7742mr16244856pfu.18.1643069960273; Mon, 24 Jan 2022 16:19:20 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1643069960; cv=none; d=google.com; s=arc-20160816; b=a1Od7haab/qtiLVx4oYH35MwotF0ziBCrLZfYY0Apacw9NJlvKtACyJ3Ja1ub4uzEb Nmh4BjzD8024nfWaCjG47+rHM222128UKTDsKsprHedeKkMAsGK68KCsR+NNz/UKxXKT AbpaTbscXdmXS8kGnPXJtGMqpvnB7YHFbDnYRdNbKpUtTD0kaMXFECW4j22WU9Qb/ACR bulO/wfocIXXanV/AkcqWT3S2WXFU04nmnANyo132izX4crBPcuVsLaZ+btSa447w3vA 2VvAP/4/yzwkYeGdmUj69FsC2ghlnj8BqeK6yKiaAyf8Ul5xLs8GNAncAdYpblfx/QC6 3axw== 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=utirooBJ+tSXW9QcFO7KWI2Y4xYYwU0Gt/Ah/EW8iS+zhB6dLsyGwykhbNTfZgHA9v Ic8sFtRyBjnqbYxOtdnOCQlONy4Skow1Aq98UQ8EhuypdibE+ECjS2JmqyC/Ny4xshCv 4dBw3mTzu/LRVzLj0H+DnwrFOIlb6ykOju2ZKX2NIgsdo6+/kRNncyH3PSqCt/WII2Z+ oF++70/QbBqsiBpDPXNMN5nXnpum5xoPHoHiaj5L0UTqwM32ggyfG1xpDpn0qMyc+ggf QEy0ZoU5E9JsHPGmETNWtYQD11pDODjnNdi5DtFx7JR/UToPjsd5jTe9L2jTmxjdXYiF iEEA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=OQDubghm; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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 vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id j62si11892477pge.93.2022.01.24.16.19.08; Mon, 24 Jan 2022 16:19:20 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=OQDubghm; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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 S2373287AbiAYANb (ORCPT + 99 others); Mon, 24 Jan 2022 19:13:31 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53498 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1841162AbiAXX2d (ORCPT ); Mon, 24 Jan 2022 18:28:33 -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 8FB87C075951; Mon, 24 Jan 2022 13:34:02 -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 2F88D61305; Mon, 24 Jan 2022 21:34:02 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0DAC8C340E4; Mon, 24 Jan 2022 21:34:00 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1643060041; bh=ZRudVY4cCl8/MQQO5V8VjUC2mo62hikaH/uo7E/qylE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=OQDubghmpfXcXk7zXNdKok0fI7mDKQpULL/tCqin1osYycLXS0Tr5MrDumPuVYclA CO97lsOmMeLAEnZNzFV717zS1xNzqnQ9MX/6nwymOhG7mSYoJ9EBZIxIRiLdhOKDwP PT4wSmodJw+umF4XDamUtAmRPtHKyF39qcN0L+xY= 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.16 0819/1039] ntb_hw_switchtec: Fix pff ioread to read into mmio_part_cfg_all Date: Mon, 24 Jan 2022 19:43:28 +0100 Message-Id: <20220124184152.831999577@linuxfoundation.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220124184125.121143506@linuxfoundation.org> References: <20220124184125.121143506@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 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