From patchwork Tue Feb 12 16:38:38 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Neil Armstrong X-Patchwork-Id: 10808273 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 84C801669 for ; Tue, 12 Feb 2019 16:38:50 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 6AB192C1F4 for ; Tue, 12 Feb 2019 16:38:50 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 688B62C211; Tue, 12 Feb 2019 16:38:50 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id B71962C1F4 for ; Tue, 12 Feb 2019 16:38:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject: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=yzCsMZ2+/AhHpPDArfaIBBmPx/LbHylmVh4K7twu89g=; b=dFswaZvpK/xR7q JZOc9lEVxZyB7XwgiXdPVXxPU5Tq8W1qhZZ0o7NnNivi/O/mSvHr0eiuc5sAp71Qt3yQn+Pzcb2WL zjAIGCqHfdxHUag19PmnDXVP+muq9WrM+RCaAsNWkI62Hbqq1nCHSbTRq53JhKn0E3iZ+2Iq0PXCU f9ckKwchOMFz1RZqAKwvV3ufTaKazhtGHA81XAGFJeqYO4BlmhT406UYEKJEekHMV34KrNHUceQz8 ePp16/8wqunA5hbeLmN5s5Vv1FvNYS2yTrBcATURqHHmd/OKpfBfz0FSzt5mWb4cIN+8b1OT0zACu XYRo0htoPtxF61voSurA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gtb56-000329-Vl; Tue, 12 Feb 2019 16:38:48 +0000 Received: from mail-wr1-x444.google.com ([2a00:1450:4864:20::444]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gtb54-00031W-4W for linux-amlogic@lists.infradead.org; Tue, 12 Feb 2019 16:38:48 +0000 Received: by mail-wr1-x444.google.com with SMTP id t27so3404568wra.6 for ; Tue, 12 Feb 2019 08:38:45 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=ClTUzezi3cfuWIoAAbFTrjOhNUbiBoeL1rpDXNmQzB4=; b=t45TfQUBTPQ+9tg2cFrO4qK/7DJLyUHFwlXzvpynxsp4PrnN/0h9ZjidtgSuF1xuMw i1WmiU+eQLrvqbJfTBEWVEJ+jxcJu44n3Qkefc07sC/pzAePq+zIYieXrUksRb30gNqb wy6gNLVd+YQXMFP1jIXR92XeoNcZ8xL6KK7olZp+VeYeWn2jiseLnDdKXDm33nmm0p5D OaU2xUthA+UJjSJ0UINM7zU7SVUmtkS/kF/6jwjs2NZddUQtk2RmHu+f+YMOg7bBLfW0 0S3mvIimyaHiU/Jwo72ANMpoXlfhKUolmRnbqZx3RKiH07eBYl7q3sIhYEapz9wGwi/6 iKdA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=ClTUzezi3cfuWIoAAbFTrjOhNUbiBoeL1rpDXNmQzB4=; b=PN8uzxt1CB2bA6zG09r1ou+OVTs/wOQQrDqyOn9i1BWThLKKsngDTkhIPpIgCBu08s i58weSsI8eUTKeIfYr3LRFu3Zc6WJef0wLeI5jlXbBRn4IYL26iLz2I4f+uoP1dLMF5S 619ik3+ZriPDnFFMPheS2thc6iWheYYw0xONRK/PAzkzdC8YmM6IzdPVDtzfxYlApITc tx08md1HDoxf87q1eLmR7LaIk7Jpg+sv0pPbMggoH7pEhmlyGfMvdFmZpgPPKlw4fqOK Q10UQHg4h6WcNy/E5s3pg8OOsoBtrp58zKcEk4DS4lxX4UxvBKGfu8FSzLZ4dk5wIrjZ 5Cog== X-Gm-Message-State: AHQUAub9hOlSXFiu591dChzeJdVJaJEIHnxw1/puk1Sx2eaC77P2seeP NJw9fNhfQb/qok59FVWAj+qTsg== X-Google-Smtp-Source: AHgI3IYKvyjBpIFDL2NL4yYJsmSAtaHCmuisSBlNRPvAGGCeHH/otyUc+Rht553ENztIiMblhDsiZQ== X-Received: by 2002:adf:eb07:: with SMTP id s7mr3670318wrn.158.1549989524502; Tue, 12 Feb 2019 08:38:44 -0800 (PST) Received: from bender.baylibre.local (lmontsouris-657-1-212-31.w90-63.abo.wanadoo.fr. [90.63.244.31]) by smtp.gmail.com with ESMTPSA id v6sm10325610wro.57.2019.02.12.08.38.43 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 12 Feb 2019 08:38:43 -0800 (PST) From: Neil Armstrong To: daniel@ffwll.ch Subject: [PATCH v2] dt-bindings: gpu: add bindings for the ARM Mali Bifrost GPU Date: Tue, 12 Feb 2019 17:38:38 +0100 Message-Id: <20190212163838.22644-1-narmstrong@baylibre.com> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190212_083846_188589_1D7D6433 X-CRM114-Status: GOOD ( 12.09 ) X-BeenThere: linux-amlogic@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, Neil Armstrong , linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-amlogic@lists.infradead.org, linux-arm-kernel@lists.infradead.org Sender: "linux-amlogic" Errors-To: linux-amlogic-bounces+patchwork-linux-amlogic=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP 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 --- Changes since v1: - adding missing G31 and G52 - fixed example .../bindings/gpu/arm,mali-bifrost.txt | 96 +++++++++++++++++++ 1 file changed, 96 insertions(+) create mode 100644 Documentation/devicetree/bindings/gpu/arm,mali-bifrost.txt 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..04a1d63ee578 --- /dev/null +++ b/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.txt @@ -0,0 +1,96 @@ +ARM Mali Bifrost GPU +==================== + +Required properties: + +- compatible : + * Must contain one of the following: + + "arm,mali-g31" + + "arm,mali-g51" + + "arm,mali-g52" + + "arm,mali-g71" + + "arm,mali-g72" + + "arm,mali-g76" + * 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. + +- interrupt-names : Contains the names of IRQ resources in the order they were + provided in the interrupts property. Must contain: "job", "mmu", "gpu". + + +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 accomodate 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-g31"; + 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>; + }; +};