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: 10854821 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 3650A1390 for ; Fri, 15 Mar 2019 13:57:18 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 1AFD72A9F6 for ; Fri, 15 Mar 2019 13:57:18 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 0F6512A9FA; Fri, 15 Mar 2019 13:57:18 +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 BAAD12A9F6 for ; Fri, 15 Mar 2019 13:57:17 +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:References:In-Reply-To: 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: List-Owner; bh=X4k/frghUgiPtF6R6664VP4nRgX2302zzKaMsNBEzSc=; b=CygwzPVYzw3K1+ xYcU/GFWX5BKXokAKpIeo7yNL3tXRJ4iDdBMfFps6Mdf0IXD7SoBCsRskyA4C+KCBT6sCjWMMXc0D /sC901PU0u1oh99AzQYkg8b4b5346i4gDFks76edwKpJZkmGT1C457FhrCNB2co3VoYZyfII4GHrC yXjJ2cXiz8gTtQbnKYFdXzgEnsaWlvXrtZFq8RQwN3OZuSbmk2EnufFOG/6qcXTrKtTbEBQdZ4HJ5 K1f5WcQKNvouUq+UxZbConfOfqGYu2LzLJB9UanBqehLHyr6A8DSiIKZMYr+YIf6tNyYvkcXIqMBQ 6MNxcltgSDbJkeawkMHA==; 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 1h4nKl-0007J8-DG; Fri, 15 Mar 2019 13:57:15 +0000 Received: from mail-wm1-x344.google.com ([2a00:1450:4864:20::344]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1h4nKX-0006rJ-VL for linux-arm-kernel@lists.infradead.org; Fri, 15 Mar 2019 13:57:02 +0000 Received: by mail-wm1-x344.google.com with SMTP id c13so9261573wmb.0 for ; Fri, 15 Mar 2019 06:57:01 -0700 (PDT) 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-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=szQF9A01OhgyrFIIKDQv2xe6aTBD2pvsjUmPg6Ava5TQvC0BkZAg5QO7GfT8qVJnVo NNghWGb4rgJ8TcxMZKbxxdQOnMCkwa5Veq35x0QvwBcryVUoYgo67Dn+LyWAIZrEolei quTs5icT0UL+MwzIfNrcf9zCsFm7TrHsvxOwH1U6KQkXHQHZ9NaR9HArS7RGs4G9d5VF QjQWDf4M0N07nU9P9j66N5hZ7i1gxox1CttmBJgtxwddhcZGXGe/YpdSW+HebazvZalh FLd/zFkOU+QS8ZFj+aeFtY/2LKbhH5gQNOY7E0AMoWSHEl4gzdbEeQGV1D3PiXVbd5Kh CCXQ== X-Gm-Message-State: APjAAAVeL5+jO2hIzMceB7ib+KJCaPvk6ObrhCIQxAoHklf45wp1p72d rwcOvGY0tO0qeLUEiypzUje80A== 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-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190315_065702_010494_1645ED8D X-CRM114-Status: GOOD ( 10.19 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: 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 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org 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: 10854829 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 DE5871390 for ; Fri, 15 Mar 2019 13:57:36 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id C00742A9F8 for ; Fri, 15 Mar 2019 13:57:36 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id B3A8C2A9FA; Fri, 15 Mar 2019 13:57:36 +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 643BD2A9F8 for ; Fri, 15 Mar 2019 13:57:36 +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:References:In-Reply-To: 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: List-Owner; bh=+5l6flto5GiU50eDaFwsPIL4Ij/glrL2m/1Zjm1pnhM=; b=ZD3lb5ra1uMtSp 7hfzHmqUPuPj+u2anDDX4FulYLtvyl1/ilBZYAnf8Rj8ndfKJ6bFRDsoRUyKimrJr6n7DfqJUekfL upo7E87DNpYSK25nAOfPePKaJk1p/mwvn/aVP0xW+svTTV/p4vg7Zkkum65Wvzdr6gWbHc3veOEAo Mbj9qDF4xc2pjVcbRySAwEsaVZ5mmQhQBy2NkVsmQfKEUZH3Qch6k02gZyKyNdYu6HUS0qjiF/HGe f70mSJT1g+cmrbWVt9yGBBe/6JB0lWmQ5dPpVeDf7/jbM/yXUayBwiSgeveUwywP5utLcD0/s5H/j R6X7E/2EvYl4+FVLcDZg==; 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 1h4nKz-0007eB-Ce; Fri, 15 Mar 2019 13:57:29 +0000 Received: from mail-wm1-x342.google.com ([2a00:1450:4864:20::342]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1h4nKY-0006rQ-Kk for linux-arm-kernel@lists.infradead.org; Fri, 15 Mar 2019 13:57:04 +0000 Received: by mail-wm1-x342.google.com with SMTP id n19so6614766wmi.1 for ; Fri, 15 Mar 2019 06:57:02 -0700 (PDT) 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-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=n8RVV9b6XjRfrsOgLWjzAfG7OrHcJVeM/tDDFfeivKwudpckeYPYAxP8sbmLw+NQHP X0Eiz/wzH/N6BVTbGVkGLVvQsq3rO/r5DEHKCS4E3QA2m61HIrqQHfZP4pSbHCxn1ARn nKN/7BmYqinntRgZcl4qa0D69q+H0LCAepmAkoTxE2QIgv/zOjhGj0KlOYwzScK+IH4h ob1P+uhsIw79tBD1B+sCuHGsxmbGzO2//pRhZOX5n5whUMo58zwSkb+9UMW2BoKN0PAn tVcg9bG3O3ErOMVpq9ovWCfz6TOvU+AU5NeyaP+jEE4QcMkOYfsaxXdXiL+Ttu0LSv+Z erlA== X-Gm-Message-State: APjAAAUakrEbmu/QCoSa2IVCWqAdEQIbnoqq435IihlWVKn0nethVvdy 9dUMMJXPVnZ5KqczYQybikMUPg== 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-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190315_065702_679521_CA1AB560 X-CRM114-Status: GOOD ( 12.94 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: 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 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org 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 {