From patchwork Mon Nov 27 22:37:12 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Brandon Brnich X-Patchwork-Id: 13470381 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id C8CC9C10DAA for ; Mon, 27 Nov 2023 22:38:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:CC:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=AXKrn6+PWyUDsMhh7FaFYfMspG0YAlTcmhgmP+xWtC4=; b=CJQrhf3UX/malS Bm8iFH7mWDMCBI3rtri0FW9yK0blN4LdSbMOSlY+OQZjHmPQLwOocNMHoDzGD6gQa/atHeKFe5YYd dbrerFVhSI78NPLGSZl6wKL342RtSZRtL5JPiCxw1kmXtQJRoQkHZuF6QuNrThJcBRboM7yCBc2FC EId9qbut8IpQjaL6ymIKot+msWR5OjKJuSB03Y2nDYteH2yP2WaADKlbAVxg7kHZFzeYO43gfpyeN G7KMtos8RGrLrue5soprCWnGp4cQ9rIyjFhEBSJHUOZjSC8P4eIV9DPHBEanzxiCufciWtsYeLMZp RPZ/iTHNxvx1wZBLfrkA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1r7kEm-003bdO-2s; Mon, 27 Nov 2023 22:37:56 +0000 Received: from fllv0015.ext.ti.com ([198.47.19.141]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1r7kES-003bVq-3B for linux-arm-kernel@lists.infradead.org; Mon, 27 Nov 2023 22:37:40 +0000 Received: from fllv0034.itg.ti.com ([10.64.40.246]) by fllv0015.ext.ti.com (8.15.2/8.15.2) with ESMTP id 3ARMbPxJ013759; Mon, 27 Nov 2023 16:37:25 -0600 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1701124645; bh=gHRsQAHBwfqZPAF5xGal+oWH/Jueq5iCBVQ3IjdM/EQ=; h=From:To:CC:Subject:Date:In-Reply-To:References; b=DHJmL23BK/ER4lYyReLPaBK59kA9BvwTfSxKdAV6MKbOu4icgsS4B8yJM19ZjXe/G odXIuKIJSoJSTYtgequ3QhTG89ZVB+6BaI+LeaDKa3ZwdVRrynSXcT7Ol8WYWMcwvD ghRZJUsC0mZVk9FIRwaJ499jVqNdPGo+UOTJKI9I= Received: from DLEE109.ent.ti.com (dlee109.ent.ti.com [157.170.170.41]) by fllv0034.itg.ti.com (8.15.2/8.15.2) with ESMTPS id 3ARMbP2m047985 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Mon, 27 Nov 2023 16:37:25 -0600 Received: from DLEE111.ent.ti.com (157.170.170.22) by DLEE109.ent.ti.com (157.170.170.41) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23; Mon, 27 Nov 2023 16:37:25 -0600 Received: from lelv0327.itg.ti.com (10.180.67.183) by DLEE111.ent.ti.com (157.170.170.22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23 via Frontend Transport; Mon, 27 Nov 2023 16:37:25 -0600 Received: from udba0500997.dhcp.ti.com (ileaxei01-snat.itg.ti.com [10.180.69.5]) by lelv0327.itg.ti.com (8.15.2/8.15.2) with ESMTP id 3ARMbOdh097304; Mon, 27 Nov 2023 16:37:25 -0600 From: Brandon Brnich To: Nishanth Menon , , Vignesh Raghavendra , Sebastian Fricke , Nas Chung CC: Darren Etheridge , Devarsh Thakkar , Praneeth Bajjuri , Brandon Brnich , Prasanth Mantena Subject: [PATCH 1/7] arm64: dts: ti: k3-j784s4: Add Wave5 Video Encoder/Decoder Node Date: Mon, 27 Nov 2023 16:37:12 -0600 Message-ID: <20231127223718.2651185-2-b-brnich@ti.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231127223718.2651185-1-b-brnich@ti.com> References: <20231127223718.2651185-1-b-brnich@ti.com> MIME-Version: 1.0 X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20231127_143737_166150_6DAF0B66 X-CRM114-Status: GOOD ( 12.72 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org This patch adds support for the Wave521cl on the J784S4-evm. The node requires an SRAM buffer to reduce bandwidth by saving temporal information. Allocate 126K for this as specified in documentation. Wave521cl needs to use CMA as there is no IO MMU on J784S4-evm. Each 1080p channel requires roughly 98-100 MB. Allocate 1792 MB to meet 16 channel capability for J784S4-evm. Signed-off-by: Brandon Brnich --- arch/arm64/boot/dts/ti/k3-j784s4-evm.dts | 16 +++++++++++++ arch/arm64/boot/dts/ti/k3-j784s4-main.dtsi | 26 ++++++++++++++++++++++ arch/arm64/boot/dts/ti/k3-j784s4.dtsi | 2 ++ 3 files changed, 44 insertions(+) diff --git a/arch/arm64/boot/dts/ti/k3-j784s4-evm.dts b/arch/arm64/boot/dts/ti/k3-j784s4-evm.dts index f1f4c8634ab6..ff72674acae2 100644 --- a/arch/arm64/boot/dts/ti/k3-j784s4-evm.dts +++ b/arch/arm64/boot/dts/ti/k3-j784s4-evm.dts @@ -41,6 +41,14 @@ reserved_memory: reserved-memory { #size-cells = <2>; ranges; + /* global cma region */ + linux,cma { + compatible = "shared-dma-pool"; + reusable; + size = <0x00 0x70000000>; + linux,cma-default; + }; + secure_ddr: optee@9e800000 { reg = <0x00 0x9e800000 0x00 0x01800000>; no-map; @@ -682,6 +690,14 @@ &main_gpio0 { status = "okay"; }; +&vpu0 { + status = "okay"; +}; + +&vpu1 { + status = "okay"; +}; + &mcu_cpsw { status = "okay"; pinctrl-names = "default"; diff --git a/arch/arm64/boot/dts/ti/k3-j784s4-main.dtsi b/arch/arm64/boot/dts/ti/k3-j784s4-main.dtsi index d89bcddcfe3d..8c0c3f171120 100644 --- a/arch/arm64/boot/dts/ti/k3-j784s4-main.dtsi +++ b/arch/arm64/boot/dts/ti/k3-j784s4-main.dtsi @@ -32,6 +32,10 @@ atf-sram@0 { reg = <0x00 0x20000>; }; + vpu_sram: vpu-sram@20000 { + reg = <0x20000 0x1f800>; + }; + tifs-sram@1f0000 { reg = <0x1f0000 0x10000>; }; @@ -662,6 +666,28 @@ main_i2c6: i2c@2060000 { status = "disabled"; }; + vpu0: video-codec@4210000 { + compatible = "cnm,cm521c-vpu"; + reg = <0x00 0x4210000 0x00 0x10000>; + interrupts = ; + clocks = <&k3_clks 241 2>; + clock-names = "vcodec"; + power-domains = <&k3_pds 241 TI_SCI_PD_EXCLUSIVE>; + sram = <&vpu_sram>; + status = "disabled"; + }; + + vpu1: video-codec@4220000 { + compatible = "cnm,cm521c-vpu"; + reg = <0x00 0x4220000 0x00 0x10000>; + interrupts = ; + clocks = <&k3_clks 242 2>; + clock-names = "vcodec"; + power-domains = <&k3_pds 242 TI_SCI_PD_EXCLUSIVE>; + sram = <&vpu_sram>; + status = "disabled"; + }; + main_sdhci0: mmc@4f80000 { compatible = "ti,j721e-sdhci-8bit"; reg = <0x00 0x04f80000 0x00 0x1000>, diff --git a/arch/arm64/boot/dts/ti/k3-j784s4.dtsi b/arch/arm64/boot/dts/ti/k3-j784s4.dtsi index 4398c3a463e1..93bb0cba1b48 100644 --- a/arch/arm64/boot/dts/ti/k3-j784s4.dtsi +++ b/arch/arm64/boot/dts/ti/k3-j784s4.dtsi @@ -247,6 +247,8 @@ cbass_main: bus@100000 { <0x00 0x30000000 0x00 0x30000000 0x00 0x0c400000>, /* MAIN NAVSS */ <0x41 0x00000000 0x41 0x00000000 0x01 0x00000000>, /* PCIe1 DAT1 */ <0x4e 0x20000000 0x4e 0x20000000 0x00 0x00080000>, /* GPU */ + <0x00 0x04210000 0x00 0x04210000 0x00 0x00010000>, /* VPU0 */ + <0x00 0x04220000 0x00 0x04220000 0x00 0x00010000>, /* VPU1 */ /* MCUSS_WKUP Range */ <0x00 0x28380000 0x00 0x28380000 0x00 0x03880000>,