From patchwork Mon May 27 09:37:13 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Conor Dooley X-Patchwork-Id: 13674962 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id A8417C25B74 for ; Mon, 27 May 2024 09:38:08 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-ID:Date:Subject:CC :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=RvVUYRs52y/+kH2CFemi+6ux626g8632wq8uS0tRlEs=; b=5HDc7VkxSSZYTS CLDTFs9TZa6KhtYfFUS+X/67jxKV1QBCAT1sAPUYZ+RsFuPZogCSeUQZaZTFmgvE/Mx4CJA52DxZn u43y9b54G+6lsWSkY+TI/S0xAOtRxNO2WvjGb8UH+me2kvmDflYfojwOCR1yChOhNuCzA1lG5bfQU xTiP8nBr/zpodyoD1ZVDrqRCnuhaHVjuKTAJ3TE6R0O6VlQ/XT8dqIc5CYc2XhDX4eIIfqqJ8VFat QvbQuRLa7aws/A7Dg8lq/9mxPQ2drx1yCP3uQ9sLBQLV6bpAzxlT9aVdIwEXKf4Wt3z6rmK5ST79f KOyzugXJDaSQPxJfWjag==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sBWnq-0000000ES5t-3FXr; Mon, 27 May 2024 09:38:02 +0000 Received: from esa.microchip.iphmx.com ([68.232.154.123]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sBWno-0000000ES4C-18cN for linux-riscv@lists.infradead.org; Mon, 27 May 2024 09:38:01 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=microchip.com; i=@microchip.com; q=dns/txt; s=mchp; t=1716802679; x=1748338679; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=XBN7++Zvn6jUh1suRjCaio6HybTeWQjWEhslD6Yd0b8=; b=Gd9Jv0C9yxKbhuiTauUkCjE11Ur3U6Jrpl3fkKm+hSRuotWeFqVFYIZP Ms7bekbPmb0sdH42Y0pritzXGVBwZenpB9avP/zXT/osHvhjVsQWhfeex y75n2n7618RnebapUHUFD9SCcjuovwFsLD06/E865z2pjDGDvBJNYXD/H I3ou3ehV+cduxse5+yth+VJj9rogip1Z0Njn07D2MduzvYa2kPbrUC8KH Yy0AFLGHXKmCbuVjs8soqYp9gltH9U15Yywt9s/19KfVLreohkfGJ7IFV rSdFdq1Byj16d80l3Gki36OLObBFtvHENMs0PMUhJFpjeYJ+0RkxkqFn8 g==; X-CSE-ConnectionGUID: AcSvwgxcR7OHBHrk8NTkiw== X-CSE-MsgGUID: 9VeZiux7QCa+8v7K5kzo2A== X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="193774875" X-Amp-Result: SKIPPED(no attachment in message) Received: from unknown (HELO email.microchip.com) ([170.129.1.10]) by esa6.microchip.iphmx.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 27 May 2024 02:37:55 -0700 Received: from chn-vm-ex02.mchp-main.com (10.10.85.144) by chn-vm-ex04.mchp-main.com (10.10.85.152) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.35; Mon, 27 May 2024 02:37:36 -0700 Received: from wendy.microchip.com (10.10.85.11) by chn-vm-ex02.mchp-main.com (10.10.85.144) with Microsoft SMTP Server id 15.1.2507.35 via Frontend Transport; Mon, 27 May 2024 02:37:34 -0700 From: Conor Dooley To: CC: , , Daire McNamara , Lorenzo Pieralisi , =?utf-8?q?Krzysztof_Wilczy=C5=84?= =?utf-8?q?ski?= , Rob Herring , Bjorn Helgaas , Krzysztof Kozlowski , Conor Dooley , , , , Subject: [PATCH v1 0/2] PCI: microchip: support using either instance 1 or 2 Date: Mon, 27 May 2024 10:37:13 +0100 Message-ID: <20240527-slather-backfire-db4605ae7cd7@wendy> X-Mailer: git-send-email 2.43.2 MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=1393; i=conor.dooley@microchip.com; h=from:subject:message-id; bh=XBN7++Zvn6jUh1suRjCaio6HybTeWQjWEhslD6Yd0b8=; b=owGbwMvMwCFWscWwfUFT0iXG02pJDGkhIV5Hb7ekJjy5yn61vjp/YpvsgyCxNZrvRef79E9Z3+6W 8uFhRykLgxgHg6yYIkvi7b4WqfV/XHY497yFmcPKBDKEgYtTACaiMpHhr5DDG46y3Zencpk4fFrxyy f147+COPmrgR+W7Www+D5dI56R4amTOremdfZq2zc19WvYBFssG2QYkieJsHKvE0pImxrIDQA= X-Developer-Key: i=conor.dooley@microchip.com; a=openpgp; fpr=F9ECA03CF54F12CD01F1655722E2C55B37CF380C X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240527_023800_453467_4A3BCAAB X-CRM114-Status: UNSURE ( 6.44 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-riscv@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-riscv" Errors-To: linux-riscv-bounces+linux-riscv=archiver.kernel.org@lists.infradead.org The current driver and binding for PolarFire SoC's PCI controller assume that the root port instance in use is instance 1. The second reg property constitutes the region encompassing both "control" and "bridge" registers for both instances. In the driver, a fixed offset is applied to find the base addresses for instance 1's "control" and "bridge" registers. The BeagleV Fire uses root port instance 2, so something must be done so that software can differentiate. This series splits the second reg property in two, with dedicated "control" and "bridge" entries so that either instance can be used. Cheers, Conor. CC: Daire McNamara CC: Lorenzo Pieralisi CC: Krzysztof WilczyƄski CC: Rob Herring CC: Bjorn Helgaas CC: Krzysztof Kozlowski CC: Conor Dooley CC: linux-pci@vger.kernel.org CC: devicetree@vger.kernel.org CC: linux-kernel@vger.kernel.org CC: linux-riscv@lists.infradead.org Conor Dooley (2): dt-bindings: PCI: microchip,pcie-host: fix reg properties PCI: microchip: rework reg region handing .../bindings/pci/microchip,pcie-host.yaml | 10 +- drivers/pci/controller/pcie-microchip-host.c | 159 +++++++++--------- 2 files changed, 83 insertions(+), 86 deletions(-)