From mboxrd@z Thu Jan 1 00:00:00 1970 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 7F53BEB64D7 for ; Tue, 20 Jun 2023 17:04:24 +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:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=qZiv5AlotiaoW934zStrUeFqHlJInHXlWIb7Do8AovY=; b=3ChyPqKUh8R/p5 1NPjfsoreoO18oHaYjSrsqE4+Y6dkXxhjp7Uqi3Ah1PJDdX2eyVJcU7CGlvebjp2pPp6TUSN+lgy3 9CqhnfMYTfgUCxtkjkUt/d9jRI2R5jtx00xxTa5nHN9kzTkmihi7Ym7YsdJSaDkSmFRa1pzZ59EN2 k9NaBalLQLCCSmfiZqh4xXdSzPUn9X8PkEOTb9E3Xjar+nrVW0dUNCc2d4vJPZQz0KV/CC0bIJBCm jydA/l0uIi3cuQRC7f87A8nAT2WyzAdZ9NMNVXQ7nFuOZ3zWI5MXRSdypO9XEIwC0ddCZVJwGLNYU rpKwWbyfZIc+zZn0LG+Q==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qBelr-00Bstx-0U; Tue, 20 Jun 2023 17:03:59 +0000 Received: from mail-il1-f173.google.com ([209.85.166.173]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qBeln-00BstQ-1y for linux-arm-kernel@lists.infradead.org; Tue, 20 Jun 2023 17:03:57 +0000 Received: by mail-il1-f173.google.com with SMTP id e9e14a558f8ab-340bdf36dd9so19322335ab.3 for ; Tue, 20 Jun 2023 10:03:55 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1687280634; x=1689872634; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=HCxVkIs3pUGBG0JtGXoEayTlvQd9BiV5q7V3iQO4g6s=; b=aSe6d+rF+acgOjxg3o0fJGMndXo0AtHXUkrPo848u+DjkuhAAKyXxWX9VI+Ge5U6TP rzoWyH4xAL7KZvTClgmjcHbPxXtX2UChfMfSm4OqHjB3uTJffzGm7Np3n9BGuqxl/3U6 DgMZKqI9S2yFvFlk4hzUkm+uBhFVtf2Qt1FGHw13+1VhFIivsvAwOKE+kLK22jVYnKFw TYZBEwrA5yX/+5nlfR7DEhSwiRXqDPO04pjqVuUUedv/amUdVc6s9RwOAol0HZR+GaAe AjYWPaDNAB9/QK9bZxbxJsSFHwwdLYReGotv3e50JwaNUShYfe3GNanOl3NJffoaOdMw 1dEQ== X-Gm-Message-State: AC+VfDw5wx56oa+a+hVq+ObCRy0bKHNBOjOLvpx8oane3Q/ZXIkJ0sZJ Aiq7AHQ1BwM/8PxzZCSU5g== X-Google-Smtp-Source: ACHHUZ4es3Xqrn8GhEVk3UEKhL4IF8fsqsNITMRianUevVLqC4oKI3MpQ9s+qp6ckJXM7LEiHikbYQ== X-Received: by 2002:a92:d78d:0:b0:33b:2ea9:9f8e with SMTP id d13-20020a92d78d000000b0033b2ea99f8emr4089408iln.12.1687280634282; Tue, 20 Jun 2023 10:03:54 -0700 (PDT) Received: from robh_at_kernel.org ([64.188.179.250]) by smtp.gmail.com with ESMTPSA id o12-20020a92d38c000000b00340b48d5347sm691159ilo.77.2023.06.20.10.03.52 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Jun 2023 10:03:53 -0700 (PDT) Received: (nullmailer pid 3827476 invoked by uid 1000); Tue, 20 Jun 2023 17:03:51 -0000 Date: Tue, 20 Jun 2023 11:03:51 -0600 From: Rob Herring To: Radhey Shyam Pandey Cc: andersson@kernel.org, mathieu.poirier@linaro.org, krzysztof.kozlowski+dt@linaro.org, conor+dt@kernel.org, michal.simek@amd.com, ben.levinsky@amd.com, tanmay.shah@amd.com, linux-remoteproc@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, git@amd.com Subject: Re: [PATCH] dt-bindings: remoteproc: add Tightly Coupled Memory (TCM) bindings Message-ID: <20230620170351.GA3815971-robh@kernel.org> References: <1686918865-2330677-1-git-send-email-radhey.shyam.pandey@amd.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <1686918865-2330677-1-git-send-email-radhey.shyam.pandey@amd.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230620_100355_673921_4CFCC49D X-CRM114-Status: GOOD ( 23.68 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Fri, Jun 16, 2023 at 06:04:25PM +0530, Radhey Shyam Pandey wrote: > Introduce bindings for TCM memory address space on AMD-xilinx Zynq > UltraScale+ platform. As of now TCM addresses are hardcoded in xilinx > remoteproc driver. This binding will help in defining TCM in device-tree > and make it's access platform agnostic and data-driven from the driver. > > Tightly-coupled memories(TCMs) are low-latency memory that provides > predictable instruction execution and predictable data load/store > timing. Each Cortex-R5F processor contains two 64-bit wide 64 KB memory > banks on the ATCM and BTCM ports, for a total of 128 KB of memory. > > In split mode, TCM resources(reg, ranges and power-domain) are documented > in each R5 node and in lockstep mode TCM resources are documented in any > of the R5 node. > > It also extends the examples for TCM split and lockstep modes. > > Signed-off-by: Radhey Shyam Pandey > --- > The inspiration for integrating TCM nodes in R5 nodes is taken from > "5ee79c2ed5bd dt-bindings: remoteproc: Add bindings for R5F subsystem > on TI K3 SoCs".Once the binding is reviewed/accepted will send out > driver changes in follow-up series. > --- > .../remoteproc/xlnx,zynqmp-r5fss.yaml | 86 +++++++++++++++++-- > 1 file changed, 81 insertions(+), 5 deletions(-) > > diff --git a/Documentation/devicetree/bindings/remoteproc/xlnx,zynqmp-r5fss.yaml b/Documentation/devicetree/bindings/remoteproc/xlnx,zynqmp-r5fss.yaml > index 9f677367dd9f..0bc3a8bb8374 100644 > --- a/Documentation/devicetree/bindings/remoteproc/xlnx,zynqmp-r5fss.yaml > +++ b/Documentation/devicetree/bindings/remoteproc/xlnx,zynqmp-r5fss.yaml > @@ -20,6 +20,12 @@ properties: > compatible: > const: xlnx,zynqmp-r5fss > > + "#address-cells": > + const: 1 > + > + "#size-cells": > + const: 1 If these are translatable addresses, then you are missing 'ranges'. > + > xlnx,cluster-mode: > $ref: /schemas/types.yaml#/definitions/uint32 > enum: [0, 1, 2] > @@ -37,7 +43,7 @@ properties: > 2: single cpu mode > > patternProperties: > - "^r5f-[a-f0-9]+$": > + "^r5f(.*)+$": That's just '^r5f'. If adding a unit-address is what you want then make the regex define that: "^r5f(@[0-9a-f]+|-[a-f0-9]+)$" > type: object > description: | > The RPU is located in the Low Power Domain of the Processor Subsystem. > @@ -54,8 +60,27 @@ patternProperties: > compatible: > const: xlnx,zynqmp-r5f > > + "#address-cells": > + const: 1 > + > + "#size-cells": > + const: 1 These (and ranges) apply to child nodes, but you don't have any at this level. > + > + reg: > + items: > + - description: Address and Size of the ATCM internal memory region > + - description: Address and Size of the BTCM internal memory region > + > + reg-names: > + items: > + - const: atcm > + - const: btcm > + > + ranges: true > + > power-domains: > - maxItems: 1 > + minItems: 1 > + maxItems: 3 > > mboxes: > minItems: 1 > @@ -112,13 +137,64 @@ additionalProperties: false > > examples: > - | > + #include > + > + //Split mode configuration > + remoteproc { > + compatible = "xlnx,zynqmp-r5fss"; > + xlnx,cluster-mode = <0>; > + > + #address-cells = <1>; > + #size-cells = <1>; > + r5f_0: r5f@ffe00000 { > + compatible = "xlnx,zynqmp-r5f"; > + #address-cells = <1>; > + #size-cells = <1>; > + reg = <0xffe00000 0x10000>, <0xffe20000 0x10000>; > + reg-names = "atcm", "btcm"; > + ranges = <0x0 0xffe00000 0x10000>, <0x20000 0xffe20000 0x10000>; > + power-domains = <&zynqmp_firmware PD_RPU_0>, > + <&zynqmp_firmware PD_R5_0_ATCM>, > + <&zynqmp_firmware PD_R5_0_BTCM>; > + memory-region = <&rproc_0_fw_image>, <&rpu0vdev0buffer>, <&rpu0vdev0vring0>, <&rpu0vdev0vring1>; > + mboxes = <&ipi_mailbox_rpu0 0>, <&ipi_mailbox_rpu0 1>; > + mbox-names = "tx", "rx"; > + }; > + > + r5f_1: r5f@ffe90000 { > + compatible = "xlnx,zynqmp-r5f"; > + #address-cells = <1>; > + #size-cells = <1>; > + reg = <0xffe90000 0x10000>, <0xffeb0000 0x10000>; > + reg-names = "atcm", "btcm"; > + ranges = <0x0 0xffe90000 0x10000>, <0x20000 0xffeb0000 0x10000>; > + power-domains = <&zynqmp_firmware PD_RPU_1>, > + <&zynqmp_firmware PD_R5_1_ATCM>, > + <&zynqmp_firmware PD_R5_1_BTCM>; > + memory-region = <&rproc_1_fw_image>, <&rpu1vdev0buffer>, <&rpu1vdev0vring0>, <&rpu1vdev0vring1>; > + mboxes = <&ipi_mailbox_rpu1 0>, <&ipi_mailbox_rpu1 1>; > + mbox-names = "tx", "rx"; > + }; > + }; > + > + - | > + //Lockstep configuration > remoteproc { > compatible = "xlnx,zynqmp-r5fss"; > xlnx,cluster-mode = <1>; > > - r5f-0 { > + #address-cells = <1>; > + #size-cells = <1>; > + r5f_00: r5f@ffe00000 { > compatible = "xlnx,zynqmp-r5f"; > - power-domains = <&zynqmp_firmware 0x7>; > + #address-cells = <1>; > + #size-cells = <1>; > + reg = <0xffe00000 0x20000>, <0xffe20000 0x20000>; > + reg-names = "atcm", "btcm"; > + ranges = <0x0 0xffe00000 0x20000>, <0x20000 0xffe20000 0x20000>; > + power-domains = <&zynqmp_firmware PD_RPU_0>, > + <&zynqmp_firmware PD_R5_0_ATCM>, > + <&zynqmp_firmware PD_R5_0_BTCM>; > memory-region = <&rproc_0_fw_image>, <&rpu0vdev0buffer>, <&rpu0vdev0vring0>, <&rpu0vdev0vring1>; > mboxes = <&ipi_mailbox_rpu0 0>, <&ipi_mailbox_rpu0 1>; > mbox-names = "tx", "rx"; > @@ -126,7 +202,7 @@ examples: > > r5f-1 { > compatible = "xlnx,zynqmp-r5f"; > - power-domains = <&zynqmp_firmware 0x8>; > + power-domains = <&zynqmp_firmware PD_RPU_1>; > memory-region = <&rproc_1_fw_image>, <&rpu1vdev0buffer>, <&rpu1vdev0vring0>, <&rpu1vdev0vring1>; > mboxes = <&ipi_mailbox_rpu1 0>, <&ipi_mailbox_rpu1 1>; > mbox-names = "tx", "rx"; > -- > 2.25.1 > _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel