From patchwork Mon Nov 28 11:17:37 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tomeu Vizoso X-Patchwork-Id: 26642 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:f944:0:0:0:0:0 with SMTP id q4csp5594476wrr; Mon, 28 Nov 2022 03:33:27 -0800 (PST) X-Google-Smtp-Source: AA0mqf6uJIvdrK8wPz0+OXfS/CfMzOWAYaMMR8W04UWqI63elMV3R2Sb+R2H3earVt32tIS5opgs X-Received: by 2002:a17:902:a9c6:b0:188:52df:769e with SMTP id b6-20020a170902a9c600b0018852df769emr30824359plr.30.1669635206806; Mon, 28 Nov 2022 03:33:26 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1669635206; cv=none; d=google.com; s=arc-20160816; b=0uVAz9K3wNYc1UlnuG3tY2U6sMFza/fahhR9Foh8YzM0hRX25r4diG1SdCkv77Lf+n rDNTq7WK9WGKdhkNJ+VydQOeoQqIvNNrsHlnRGvhFjNAozRQNouNFIdGQtYKCEKlKfau 0yqIfzX1SIMYA0kDlWBhWLiBKrUgMhcp+5vk1nahCR808YvdoZdKSdfDG6d0fvUno3C1 qW22JfYruGC0bvyz9h51Yx9pw/fxa2YOZtZyH+PgRLGj+AOXT6h36N+Ue9Sagipug4f/ HyLiAmcNowvGEnExmVK1I2gLjblhHE946ukCYWqPerkPOPBtmexGQLIvvwT5ODahfBGL hhDg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:to:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:from:sender :dkim-signature; bh=MZ/yfW2uv4L2OBEMjogEawvHGxQ+pctbkljRiIAmmkE=; b=U3vsCLTvws16l3wNoiBNjyD7quvZi0nV6ML640bbjo8njSBGbPUORg+M/Jm2QNFRK9 sL+GZySbXQz3rwnKxpolnMkKdcifbwCCYMyUdTx34Ap+tlnJbAZRO96I2BM/CWEQyw7A wIdIt2kTNajsbcBRtcKU/uj7H6wKpdaXsOHgpoo6KDA9w8AmUEIjW0ulLv30FIR+mbua 45+yEcv9VF2ZEig+0f4/AvuLz5wn5Lyz2L7EUome9vytSzO1hrSFU1svQuGp//SbwQCm xri6iz5iRX67d788znmin97/OZgZhV1avvkLyKJpnetZAHXXsFH6BxIYJws1Zxl0ZEWN gJag== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@gmail.com header.s=20210112 header.b=hGj6yWEx; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=collabora.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id t20-20020a635f14000000b00477650a2cdbsi12419671pgb.18.2022.11.28.03.33.13; Mon, 28 Nov 2022 03:33:26 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=fail header.i=@gmail.com header.s=20210112 header.b=hGj6yWEx; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=collabora.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230032AbiK1LSr (ORCPT + 99 others); Mon, 28 Nov 2022 06:18:47 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37674 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231243AbiK1LSG (ORCPT ); Mon, 28 Nov 2022 06:18:06 -0500 Received: from mail-wr1-x434.google.com (mail-wr1-x434.google.com [IPv6:2a00:1450:4864:20::434]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2C1E39590; Mon, 28 Nov 2022 03:18:04 -0800 (PST) Received: by mail-wr1-x434.google.com with SMTP id b12so16259713wrn.2; Mon, 28 Nov 2022 03:18:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:sender:from:to:cc:subject:date :message-id:reply-to; bh=MZ/yfW2uv4L2OBEMjogEawvHGxQ+pctbkljRiIAmmkE=; b=hGj6yWExeA6aOxOP28/1HTpYw/34JrQ7Esvqizyi96Ucx4ABRX8kMiUxEHL9qfsiE0 PqAAPfTyE97mJzH7BnkNxb3dOEga0uSP6vmgicBtIKcXdG99+CaH6p+PH9l+ZDP1e+WW bvWsY2p6m6fkKh3/oi+1jwK7HQfx8vQmNaC6gKZjnzqvXx+H47P+7SPY3H4dzQ+Hp74W Maf4pZjT7qBSotYev3Ay7J2G570YJp1d3WrXwJaswh4oY7DqJTL4fmuUpeP8Bub2rO05 5wZiV+82TgrY+Hlq8t5ZQkzqjc34D8BEbJspYKcRy3D3zE9ySXLJoPo7D3c2r6K+cdZp qoOA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:sender:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=MZ/yfW2uv4L2OBEMjogEawvHGxQ+pctbkljRiIAmmkE=; b=ZGUsc6qo+W75f8tpb27mSO8gfChXnxmx8ziLFC+jY3fxpWQxvCpfwX8VArdgzItK5C 4Qse05CJJkhrcOlDwCQr7apEoGSSuX2O+RYLIONGVzSibThcwr/kJirz07ZO3vz8J4qL /OVsN2CqHmZnA6Xrt5B663wMa0J+nvXToaU4XU9B8fRuHdHj5w6fcG/9gE71CLv8kAA0 SniLnLz2ETUQXdEbHXWI6+r4AkF7eZn7Ua/y5JGN1dVn76bTJqKhTjKls6gSu8Zk+pGW 6Yyd+9+E/cG0x6n9rWyppYi/XQmb0EDfcUIW/r483Vi5j1GAmOZMSH1ynC/jwWV0yNkn CRfA== X-Gm-Message-State: ANoB5plGMjvFZfH4PlA3SqlVO+udmomxf4JF40Wx0YeHgdxEi3o3nbgr 49X0JGhz6jWFWhLUs6qrbAFeBIFM94w= X-Received: by 2002:adf:a1c8:0:b0:236:72f1:f124 with SMTP id v8-20020adfa1c8000000b0023672f1f124mr30428869wrv.161.1669634283786; Mon, 28 Nov 2022 03:18:03 -0800 (PST) Received: from cizrna.home (cst-prg-44-69.cust.vodafone.cz. [46.135.44.69]) by smtp.gmail.com with ESMTPSA id g3-20020adffc83000000b0024207ed4ce0sm7711817wrr.58.2022.11.28.03.18.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 28 Nov 2022 03:18:03 -0800 (PST) Sender: Tomeu Vizoso From: Tomeu Vizoso Cc: italonicola@collabora.com, Tomeu Vizoso , Rob Herring , Krzysztof Kozlowski , Neil Armstrong , Kevin Hilman , Jerome Brunet , Martin Blumenstingl , devicetree@vger.kernel.org (open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS), linux-arm-kernel@lists.infradead.org (moderated list:ARM/Amlogic Meson SoC support), linux-amlogic@lists.infradead.org (open list:ARM/Amlogic Meson SoC support), linux-kernel@vger.kernel.org (open list) Subject: [PATCH v2 4/5] arm64: dts: Add DT node for the VIPNano-QI on the A311D Date: Mon, 28 Nov 2022 12:17:37 +0100 Message-Id: <20221128111740.39003-5-tomeu.vizoso@collabora.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221128111740.39003-1-tomeu.vizoso@collabora.com> References: <20221128111740.39003-1-tomeu.vizoso@collabora.com> MIME-Version: 1.0 X-Spam-Status: No, score=-1.7 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_EF,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE, SPF_PASS autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net To: unlisted-recipients:; (no To-header on input) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1750739406679737264?= X-GMAIL-MSGID: =?utf-8?q?1750739406679737264?= This "NPU" is very similar to the Vivante GPUs and Etnaviv works well with it with just a few small changes. v2: Add reference to RESET_NNA (Neil) Signed-off-by: Tomeu Vizoso Reviewed-by: Neil Armstrong --- arch/arm64/boot/dts/amlogic/meson-g12-common.dtsi | 11 +++++++++++ .../boot/dts/amlogic/meson-g12b-a311d-khadas-vim3.dts | 4 ++++ 2 files changed, 15 insertions(+) diff --git a/arch/arm64/boot/dts/amlogic/meson-g12-common.dtsi b/arch/arm64/boot/dts/amlogic/meson-g12-common.dtsi index 45947c1031c4..aaa629816e41 100644 --- a/arch/arm64/boot/dts/amlogic/meson-g12-common.dtsi +++ b/arch/arm64/boot/dts/amlogic/meson-g12-common.dtsi @@ -11,6 +11,7 @@ #include #include #include +#include / { interrupt-parent = <&gic>; @@ -2484,4 +2485,14 @@ xtal: xtal-clk { #clock-cells = <0>; }; + npu: npu@ff100000 { + compatible = "vivante,gc"; + reg = <0x0 0xff100000 0x0 0x20000>; + interrupts = <0 147 4>; + clocks = <&clkc CLKID_NNA_CORE_CLK>, + <&clkc CLKID_NNA_AXI_CLK>; + clock-names = "core", "bus"; + resets = <&reset RESET_NNA>; + power-domains = <&pwrc PWRC_G12A_NNA_ID>; + }; }; diff --git a/arch/arm64/boot/dts/amlogic/meson-g12b-a311d-khadas-vim3.dts b/arch/arm64/boot/dts/amlogic/meson-g12b-a311d-khadas-vim3.dts index 124a80901084..73f3d87dcefd 100644 --- a/arch/arm64/boot/dts/amlogic/meson-g12b-a311d-khadas-vim3.dts +++ b/arch/arm64/boot/dts/amlogic/meson-g12b-a311d-khadas-vim3.dts @@ -15,6 +15,10 @@ / { compatible = "khadas,vim3", "amlogic,a311d", "amlogic,g12b"; }; +&npu { + status = "okay"; +}; + /* * The VIM3 on-board MCU can mux the PCIe/USB3.0 shared differential * lines using a FUSB340TMX USB 3.1 SuperSpeed Data Switch between