From nobody Thu Sep 18 23:38:04 2025 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4072DC43217 for ; Thu, 1 Dec 2022 09:22:10 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230070AbiLAJWI (ORCPT ); Thu, 1 Dec 2022 04:22:08 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54218 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229652AbiLAJWC (ORCPT ); Thu, 1 Dec 2022 04:22:02 -0500 Received: from mail-ej1-x62e.google.com (mail-ej1-x62e.google.com [IPv6:2a00:1450:4864:20::62e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DFFD886594; Thu, 1 Dec 2022 01:22:00 -0800 (PST) Received: by mail-ej1-x62e.google.com with SMTP id bj12so2656066ejb.13; Thu, 01 Dec 2022 01:22:00 -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=9cg4h08ScbCmARXEsFqgc8N6O4NbradYeqRREoszyl4=; b=CXkqw4qUp3iF1c/VAFgMXTatfXdqW2qdLv/ri5wf4ff6y/bwMhcPTiZXL1x5LkU5Sz 8Q3mRbIrRA7hlRTEfTFvkSh4JplJO/zNfnMvtjbXrFyqH4PZ7WpFjEnp/GBxXNwUR7GH EkCCEv4ab3AsoRp7+L1ILg70SRjD0TtXIjl5wkVTPpNUj+/yqoDESBjYRocrbG7qVSJg vVJbXbCSMCe9Dao9ZtUScNN9WV/YVzg1l6F9nWke00MhibBosR79feNatjZIYXSi/v24 VFRKQvRE0AS0abToSBRu3BfhJ0c225w/p4IfxWJ5Np67Q38A5aicQ82QiqNr6PElvY6M QySA== 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=9cg4h08ScbCmARXEsFqgc8N6O4NbradYeqRREoszyl4=; b=Da5q08jiLNLYqb879IY42OVVTFOWTfftxLxUBt0ww8WJ9ZAg2vDVWE+9E+rH98cEd+ BCSGHY/t4feOwoVdH3OyAGfD0AKKwSVG6fXBu9uLNmMppCtQl7IvdIjh02Ca5wiMUUEX ib9admM8v6wASoQ7Ef6mKU8H2q8n4UbI2D/eGd5dLuQKORiyqsbkpzb9xYeoL58tFk/D zS5LxhFz71tjanNE18RhXbvDWLZrGYYJqdVfXcpQgoVFmrkflePT/JdMXTh5FI8y5Wt+ c6q13U2JxdLME6MkQmRrDjZC9u+Sx3RxiGLtwaHULLPCDa76ihE6KDCG/xEduA9pj/Xw iWlw== X-Gm-Message-State: ANoB5pnctS+WUx+NBlteVUgRP+KX4KrB28RYSw4VXTaaBooJSJmEFoeJ yjoDSlF1CPXxAtz7VeLsVFU= X-Google-Smtp-Source: AA0mqf4ntoAMYIY51L9dJw/8VGj7v7SAFWbpcSMtapJ99oDCgJj+l+3LtrhYBgp8Pss4X42nEaXNwA== X-Received: by 2002:a17:906:a418:b0:7a5:e944:9e48 with SMTP id l24-20020a170906a41800b007a5e9449e48mr57172762ejz.109.1669886519485; Thu, 01 Dec 2022 01:21:59 -0800 (PST) Received: from cizrna.home (cst-prg-44-69.cust.vodafone.cz. [46.135.44.69]) by smtp.gmail.com with ESMTPSA id 18-20020a170906211200b007b29eb8a4dbsm1587879ejt.13.2022.12.01.01.21.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 01 Dec 2022 01:21:59 -0800 (PST) Sender: Tomeu Vizoso From: Tomeu Vizoso Cc: italonicola@collabora.com, Tomeu Vizoso , Neil Armstrong , Philipp Zabel , Rob Herring , Krzysztof Kozlowski , 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 v4 1/7] dt-bindings: reset: meson-g12a: Add missing NNA reset Date: Thu, 1 Dec 2022 10:21:22 +0100 Message-Id: <20221201092131.62867-2-tomeu.vizoso@collabora.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221201092131.62867-1-tomeu.vizoso@collabora.com> References: <20221201092131.62867-1-tomeu.vizoso@collabora.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable To: unlisted-recipients:; (no To-header on input) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" Doesn't appear in the TRM I have, but it is used by the downstream galcore driver. Signed-off-by: Tomeu Vizoso Acked-by: Neil Armstrong --- include/dt-bindings/reset/amlogic,meson-g12a-reset.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/include/dt-bindings/reset/amlogic,meson-g12a-reset.h b/include= /dt-bindings/reset/amlogic,meson-g12a-reset.h index 6d487c5eba2c..45f6b8a951d0 100644 --- a/include/dt-bindings/reset/amlogic,meson-g12a-reset.h +++ b/include/dt-bindings/reset/amlogic,meson-g12a-reset.h @@ -69,7 +69,9 @@ #define RESET_PARSER_FETCH 72 #define RESET_CTL 73 #define RESET_PARSER_TOP 74 -/* 75-77 */ +/* 75 */ +#define RESET_NNA 76 +/* 77 */ #define RESET_DVALIN 78 #define RESET_HDMITX 79 /* 80-95 */ --=20 2.38.1 From nobody Thu Sep 18 23:38:04 2025 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6BD56C43217 for ; Thu, 1 Dec 2022 09:22:13 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230075AbiLAJWL (ORCPT ); Thu, 1 Dec 2022 04:22:11 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54224 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229771AbiLAJWE (ORCPT ); Thu, 1 Dec 2022 04:22:04 -0500 Received: from mail-ed1-x52b.google.com (mail-ed1-x52b.google.com [IPv6:2a00:1450:4864:20::52b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 701D585679; Thu, 1 Dec 2022 01:22:03 -0800 (PST) Received: by mail-ed1-x52b.google.com with SMTP id f7so1506026edc.6; Thu, 01 Dec 2022 01:22:03 -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=IIHeFovEuwjGuythdoubrFT/SXANkAJoc/lUtd9ZW10=; b=T8NMw0auTX3nVwIJOBEXOMKh+uqx8TL/MfgsQaHpXiIPpHbTluYVT5MbwoV+eH/Mwl aqCvSWODpNANYQEcN63jk0hAhV3rHpzhzuEZhLJYxzV3wogr9KE58ZfFLdqTumxU64Ah x4H9WETB8elERPDbGGTVLAbok1wt5d0RWcqQXOs1udLnRqd4lM5q4/Su2WpKE5VP35Cf XZCLXa0N3xi2YEDA/Ep+KNM5t9fSPxhIkOTQH01L2wOo6SVwXctSxX+BtCFPPxA5Cge9 umbox7LujP/qN+0OAsIz5/AU9jGE1SjQhJeHw/WLhEbzpYfWAShi3B5wD02MZTDaQXI5 UVLA== 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=IIHeFovEuwjGuythdoubrFT/SXANkAJoc/lUtd9ZW10=; b=5blYqe3G/RcosCvZ32CZEIcCqmzvhVq4rBrH9bxEEmsuT8tF4U9PGc0shRkAiwEpv5 t6RLNiNw//hfFWkD2lwdrvOjZL7i6rj3O66JWJ9PSZ5ski+pZ/yBOOybkV8Z2kYYH8jq 4TbnvleJfEkY1bjR9MoMARknKKtYzQl47UDeXQTRO8f+pnyWmBw5jEh6ZQHz5aP/f48t RjB9zBKQXaa1CcmTqQ/YwuPhZnyVtMmBKAl9gabvFIWgYYRbqz/AyKY2Kc9uYSh6Madq xGBNKo333fsawqgaq8IgriQaD4Q4a3/UpWoA4QkJ8PkLSdfX+0rxc2JMDOi44rEydBw0 w0Ig== X-Gm-Message-State: ANoB5pk0I/PiQG3OJRNmMw52hj4WZw8X+x3Xm/x1BAuMSLcFodD8myMq aKFGeArboMPRQO+hJjqbmxM= X-Google-Smtp-Source: AA0mqf5pb8aFIA8ELC14wWkc0BpA3jtfmG0vYDIKXKX3zZ1MK+of5ZM9eNc1qHqbitu8LkqX55N8DQ== X-Received: by 2002:aa7:cad7:0:b0:459:443a:faf4 with SMTP id l23-20020aa7cad7000000b00459443afaf4mr59471545edt.297.1669886521955; Thu, 01 Dec 2022 01:22:01 -0800 (PST) Received: from cizrna.home (cst-prg-44-69.cust.vodafone.cz. [46.135.44.69]) by smtp.gmail.com with ESMTPSA id 18-20020a170906211200b007b29eb8a4dbsm1587879ejt.13.2022.12.01.01.22.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 01 Dec 2022 01:22:01 -0800 (PST) Sender: Tomeu Vizoso From: Tomeu Vizoso Cc: italonicola@collabora.com, Tomeu Vizoso , Neil Armstrong , Rob Herring , Krzysztof Kozlowski , 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 v4 2/7] dt-bindings: power: Add G12A NNA power domain Date: Thu, 1 Dec 2022 10:21:23 +0100 Message-Id: <20221201092131.62867-3-tomeu.vizoso@collabora.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221201092131.62867-1-tomeu.vizoso@collabora.com> References: <20221201092131.62867-1-tomeu.vizoso@collabora.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable To: unlisted-recipients:; (no To-header on input) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" Add define for the NNA power domain for the NPU in the G12A. Signed-off-by: Tomeu Vizoso Acked-by: Neil Armstrong --- include/dt-bindings/power/meson-g12a-power.h | 1 + 1 file changed, 1 insertion(+) diff --git a/include/dt-bindings/power/meson-g12a-power.h b/include/dt-bind= ings/power/meson-g12a-power.h index bb5e67a842de..93b03bdd60b7 100644 --- a/include/dt-bindings/power/meson-g12a-power.h +++ b/include/dt-bindings/power/meson-g12a-power.h @@ -9,5 +9,6 @@ =20 #define PWRC_G12A_VPU_ID 0 #define PWRC_G12A_ETH_ID 1 +#define PWRC_G12A_NNA_ID 2 =20 #endif --=20 2.38.1 From nobody Thu Sep 18 23:38:04 2025 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id A7DE5C47090 for ; Thu, 1 Dec 2022 09:22:15 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230092AbiLAJWO (ORCPT ); Thu, 1 Dec 2022 04:22:14 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54230 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229937AbiLAJWF (ORCPT ); Thu, 1 Dec 2022 04:22:05 -0500 Received: from mail-ej1-x635.google.com (mail-ej1-x635.google.com [IPv6:2a00:1450:4864:20::635]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9DC2F86594 for ; Thu, 1 Dec 2022 01:22:04 -0800 (PST) Received: by mail-ej1-x635.google.com with SMTP id o13so2760110ejm.1 for ; Thu, 01 Dec 2022 01:22: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=Cw/am3froU3IMTWG9BB3ZSyfplgImMW6lCXqrhZP2N0=; b=VtKXP9AfoQpyEZYYV8RQoSBNAXIYAvwbKi6Yg6Coz0B22h0nwf6cOnNjAiCNC6+8J1 7NolDrEwXwXRx4yAaXXvqvu4wIgZsTZ6gLLbOMAqjbY94rN0zdjIWXsYwnONwGW/NsC/ w2BiyAJVq4d0sjwWQtorKHctehY7vfauDgXs2hBNxAUV8PVaRnzRlqVrq6EGnTfq/vot z8opNiGX6/1bWF+R5skTgx9u1kpkMP54cALtMfMmZFlCymXrysGAOIRICToMQONZs/4l x3ufy1N7+UUN9Y4RraBMyMX+QvO6MiINR/ScMSbAh+mq210eN2ipnUpL/d0hsGL7jsGR QzBw== 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=Cw/am3froU3IMTWG9BB3ZSyfplgImMW6lCXqrhZP2N0=; b=r3Fdijw5U8NoegtxRC28gjxCs+u7KIE0xtDxZltKfCDkEhEBwR5oTayP3fwKPyN2XA g+Rbxc4HlbnjoNgC6yunAqVOFJH3+FBZzVfnDZQkxL/FB/H4+LbNItTCyp9gFv6hmdtL o3gbg3zLpxRlDhiMk9pKBTMUiKrZcLwzvlfPBphzcQe3wWf91/h7kFk0SlYdWnO6Vxo0 mfrblZw7JRS0lXKlxP9b4MhjdhPbBRxm8sFcrw92qKlgDR6PbDvrqiTCbuJ/FEBXyoBp TmBSuVI5/Cr9kK7Zf/JiR3hlamtaBJyIWpaLdxirgvEmg5wCx0q0Kg3GExOWnauTAdrp 8+xg== X-Gm-Message-State: ANoB5plADgIP43yCn7sjIx6DvyQ4kXq2rGdQfUFrU4JoY3nmjH2qpX6g QchT1zBXrphS2KivG1vcLlg= X-Google-Smtp-Source: AA0mqf6j94e36tZw8yrtZZ4lcltmqWjX7I3vRd3gaN2OAM5MqJ9bj+WCkFF+5F9Iy3UWrMLt1UWLkg== X-Received: by 2002:a17:906:a387:b0:7bc:2ad:7c1e with SMTP id k7-20020a170906a38700b007bc02ad7c1emr28734923ejz.588.1669886523183; Thu, 01 Dec 2022 01:22: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 18-20020a170906211200b007b29eb8a4dbsm1587879ejt.13.2022.12.01.01.22.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 01 Dec 2022 01:22:02 -0800 (PST) Sender: Tomeu Vizoso From: Tomeu Vizoso Cc: italonicola@collabora.com, Tomeu Vizoso , Neil Armstrong , Kevin Hilman , Jerome Brunet , Martin Blumenstingl , 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 v4 3/7] soc: amlogic: meson-pwrc: Add NNA power domain for A311D Date: Thu, 1 Dec 2022 10:21:24 +0100 Message-Id: <20221201092131.62867-4-tomeu.vizoso@collabora.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221201092131.62867-1-tomeu.vizoso@collabora.com> References: <20221201092131.62867-1-tomeu.vizoso@collabora.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable To: unlisted-recipients:; (no To-header on input) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" Based on power initialization sequence in downstream driver. Signed-off-by: Tomeu Vizoso Reviewed-by: Neil Armstrong --- drivers/soc/amlogic/meson-ee-pwrc.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/drivers/soc/amlogic/meson-ee-pwrc.c b/drivers/soc/amlogic/meso= n-ee-pwrc.c index dd5f2a13ceb5..dfbf0b1c7d29 100644 --- a/drivers/soc/amlogic/meson-ee-pwrc.c +++ b/drivers/soc/amlogic/meson-ee-pwrc.c @@ -46,6 +46,9 @@ #define HHI_NANOQ_MEM_PD_REG1 (0x47 << 2) #define HHI_VPU_MEM_PD_REG2 (0x4d << 2) =20 +#define G12A_HHI_NANOQ_MEM_PD_REG0 (0x43 << 2) +#define G12A_HHI_NANOQ_MEM_PD_REG1 (0x44 << 2) + struct meson_ee_pwrc; struct meson_ee_pwrc_domain; =20 @@ -106,6 +109,13 @@ static struct meson_ee_pwrc_top_domain sm1_pwrc_usb = =3D SM1_EE_PD(17); static struct meson_ee_pwrc_top_domain sm1_pwrc_pci =3D SM1_EE_PD(18); static struct meson_ee_pwrc_top_domain sm1_pwrc_ge2d =3D SM1_EE_PD(19); =20 +static struct meson_ee_pwrc_top_domain g12a_pwrc_nna =3D { \ + .sleep_reg =3D GX_AO_RTI_GEN_PWR_SLEEP0, \ + .sleep_mask =3D BIT(16) | BIT(17), \ + .iso_reg =3D GX_AO_RTI_GEN_PWR_ISO0, \ + .iso_mask =3D BIT(16) | BIT(17), \ + }; + /* Memory PD Domains */ =20 #define VPU_MEMPD(__reg) \ @@ -217,6 +227,11 @@ static struct meson_ee_pwrc_mem_domain sm1_pwrc_mem_au= dio[] =3D { { HHI_AUDIO_MEM_PD_REG0, GENMASK(27, 26) }, }; =20 +static struct meson_ee_pwrc_mem_domain g12a_pwrc_mem_nna[] =3D { + { G12A_HHI_NANOQ_MEM_PD_REG0, GENMASK(31, 0) }, + { G12A_HHI_NANOQ_MEM_PD_REG1, GENMASK(23, 0) }, +}; + #define VPU_PD(__name, __top_pd, __mem, __is_pwr_off, __resets, __clks) \ { \ .name =3D __name, \ @@ -253,6 +268,8 @@ static struct meson_ee_pwrc_domain_desc g12a_pwrc_domai= ns[] =3D { [PWRC_G12A_VPU_ID] =3D VPU_PD("VPU", &gx_pwrc_vpu, g12a_pwrc_mem_vpu, pwrc_ee_is_powered_off, 11, 2), [PWRC_G12A_ETH_ID] =3D MEM_PD("ETH", meson_pwrc_mem_eth), + [PWRC_G12A_NNA_ID] =3D TOP_PD("NNA", &g12a_pwrc_nna, g12a_pwrc_mem_nna, + pwrc_ee_is_powered_off), }; =20 static struct meson_ee_pwrc_domain_desc gxbb_pwrc_domains[] =3D { --=20 2.38.1 From nobody Thu Sep 18 23:38:04 2025 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id E6C00C43217 for ; Thu, 1 Dec 2022 09:22:24 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230114AbiLAJWV (ORCPT ); Thu, 1 Dec 2022 04:22:21 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54358 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230079AbiLAJWJ (ORCPT ); Thu, 1 Dec 2022 04:22:09 -0500 Received: from mail-ej1-x631.google.com (mail-ej1-x631.google.com [IPv6:2a00:1450:4864:20::631]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9F72C88B75; Thu, 1 Dec 2022 01:22:06 -0800 (PST) Received: by mail-ej1-x631.google.com with SMTP id n21so2689861ejb.9; Thu, 01 Dec 2022 01:22:06 -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=emFoOM20hOM5X61XhU2Zz+3u4EcYFFGnLjIcqz3xjIc=; b=eEKedVMqKjYToTnqqxIEak73Wzz7rW0xVExwfxSdUKfxOp8vkH2NxTqrOtIoQLz4F8 9exnW6NsirZrwSTRSfprHwDR5nwlpq0pDtbX1yq8dJmnSnKk/KwnLpBVOSkJTcxo147N WSyq6IUND9gaNMgFQUZqSGL7RikXSjj4WYPm9AtgEMeUD2wgnXFaZCLy2bwodcAmida4 ZsaQTs/81oikt/C+1jx4caWjMSbKOOSdBMb3ToqVHQmwU5UbUaLeMMvlB2IlyaAGUTuF aaDD5i4nFWyynDYWo15p/tdbfOA0xQJush3cXN4PQMqmOX/dO+Am4L7aSZGKcga+SsZC EbvQ== 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=emFoOM20hOM5X61XhU2Zz+3u4EcYFFGnLjIcqz3xjIc=; b=gGwhFrMapEKmtwjXbU6kUSJLdNz+hT7wvr8X4o+1ipXxniqWbfm/FAaXKPJVoPMAel EJitaPG+8XBKTR9M/KggjFrU/Twy6AoaXv6pxpwVbOLra3fMsO8oHOPq8jIAZd40DLjy UKyq6gx8X7EbKu26F1oTOwo382OGHvUR7huFpBKk9gwpfHHB8dsv0/JkMii1HPDDoCP1 g5+yvErXRbtK+RsSyzwXzi/4j+NfKxohxr80qWoBWNFk9uU+GmVTmjR0NQE2p5iXbEsX BGCO5tAnY4PZ9HTnOFOectMSog/PdLaA7gBQMcfGRErnaVIS6Hn4qJhKzUmEquAP4NEv UM2g== X-Gm-Message-State: ANoB5pl+0SHNNfBVH+sQsQZeSNc7b6Fu+5BONdMj/crMKatC18WRRoxP wLKW0D58g/XXuiZJKfRfs40= X-Google-Smtp-Source: AA0mqf4UyZ0O/AsgAmnpnzeo9TgNMV2FW3qhCZ7iet38KCkJzo/YLs9LD+vUUo9/Xdof/6/2W89Bdg== X-Received: by 2002:a17:906:4f0b:b0:78d:aaf9:7b8c with SMTP id t11-20020a1709064f0b00b0078daaf97b8cmr56468241eju.229.1669886524515; Thu, 01 Dec 2022 01:22:04 -0800 (PST) Received: from cizrna.home (cst-prg-44-69.cust.vodafone.cz. [46.135.44.69]) by smtp.gmail.com with ESMTPSA id 18-20020a170906211200b007b29eb8a4dbsm1587879ejt.13.2022.12.01.01.22.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 01 Dec 2022 01:22:04 -0800 (PST) Sender: Tomeu Vizoso From: Tomeu Vizoso Cc: italonicola@collabora.com, Tomeu Vizoso , Neil Armstrong , Rob Herring , Krzysztof Kozlowski , 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 v4 4/7] arm64: dts: Add DT node for the VIPNano-QI on the A311D Date: Thu, 1 Dec 2022 10:21:25 +0100 Message-Id: <20221201092131.62867-5-tomeu.vizoso@collabora.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221201092131.62867-1-tomeu.vizoso@collabora.com> References: <20221201092131.62867-1-tomeu.vizoso@collabora.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable To: unlisted-recipients:; (no To-header on input) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" 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) v3: Fix indentation (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..61c8461df614 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 =20 / { interrupt-parent =3D <&gic>; @@ -2484,4 +2485,14 @@ xtal: xtal-clk { #clock-cells =3D <0>; }; =20 + npu: npu@ff100000 { + compatible =3D "vivante,gc"; + reg =3D <0x0 0xff100000 0x0 0x20000>; + interrupts =3D <0 147 4>; + clocks =3D <&clkc CLKID_NNA_CORE_CLK>, + <&clkc CLKID_NNA_AXI_CLK>; + clock-names =3D "core", "bus"; + resets =3D <&reset RESET_NNA>; + power-domains =3D <&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 =3D "khadas,vim3", "amlogic,a311d", "amlogic,g12b"; }; =20 +&npu { + status =3D "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 --=20 2.38.1 From nobody Thu Sep 18 23:38:04 2025 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id C273AC43217 for ; Thu, 1 Dec 2022 09:22:31 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230103AbiLAJW3 (ORCPT ); Thu, 1 Dec 2022 04:22:29 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54360 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230080AbiLAJWJ (ORCPT ); Thu, 1 Dec 2022 04:22:09 -0500 Received: from mail-ej1-x634.google.com (mail-ej1-x634.google.com [IPv6:2a00:1450:4864:20::634]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5780889AED for ; Thu, 1 Dec 2022 01:22:07 -0800 (PST) Received: by mail-ej1-x634.google.com with SMTP id vp12so2696093ejc.8 for ; Thu, 01 Dec 2022 01:22:07 -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=j/wAlj9+lbLEBeIqsdF+yfeUS1s2V84+JTVk1VCdcTE=; b=AEJ5Dr7zB416GNoTNHNKS9rh5+Y2xhjAKHwoZGCbN23KANzvgKbjQsTMwcHfU9//gc 7eEuqNfoarSzqd6Hub73JzuxHzfZ3zuKU8KbpyRTmxVxZ8jxQLHg56ngi90cCF+1I+IA ETujKamyy5Lki/kXzCCBzo3ZCdibteSRokDjyYZX6sa+sYTcCUzC47vjDpeOoHjJTFgi LldbFFMwGZoiqaX8LPCS0KrhY+dGHtSyCwpi8DfDbiKu4JcKUTRiGGW0qYhoXcVNL1xz C1ymFTKcSVgFRNt9TI20M1niY9gxYghKhHzmRWDYslmPMfNQ9FTKs+DyFqKxnbtnlWCx 997A== 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=j/wAlj9+lbLEBeIqsdF+yfeUS1s2V84+JTVk1VCdcTE=; b=i0yGl02n6kxRnNhZistUJDyf9h2Cj6zcfTmaJwKUDJTyoiZWzth7ARw70TmvFcgRIi IhrMskPxeGll0wHPE4VivhElr3MhYp/nInN90anjwcVwoRdrpN0IQNAQS96PCD4tuqUY xALGO3DmgUOrHvUls4CzYxU6mvUQhNJkkfn18VcNqyL0YgKvQSA40VbZTa3qGBduUnfQ aVgsH7egVIIEkWuYmUARt4L5o+fxFqH34D/L2ZE8tjfQgXCJ2IibIfwCU0onAb5r27ow P3/p5ybUTVvGY3+4qgNFewxKtKX8qY0gTPnUMctDWwLSaaaI68xi9wW3CAcUs5EAb77k 10bQ== X-Gm-Message-State: ANoB5pkAYrmg0KG5HPzpGSTRdZw/3Qhul7opxDBSZnb1peqF55LyfDww M+wV+NNVdhYhFKa32QbO0yE= X-Google-Smtp-Source: AA0mqf4U7Jfjt9v07Np5vCGzYbUwDTHC1Yq1KbW+C75UIdsapP471QhHYnSvQepDZC4sLwYcl3Z1lw== X-Received: by 2002:a17:906:1ecf:b0:7ad:902c:d1d6 with SMTP id m15-20020a1709061ecf00b007ad902cd1d6mr43010098ejj.143.1669886525782; Thu, 01 Dec 2022 01:22:05 -0800 (PST) Received: from cizrna.home (cst-prg-44-69.cust.vodafone.cz. [46.135.44.69]) by smtp.gmail.com with ESMTPSA id 18-20020a170906211200b007b29eb8a4dbsm1587879ejt.13.2022.12.01.01.22.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 01 Dec 2022 01:22:05 -0800 (PST) Sender: Tomeu Vizoso From: Tomeu Vizoso Cc: italonicola@collabora.com, Tomeu Vizoso , Lucas Stach , Russell King , Christian Gmeiner , David Airlie , Daniel Vetter , etnaviv@lists.freedesktop.org (moderated list:DRM DRIVERS FOR VIVANTE GPU IP), dri-devel@lists.freedesktop.org (open list:DRM DRIVERS FOR VIVANTE GPU IP), linux-kernel@vger.kernel.org (open list) Subject: [PATCH v4 5/7] drm/etnaviv: add HWDB entry for VIPNano-QI.7120.0055 Date: Thu, 1 Dec 2022 10:21:26 +0100 Message-Id: <20221201092131.62867-6-tomeu.vizoso@collabora.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221201092131.62867-1-tomeu.vizoso@collabora.com> References: <20221201092131.62867-1-tomeu.vizoso@collabora.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable To: unlisted-recipients:; (no To-header on input) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" This is a compute-only module marketed towards AI and vision acceleration. This particular version can be found on the Amlogic A311D SoC. The feature bits are taken from the Khadas downstream kernel driver 6.4.4.3.310723AAA. Signed-off-by: Tomeu Vizoso --- drivers/gpu/drm/etnaviv/etnaviv_hwdb.c | 31 ++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/drivers/gpu/drm/etnaviv/etnaviv_hwdb.c b/drivers/gpu/drm/etnav= iv/etnaviv_hwdb.c index f2fc645c7956..3f6fd9a3c088 100644 --- a/drivers/gpu/drm/etnaviv/etnaviv_hwdb.c +++ b/drivers/gpu/drm/etnaviv/etnaviv_hwdb.c @@ -130,6 +130,37 @@ static const struct etnaviv_chip_identity etnaviv_chip= _identities[] =3D { .minor_features10 =3D 0x90044250, .minor_features11 =3D 0x00000024, }, + { + .model =3D 0x8000, + .revision =3D 0x7120, + .product_id =3D 0x45080009, + .customer_id =3D 0x88, + .eco_id =3D 0, + .stream_count =3D 8, + .register_max =3D 64, + .thread_count =3D 256, + .shader_core_count =3D 1, + .vertex_cache_size =3D 16, + .vertex_output_buffer_size =3D 1024, + .pixel_pipes =3D 1, + .instruction_count =3D 512, + .num_constants =3D 320, + .buffer_size =3D 0, + .varyings_count =3D 16, + .features =3D 0xe0287cac, + .minor_features0 =3D 0xc1799eff, + .minor_features1 =3D 0xfefbfadb, + .minor_features2 =3D 0xeb9d6fbf, + .minor_features3 =3D 0xedfffced, + .minor_features4 =3D 0xd30dafc7, + .minor_features5 =3D 0x7b5ac333, + .minor_features6 =3D 0xfc8ee200, + .minor_features7 =3D 0x03fffa6f, + .minor_features8 =3D 0x00fe0ef0, + .minor_features9 =3D 0x0088003c, + .minor_features10 =3D 0x108048c0, + .minor_features11 =3D 0x00000010, + }, }; =20 bool etnaviv_fill_identity_from_hwdb(struct etnaviv_gpu *gpu) --=20 2.38.1 From nobody Thu Sep 18 23:38:04 2025 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 20A47C47088 for ; Thu, 1 Dec 2022 09:22:20 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230109AbiLAJWR (ORCPT ); Thu, 1 Dec 2022 04:22:17 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54352 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230053AbiLAJWK (ORCPT ); Thu, 1 Dec 2022 04:22:10 -0500 Received: from mail-ed1-x52b.google.com (mail-ed1-x52b.google.com [IPv6:2a00:1450:4864:20::52b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7FC2A8BD2F for ; Thu, 1 Dec 2022 01:22:08 -0800 (PST) Received: by mail-ed1-x52b.google.com with SMTP id s12so1510278edd.5 for ; Thu, 01 Dec 2022 01:22:08 -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=ZxpUnfBd0p8vcBE3KJWC/GuBXuBQqcwTN9Z0iX5mpvg=; b=HD5y/WXR910sg83kjV2BWWD+qL/7BH8Xo4u7soFHYUr5CtSS9XJJU6O7ZscoquM91K 6i8CKACWUqe/EphfLVNL2AHfOvDiEB044SEXeiwUHAsO2Jug0lRYot3mwxw96t79SLgK 2iqa6epHYKcFXijhbisR/YZ3N9lhnp//SQWLMlTdL958FSj2WhAvDdmJIWdcfV7iFcP8 tTj8SjoHaM4lifnQ1ICKCqtYfDBJitNjdgyn11dBfVbHqs2Dh+PsU617DNKiLxHj7vXx ASv/A9z6YvKKX9AVQwdse0/25qgPMFHyAACGc+tmr8vfUArHhK+A/P+quLM8po7jBoq3 IwMQ== 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=ZxpUnfBd0p8vcBE3KJWC/GuBXuBQqcwTN9Z0iX5mpvg=; b=qg8cWyBw6w1H+n8AELbl+Yi/BBWRXge4x13PGFL4t5G2vpcEcuMwC+VXDueUcoDzxw MSNPzYhaDjFDqvjl7a1JBvUoUA1sgvDKNJK7anZJlfvbyawlSvWUssveMke82e0vQk3N UM0g0B3ys7edQU2yEB5KCub3O8sUmEPaqOyH1QBIAQuumtinAunNuIicztrZmGgoH1Ye HjwpC3cOHF7WeSHbq4fnRivfAIvKtyyWbATERYwSb8wgM/My9qtdpuDqwV7kWjtqtCKc cx3aiG554kUXNi5vm3UGTArYkfjzZwr9mJxLsk8TwmrYXEgKEyckuztXtmD4yvVvw1iy GihQ== X-Gm-Message-State: ANoB5pmVC7DALDQaXMgXM8iEo7PQfCtdSrneQeyJP02P3vHhcB3brBmi Iainy2QGmpM7S8LkLm+reJw= X-Google-Smtp-Source: AA0mqf4/z8IWZm6GF+afL3r9Qn6kOIeqai5lAdazdtaxlhi3u/3DQBDzJbdDNAkDm3voiXgaDjvn1g== X-Received: by 2002:aa7:c042:0:b0:462:2f5a:8618 with SMTP id k2-20020aa7c042000000b004622f5a8618mr59546512edo.42.1669886527062; Thu, 01 Dec 2022 01:22:07 -0800 (PST) Received: from cizrna.home (cst-prg-44-69.cust.vodafone.cz. [46.135.44.69]) by smtp.gmail.com with ESMTPSA id 18-20020a170906211200b007b29eb8a4dbsm1587879ejt.13.2022.12.01.01.22.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 01 Dec 2022 01:22:06 -0800 (PST) Sender: Tomeu Vizoso From: Tomeu Vizoso Cc: italonicola@collabora.com, Tomeu Vizoso , Lucas Stach , Russell King , Christian Gmeiner , David Airlie , Daniel Vetter , etnaviv@lists.freedesktop.org (moderated list:DRM DRIVERS FOR VIVANTE GPU IP), dri-devel@lists.freedesktop.org (open list:DRM DRIVERS FOR VIVANTE GPU IP), linux-kernel@vger.kernel.org (open list) Subject: [PATCH v4 6/7] drm/etnaviv: Add nn_core_count to chip feature struct Date: Thu, 1 Dec 2022 10:21:27 +0100 Message-Id: <20221201092131.62867-7-tomeu.vizoso@collabora.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221201092131.62867-1-tomeu.vizoso@collabora.com> References: <20221201092131.62867-1-tomeu.vizoso@collabora.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable To: unlisted-recipients:; (no To-header on input) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" We will use these for differentiating between GPUs and NPUs, as the downstream driver does. Signed-off-by: Tomeu Vizoso --- drivers/gpu/drm/etnaviv/etnaviv_gpu.h | 3 +++ drivers/gpu/drm/etnaviv/etnaviv_hwdb.c | 5 +++++ 2 files changed, 8 insertions(+) diff --git a/drivers/gpu/drm/etnaviv/etnaviv_gpu.h b/drivers/gpu/drm/etnavi= v/etnaviv_gpu.h index 85eddd492774..c8f3ad2031ce 100644 --- a/drivers/gpu/drm/etnaviv/etnaviv_gpu.h +++ b/drivers/gpu/drm/etnaviv/etnaviv_gpu.h @@ -50,6 +50,9 @@ struct etnaviv_chip_identity { /* Number of shader cores. */ u32 shader_core_count; =20 + /* Number of Neural Network cores. */ + u32 nn_core_count; + /* Size of the vertex cache. */ u32 vertex_cache_size; =20 diff --git a/drivers/gpu/drm/etnaviv/etnaviv_hwdb.c b/drivers/gpu/drm/etnav= iv/etnaviv_hwdb.c index 3f6fd9a3c088..9fc5223299e4 100644 --- a/drivers/gpu/drm/etnaviv/etnaviv_hwdb.c +++ b/drivers/gpu/drm/etnaviv/etnaviv_hwdb.c @@ -16,6 +16,7 @@ static const struct etnaviv_chip_identity etnaviv_chip_id= entities[] =3D { .register_max =3D 64, .thread_count =3D 128, .shader_core_count =3D 1, + .nn_core_count =3D 0, .vertex_cache_size =3D 8, .vertex_output_buffer_size =3D 1024, .pixel_pipes =3D 1, @@ -47,6 +48,7 @@ static const struct etnaviv_chip_identity etnaviv_chip_id= entities[] =3D { .register_max =3D 64, .thread_count =3D 512, .shader_core_count =3D 2, + .nn_core_count =3D 0, .vertex_cache_size =3D 16, .vertex_output_buffer_size =3D 1024, .pixel_pipes =3D 1, @@ -78,6 +80,7 @@ static const struct etnaviv_chip_identity etnaviv_chip_id= entities[] =3D { .register_max =3D 64, .thread_count =3D 512, .shader_core_count =3D 2, + .nn_core_count =3D 0, .vertex_cache_size =3D 16, .vertex_output_buffer_size =3D 1024, .pixel_pipes =3D 1, @@ -109,6 +112,7 @@ static const struct etnaviv_chip_identity etnaviv_chip_= identities[] =3D { .register_max =3D 64, .thread_count =3D 1024, .shader_core_count =3D 4, + .nn_core_count =3D 0, .vertex_cache_size =3D 16, .vertex_output_buffer_size =3D 1024, .pixel_pipes =3D 2, @@ -140,6 +144,7 @@ static const struct etnaviv_chip_identity etnaviv_chip_= identities[] =3D { .register_max =3D 64, .thread_count =3D 256, .shader_core_count =3D 1, + .nn_core_count =3D 8, .vertex_cache_size =3D 16, .vertex_output_buffer_size =3D 1024, .pixel_pipes =3D 1, --=20 2.38.1 From nobody Thu Sep 18 23:38:04 2025 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id D0D3FC47088 for ; Thu, 1 Dec 2022 09:22:33 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230137AbiLAJWc (ORCPT ); Thu, 1 Dec 2022 04:22:32 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54422 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229771AbiLAJWM (ORCPT ); Thu, 1 Dec 2022 04:22:12 -0500 Received: from mail-ej1-x633.google.com (mail-ej1-x633.google.com [IPv6:2a00:1450:4864:20::633]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3088886594 for ; Thu, 1 Dec 2022 01:22:10 -0800 (PST) Received: by mail-ej1-x633.google.com with SMTP id b2so2707012eja.7 for ; Thu, 01 Dec 2022 01:22:10 -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=NbApf1anPXhkyL1eMhU3x4CauZkX++vBii8PykYLja0=; b=QZsc+anXmpwu6POr+6D9Nn9OjPEpMot3211JfomV93JEayXGnUjwqnbnYsuH2EqZ8J 3QXZCMWe/ss5ahcWqWboFLZL3vqDH7B6puPa4VC80uGyOA+XWxAZSpNvpk3nBom9288C +MXcRRHO4kjisktIB490p1q2A9l115vmJMhbwvAeG7wihz8OmuT0nllQW/QTj4LEF9jH IclppEXhs/6UYUPsFSzxNyc5NapjHKT2wg9uAk0fqwtaicRwaXL6M8pXSWYpWnukA9au 4O0yxq1pVanNzhwssbcok9cAVk1PkfZXjBxWXXqq+6AoALKAocWg/5c180e2YCREbuO7 8UpQ== 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=NbApf1anPXhkyL1eMhU3x4CauZkX++vBii8PykYLja0=; b=s2yHNUyuwdXiD7HVeGHNFyc6+6rkUdyCNuOc+w7lAew4CVwWBxGaROCdqjO+fPpLUP ziL8CyOzTGsFbIpCyicy0jjNN8INBbc7sUWs/76b58Vtzr4EHix8dI8EN7yQ9Yk+aa99 dpg4Z3mKEhxcnZu8ByOo4KvbmAfcMpzxLJXERu5xfTse/KCZdyLK2DqNnq49hlt+LDrx NpnAVN2PnSqCvjNKdkQCtv1Y2n0NoFRqLnz36Cu8VjmAPz931jslk5Nm/kKqFomaTXDd LSC6CbLpT/w2hywDytFoXB+hWSh4lvzWWM50Myr2zcCoVXwSA/SUVOiqdbm5Tzu9yUs2 dFtw== X-Gm-Message-State: ANoB5pndFdzZHeGyz9oVG4PzaAJSJXiIfCjTXc5S8nbg7jKQY7jvV0D7 qndcXrffIZT6Sy9FaloGiyQ= X-Google-Smtp-Source: AA0mqf63rBMYzHT+zaT6/ZqAZm1tCS3bBM8sYXQ79N+62wzUyKjm+3MLrgRd+/tgyNUfskRVnPOAVA== X-Received: by 2002:a17:907:76e2:b0:7bd:f424:b1da with SMTP id kg2-20020a17090776e200b007bdf424b1damr20991045ejc.306.1669886528176; Thu, 01 Dec 2022 01:22:08 -0800 (PST) Received: from cizrna.home (cst-prg-44-69.cust.vodafone.cz. [46.135.44.69]) by smtp.gmail.com with ESMTPSA id 18-20020a170906211200b007b29eb8a4dbsm1587879ejt.13.2022.12.01.01.22.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 01 Dec 2022 01:22:07 -0800 (PST) Sender: Tomeu Vizoso From: Tomeu Vizoso Cc: italonicola@collabora.com, Tomeu Vizoso , Lucas Stach , Russell King , Christian Gmeiner , David Airlie , Daniel Vetter , etnaviv@lists.freedesktop.org (moderated list:DRM DRIVERS FOR VIVANTE GPU IP), dri-devel@lists.freedesktop.org (open list:DRM DRIVERS FOR VIVANTE GPU IP), linux-kernel@vger.kernel.org (open list) Subject: [PATCH v4 7/7] drm/etnaviv: Warn when probing on NPUs Date: Thu, 1 Dec 2022 10:21:28 +0100 Message-Id: <20221201092131.62867-8-tomeu.vizoso@collabora.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221201092131.62867-1-tomeu.vizoso@collabora.com> References: <20221201092131.62867-1-tomeu.vizoso@collabora.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable To: unlisted-recipients:; (no To-header on input) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" Userspace is still not making full use of the hardware, so we don't know yet if changes to the UAPI won't be needed. Warn about it. Signed-off-by: Tomeu Vizoso --- drivers/gpu/drm/etnaviv/etnaviv_gpu.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/gpu/drm/etnaviv/etnaviv_gpu.c b/drivers/gpu/drm/etnavi= v/etnaviv_gpu.c index 37018bc55810..3cbc82bbf8d4 100644 --- a/drivers/gpu/drm/etnaviv/etnaviv_gpu.c +++ b/drivers/gpu/drm/etnaviv/etnaviv_gpu.c @@ -765,6 +765,10 @@ int etnaviv_gpu_init(struct etnaviv_gpu *gpu) goto fail; } =20 + if (gpu->identity.nn_core_count > 0) + dev_warn(gpu->dev, "etnaviv has been instantiated on a NPU, " + "for which the UAPI is still experiment= al\n"); + /* Exclude VG cores with FE2.0 */ if (gpu->identity.features & chipFeatures_PIPE_VG && gpu->identity.features & chipFeatures_FE20) { --=20 2.38.1