From patchwork Fri Mar 15 13:56:54 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Neil Armstrong X-Patchwork-Id: 10854813 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 125341708 for ; Fri, 15 Mar 2019 13:57:06 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id EFC3A2A9F6 for ; Fri, 15 Mar 2019 13:57:05 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id E40BF2A9FA; Fri, 15 Mar 2019 13:57:05 +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,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id A2EC22A9F6 for ; Fri, 15 Mar 2019 13:57:05 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 3C3C76E425; Fri, 15 Mar 2019 13:57:03 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-wm1-x343.google.com (mail-wm1-x343.google.com [IPv6:2a00:1450:4864:20::343]) by gabe.freedesktop.org (Postfix) with ESMTPS id 9ABC36E425 for ; Fri, 15 Mar 2019 13:57:01 +0000 (UTC) Received: by mail-wm1-x343.google.com with SMTP id u10so3612457wmj.5 for ; Fri, 15 Mar 2019 06:57:01 -0700 (PDT) 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=DZcsemXvfglAUC0jGESedl+RTzmszV5G64pnxTWiH4g=; b=CZjsHKiJlBQl2lykTGOI6jkjLnldjjNa83FgHIrUPvRUnVQH+Ny7OLkUCZZZyDb9uC nPd1f8gdbe8VCBq+lORW6LX5u5turCoV0/JoRVbJg0qaOyyL0/LRbjfnXuNiZqzE/45Q ksf20NE7PiXupFkpx3HQu29IBQr/GRoLEB2fUV8vyJUUYl299J9T0KuEHX/YQy71mCqg p5tlPBfkRO+i26T+qOOgkul0Eqp/DW/mdIDJ9bQ0TM6EAbc0OcCIcT7a/QjyruLzDHKh OEdcB9pxwRWhAcKC+gukdEI3CAglM28BxTZ1EkDJ0Rep9sW2uJbb2KUwIp9MvtOYIYJ4 yyOw== X-Gm-Message-State: APjAAAVHyH5e7jy7HRgPevZyV2oxDeQKDJDrtqUeTc07Obk3QWRtV2V5 eIMQeulffrO6slyCyeupDcshfA== X-Google-Smtp-Source: APXvYqzLHSWXamSAChoX0YiQ6Kh+aI9iXLHASSTbYijTh2oD7ThGAS7omC/Urgn2DNOCC/Wkh3cGWA== X-Received: by 2002:a7b:cf27:: with SMTP id m7mr2232123wmg.80.1552658220083; Fri, 15 Mar 2019 06:57:00 -0700 (PDT) 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 a14sm2131900wrx.96.2019.03.15.06.56.58 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 15 Mar 2019 06:56:58 -0700 (PDT) From: Neil Armstrong To: devicetree@vger.kernel.org, khilman@baylibre.com, icenowy@aosc.io Subject: [PATCH v2 1/2] dt-bindings: gpu: mali-midgard: Add resets property Date: Fri, 15 Mar 2019 14:56:54 +0100 Message-Id: <20190315135655.28359-2-narmstrong@baylibre.com> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190315135655.28359-1-narmstrong@baylibre.com> References: <20190315135655.28359-1-narmstrong@baylibre.com> MIME-Version: 1.0 X-Mailman-Original-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:in-reply-to:references :mime-version:content-transfer-encoding; bh=DZcsemXvfglAUC0jGESedl+RTzmszV5G64pnxTWiH4g=; b=SfKmsVVC+drcRsqXUXJ6gvPIfn1f0k9kq04SPXA216aWmztGBUrCjafC40QyYDQpNb a26++I1pS+z5aAE6dkcL9WhceFW6xEYvu5w7Wl8KbhOIqGo5K0q9eKFgm6yzWK/uKqxD 4P5LjRKEEBbIWhBcqdnSxsvbnJQy2ANUpDbNNBez6K5LvN/8fMMTXcKn1ojzGQpWmN3W mGW5eF0CPP9U+/wOYjSOd2We8PtL6tEk3QJIpLsHvh5RLfEeSdm4qCENFrynm41sK8tJ ze/NUB1P5/y8vZbcacgq0Scwb9XxpUw1yVZaYzEm0wqZ00DOfjZJOibVEnrGuXL5ViX7 /Rqw== X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-amlogic@lists.infradead.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, dri-devel@lists.freedesktop.org, Neil Armstrong Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP The Amlogic ARM Mali Midgard requires reset controls to power on and software reset the GPU, adds these as optional in the bindings. Signed-off-by: Neil Armstrong Reviewed-by: Rob Herring --- .../devicetree/bindings/gpu/arm,mali-midgard.txt | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/Documentation/devicetree/bindings/gpu/arm,mali-midgard.txt b/Documentation/devicetree/bindings/gpu/arm,mali-midgard.txt index 18a2cde2e5f3..1b1a74129141 100644 --- a/Documentation/devicetree/bindings/gpu/arm,mali-midgard.txt +++ b/Documentation/devicetree/bindings/gpu/arm,mali-midgard.txt @@ -37,6 +37,20 @@ Optional properties: - 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-gxm-mali" + Required properties: + - resets : Should contain phandles of : + + GPU reset line + + GPU APB glue reset line Example for a Mali-T760: From patchwork Fri Mar 15 13:56:55 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Neil Armstrong X-Patchwork-Id: 10854817 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 F23621390 for ; Fri, 15 Mar 2019 13:57:07 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id D98C82A923 for ; Fri, 15 Mar 2019 13:57:07 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id CB2212A9F8; Fri, 15 Mar 2019 13:57:07 +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,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 7191C2A923 for ; Fri, 15 Mar 2019 13:57:07 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 906F96E427; Fri, 15 Mar 2019 13:57:04 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-wm1-x344.google.com (mail-wm1-x344.google.com [IPv6:2a00:1450:4864:20::344]) by gabe.freedesktop.org (Postfix) with ESMTPS id 86B406E425 for ; Fri, 15 Mar 2019 13:57:02 +0000 (UTC) Received: by mail-wm1-x344.google.com with SMTP id u10so3612494wmj.5 for ; Fri, 15 Mar 2019 06:57:02 -0700 (PDT) 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=Ox5dhzmGa/6JQDhw+Y9moNKLx34n2K2pj1pY4zKasYU=; b=osdlXSlS7XCHKWKdmgas27v/dbGBqQ0TSUvuf8agRh1EgsNaZyroVQgq/x9THOvHTV ddQ8z4XevKDd4h5jull2jsuMCjmcRCQynYXSmFlbecdP3SlljApYPCI4nX0+mxYjuqs7 HqHUYS+9rlXO+kipGNE1orCX6mOehgmongIaGMUW1petzPGxvDylssZpub/FKPxvm3Tc 5WzlIQEyT7MsXZKTy7jxcPt2YScQqzTKgndtQDL/yeoDIBtz3g8TlsEc46kgILJBoy1I yY8fD+Rbr9hiaHaja68QM0FAglieaTvBHYTwSozIVbNXU/zVmPz3VLELJPJsSqFThbg7 GEjw== X-Gm-Message-State: APjAAAUOH+KCWwcXvFaXXZlcdSKgwujw7fHycco9bqkxg9hA9IVEmwuB FVgftVzuPQDLMUNJyQ75riI/GQ== X-Google-Smtp-Source: APXvYqwIQoneCKa9W32nALR6Tj3GimCywQ1qdcByeYfBG/0A4RWS2a3XeyPEe0eLTiJg6DWQRGfehA== X-Received: by 2002:a1c:e715:: with SMTP id e21mr2217652wmh.122.1552658220950; Fri, 15 Mar 2019 06:57:00 -0700 (PDT) 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 a14sm2131900wrx.96.2019.03.15.06.57.00 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 15 Mar 2019 06:57:00 -0700 (PDT) From: Neil Armstrong To: khilman@baylibre.com Subject: [PATCH v2 2/2] arm64: dts: meson-gxm: Add Mali-T820 node Date: Fri, 15 Mar 2019 14:56:55 +0100 Message-Id: <20190315135655.28359-3-narmstrong@baylibre.com> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190315135655.28359-1-narmstrong@baylibre.com> References: <20190315135655.28359-1-narmstrong@baylibre.com> MIME-Version: 1.0 X-Mailman-Original-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:in-reply-to:references :mime-version:content-transfer-encoding; bh=Ox5dhzmGa/6JQDhw+Y9moNKLx34n2K2pj1pY4zKasYU=; b=qdgV9tORh+lf/4sku7mYCbPT/s6p04k67zrHnrzQJA9aULYXbshCXDV4v1DhJzqhov 1CJ6CFvTv6K/hd7gDmUPwYQZ7Ys2Uli/T1dVdn5ijxoCybkpOIjY64uxxrBLbDNUD+GT hgnJjEYETb2QuxHjza7tGum719AM8P/rBtMHUvdwCNh/Pp/LXqX6wrRDxOJRe48ZMHkU TTq6elMdoDBW9MJTYr5E0TLt8krzW0sTwPjM9CPIdfpqOKnSNs3ejOfLH3cGpP13KL8h d0UZKgEX5h8p6GNFfsJ3ynA4RAQ94fJy3OrwATDUx1/35JeBwc/fzA1VxGNfwtoBK5Vx uPFg== X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Neil Armstrong , Christian Hewitt , linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-amlogic@lists.infradead.org, linux-arm-kernel@lists.infradead.org Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP From: Christian Hewitt The Amlogic Meson GXM SoC embeds an ARM Mali T820 GPU. This patch adds the node with all the needed properties to power on the GPU. This has been tested with the work-in-progress PanFrost project aiming support for ARM Mali Midgard and later GPUs. Signed-off-by: Christian Hewitt Signed-off-by: Neil Armstrong --- arch/arm64/boot/dts/amlogic/meson-gxm.dtsi | 27 ++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/arch/arm64/boot/dts/amlogic/meson-gxm.dtsi b/arch/arm64/boot/dts/amlogic/meson-gxm.dtsi index 247888d68a3a..35e59d390903 100644 --- a/arch/arm64/boot/dts/amlogic/meson-gxm.dtsi +++ b/arch/arm64/boot/dts/amlogic/meson-gxm.dtsi @@ -91,6 +91,33 @@ reset-names = "phy"; status = "okay"; }; + + mali: gpu@c0000 { + compatible = "amlogic,meson-gxm-mali", "arm,mali-t820"; + reg = <0x0 0xc0000 0x0 0x40000>; + interrupt-parent = <&gic>; + interrupts = , + , + ; + interrupt-names = "gpu", "mmu", "job"; + clocks = <&clkc CLKID_MALI>; + resets = <&reset RESET_MALI_CAPB3>, <&reset RESET_MALI>; + + /* + * Mali clocking is provided by two identical clock paths + * MALI_0 and MALI_1 muxed to a single clock by a glitch + * free mux to safely change frequency while running. + */ + assigned-clocks = <&clkc CLKID_MALI_0_SEL>, + <&clkc CLKID_MALI_0>, + <&clkc CLKID_MALI>; /* Glitch free mux */ + assigned-clock-parents = <&clkc CLKID_FCLK_DIV3>, + <0>, /* Do Nothing */ + <&clkc CLKID_MALI_0>; + assigned-clock-rates = <0>, /* Do Nothing */ + <666666666>, + <0>; /* Do Nothing */ + }; }; &clkc_AO {