Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp117765yba; Mon, 1 Apr 2019 03:01:52 -0700 (PDT) X-Google-Smtp-Source: APXvYqxiumVQu6Wt3gZ9mXU3u/74LGOSXd4t0zXKVAfBH6QmEbXRu3DoFG8i9QpEIuTyTPtD3wic X-Received: by 2002:a62:e50a:: with SMTP id n10mr38722667pff.55.1554112912708; Mon, 01 Apr 2019 03:01:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1554112912; cv=none; d=google.com; s=arc-20160816; b=UTjx1SF0hMGj35AXWoBrQYpl6wfYwNLLX8Z1AXHaWCsJfn4MrabNH4xo4YzL3qZ24y brwNaC23muhvo3evHLSW6TBqYN8/VrZrxo9AQ+xTi2Y6fghWxAKSFRI6zS36pF5yt389 c2bTaybKDgbXFqxxteCv2MkhZOtm+kgqsHKcVvf/wJzqylo7Wp19NoWByxJC4ZU497+C k2e+p6t41MZWp+0RmSmaAkvmgylUs0R12DFxAQB08B0EQsz0OqxGt0ju2TlnCOvr55u8 dl/GbVZNJPgrxztZMJxwJGuDX1eZ+58XqFNJJUwKfRYVXdR1R6Oa0twm9fvjNfI+qmLv V6tQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=SozgHwOTJsFlCOJnhRC461LTZhrzZax2HAIVYd8DwPw=; b=RD1JZFfwtvNmEZCrWwYL+GjpP78hCn8N+BqTGfGt9OH2xMIHfwgkzNPJWbUpeVUB30 Fq0/SAkOsHaNwGSpsKnRhjqTfi8E9PMkcHE6pK1nhMHmmKWFjVi3WmxWRez/mSYfDvAD jGYg0AojCE4SxTGKKYehQC9WB0oHBiPL793LFLZNsJm+WYqpB5epSZ8L4op+pdxa5xt2 AaRexroORMoyTofslAlVQyQmBITdbRZsOF83f5MauUUfn+L00zNCqEPbJVezrMXeu7cm kgpujACHq32J6VqQnpF/8hvJbyj2RGdWwSI2g0G71d1b/xqM7MGDogNIkeSD4tQ41ey4 oL9A== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t21si8191679plr.366.2019.04.01.03.01.36; Mon, 01 Apr 2019 03:01:52 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726163AbfDAKBC (ORCPT + 99 others); Mon, 1 Apr 2019 06:01:02 -0400 Received: from foss.arm.com ([217.140.101.70]:59718 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725882AbfDAKBB (ORCPT ); Mon, 1 Apr 2019 06:01:01 -0400 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.72.51.249]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id D54F1A78; Mon, 1 Apr 2019 03:01:00 -0700 (PDT) Received: from [10.1.196.69] (e112269-lin.cambridge.arm.com [10.1.196.69]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 49BA23F690; Mon, 1 Apr 2019 03:00:59 -0700 (PDT) Subject: Re: [PATCH v4] dt-bindings: gpu: add bindings for the ARM Mali Bifrost GPU To: Neil Armstrong , daniel@ffwll.ch, robh@kernel.org Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-amlogic@lists.infradead.org, linux-arm-kernel@lists.infradead.org References: <20190401080949.14550-1-narmstrong@baylibre.com> From: Steven Price Message-ID: <1640dd7b-3576-d9ce-0641-6b6a64a87275@arm.com> Date: Mon, 1 Apr 2019 11:00:57 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.5.1 MIME-Version: 1.0 In-Reply-To: <20190401080949.14550-1-narmstrong@baylibre.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-GB Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 01/04/2019 09:09, Neil Armstrong wrote: > Add the bindings for the Bifrost family of ARM Mali GPUs. > > The Bifrost GPU architecture is similar to the Midgard family, > but with a different Shader Core & Execution Engine structures. > > Bindings are based on the Midgard family bindings, but the inner > architectural changes makes it a separate family needing separate > bindings. > > The Bifrost GPUs are present in a number of recent SoCs, like the > Amlogic G12A Family, and many other vendors. > The Amlogic vendor specific compatible is added to handle the > specific IP integration differences and dependencies. > > Signed-off-by: Neil Armstrong > --- > .../bindings/gpu/arm,mali-bifrost.txt | 92 +++++++++++++++++++ > 1 file changed, 92 insertions(+) > create mode 100644 Documentation/devicetree/bindings/gpu/arm,mali-bifrost.txt > > Changes since v3: > - Added note about discoverable model/revision > - Enforced fixed defined irq order > - Fixed typo in accommodate > > Changes since v2: > - moved to a single compatible since HW is fully discoverable > > diff --git a/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.txt b/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.txt > new file mode 100644 > index 000000000000..711c9ead17a2 > --- /dev/null > +++ b/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.txt > @@ -0,0 +1,92 @@ > +ARM Mali Bifrost GPU > +==================== > + > +Required properties: > + > +- compatible : > + * Since Mali Bifrost GPU model/revision if fully discoverable by reading ^^ s/if/is/ > + some determined registers, must contain the following: > + + "arm,mali-bifrost" > + * which must be preceded by one of the following vendor specifics: > + + "amlogic,meson-g12a-mali" > + > +- reg : Physical base address of the device and length of the register area. > + > +- interrupts : Contains the three IRQ lines required by Mali Bifrost devices, > + in the following defined order. > + > +- interrupt-names : Contains the names of IRQ resources in this exact defined > + order: "job", "mmu", "gpu". Is there any point in having "interrupt-names" if we're fixing the order? Although I guess it helps match the Midgard bindings. Steve > + > +Optional properties: > + > +- clocks : Phandle to clock for the Mali Bifrost device. > + > +- mali-supply : Phandle to regulator for the Mali device. Refer to > + Documentation/devicetree/bindings/regulator/regulator.txt for details. > + > +- operating-points-v2 : Refer to Documentation/devicetree/bindings/opp/opp.txt > + for details. > + > +- resets : Phandle of the GPU reset line. > + > +Vendor-specific bindings > +------------------------ > + > +The Mali GPU is integrated very differently from one SoC to > +another. In order to accommodate those differences, you have the option > +to specify one more vendor-specific compatible, among: > + > +- "amlogic,meson-g12a-mali" > + Required properties: > + - resets : Should contain phandles of : > + + GPU reset line > + + GPU APB glue reset line > + > +Example for a Mali-G31: > + > +gpu@ffa30000 { > + compatible = "amlogic,meson-g12a-mali", "arm,mali-bifrost"; > + reg = <0xffe40000 0x10000>; > + interrupts = , > + , > + ; > + interrupt-names = "job", "mmu", "gpu"; > + clocks = <&clk CLKID_MALI>; > + mali-supply = <&vdd_gpu>; > + operating-points-v2 = <&gpu_opp_table>; > + resets = <&reset RESET_DVALIN_CAPB3>, <&reset RESET_DVALIN>; > +}; > + > +gpu_opp_table: opp_table0 { > + compatible = "operating-points-v2"; > + > + opp@533000000 { > + opp-hz = /bits/ 64 <533000000>; > + opp-microvolt = <1250000>; > + }; > + opp@450000000 { > + opp-hz = /bits/ 64 <450000000>; > + opp-microvolt = <1150000>; > + }; > + opp@400000000 { > + opp-hz = /bits/ 64 <400000000>; > + opp-microvolt = <1125000>; > + }; > + opp@350000000 { > + opp-hz = /bits/ 64 <350000000>; > + opp-microvolt = <1075000>; > + }; > + opp@266000000 { > + opp-hz = /bits/ 64 <266000000>; > + opp-microvolt = <1025000>; > + }; > + opp@160000000 { > + opp-hz = /bits/ 64 <160000000>; > + opp-microvolt = <925000>; > + }; > + opp@100000000 { > + opp-hz = /bits/ 64 <100000000>; > + opp-microvolt = <912500>; > + }; > +}; >