From patchwork Fri Mar 9 10:14:45 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Paul Kocialkowski X-Patchwork-Id: 10270353 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 23B126016D for ; Fri, 9 Mar 2018 10:17:37 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 08E2A28CA1 for ; Fri, 9 Mar 2018 10:17:37 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id F05CE28CCB; Fri, 9 Mar 2018 10:17: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=-1.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID autolearn=unavailable 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 6EFB028CA1 for ; Fri, 9 Mar 2018 10:17: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:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id: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=t2+lInS2o7bbI9pg+qb9FGvVEm03jCw1jR7SGIGBQpg=; b=LVHOfdhy4dpQCrZUkBV9WPEMq6 D2zROIC5EwXVkYqz9x5kf0lywkNZeUTpEcSCSWYiU0u4Gv06mhq2QYMgxDK1/j9hf1Zxg9raFooBt hvi2biAEi7N2LaqDTNIXGMRQWu3QjdpDTuApetwpn6VmHpWcGDyPG9/OEihyqYg+p8sny0ZpxgBBC oi3GY5SVIELBLyYUVXzokfsN03BM3xY9MPvbmZ7XLyBlXNR0W2BLKLbfLfMPDd0Uk27F6aFys/brd vczUdBjGvZIBYNrU0YUETbyvJc7vLJMERXj5qcc9pWSx2G+YnEL9cAdcH3sL0JMvFX5v7ej3Cfbv5 rG3Yq0XQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.89 #1 (Red Hat Linux)) id 1euF5Z-0001h0-7a; Fri, 09 Mar 2018 10:17:25 +0000 Received: from mail.bootlin.com ([62.4.15.54]) by bombadil.infradead.org with esmtp (Exim 4.89 #1 (Red Hat Linux)) id 1euF4R-0000p4-A2 for linux-arm-kernel@lists.infradead.org; Fri, 09 Mar 2018 10:16:25 +0000 Received: by mail.bootlin.com (Postfix, from userid 110) id 76C2720712; Fri, 9 Mar 2018 11:15:52 +0100 (CET) Received: from localhost.localdomain (LStLambert-657-1-97-87.w90-63.abo.wanadoo.fr [90.63.216.87]) by mail.bootlin.com (Postfix) with ESMTPSA id EC17020644; Fri, 9 Mar 2018 11:15:51 +0100 (CET) From: Paul Kocialkowski To: linux-media@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-sunxi@googlegroups.com Subject: [PATCH 9/9] ARM: dts: sun7i: Add video engine support for the A20 Date: Fri, 9 Mar 2018 11:14:45 +0100 Message-Id: <20180309101445.16190-7-paul.kocialkowski@bootlin.com> X-Mailer: git-send-email 2.16.2 In-Reply-To: <20180309100933.15922-3-paul.kocialkowski@bootlin.com> References: <20180309100933.15922-3-paul.kocialkowski@bootlin.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20180309_021615_952925_15A6BF72 X-CRM114-Status: GOOD ( 14.83 ) 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: "Signed-off-by : Bob Ham" , Thomas Petazzoni , Alexandre Courbot , Maxime Ripard , Chen-Yu Tsai , Florent Revest , Hans Verkuil , Icenowy Zheng , Sakari Ailus , Thomas van Kleef , Laurent Pinchart MIME-Version: 1.0 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: Thomas van Kleef The A20 has a video engine similare to the one in the A13. Add the device node in the A20. Signed-off-by: Thomas van Kleef Signed-off-by: Maxime Ripard --- arch/arm/boot/dts/sun7i-a20.dtsi | 47 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) diff --git a/arch/arm/boot/dts/sun7i-a20.dtsi b/arch/arm/boot/dts/sun7i-a20.dtsi index bd0cd3204273..b0d21208af87 100644 --- a/arch/arm/boot/dts/sun7i-a20.dtsi +++ b/arch/arm/boot/dts/sun7i-a20.dtsi @@ -53,6 +53,35 @@ / { interrupt-parent = <&gic>; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; + + /* + * MUST TO BE IN THE LOWER 256MB of RAM for the VE! + * Src: http://linux-sunxi.org/Sunxi-cedrus "A + * limitation of the Allwinner's VPU is the need for + * buffers in the lower 256M of RAM. In order to + * allocate large sets of data in this area, + * "sunxi-cedrus" reserves a DMA pool that is then + * used by videobuf's dma-contig backend() to allocate + * input and output buffers easily and integrate that + * with the v4l QBUF/DQBUF APIs." + * + * The lower limit is 0x41000000 but the kernel has to + * be moved somewhere else in order to use this + * region. + */ + + ve_reserved: cma { + compatible = "shared-dma-pool"; + reg = <0x41000000 0x9000000>; + no-map; + linux,cma-default; + }; + }; + aliases { ethernet0 = &gmac; }; @@ -451,6 +480,24 @@ }; }; + ve: video-engine@01c0e000 { + compatible = "allwinner,sun4i-a10-video-engine"; + memory-region = <&ve_reserved>; + + clocks = <&ccu CLK_AHB_VE>, <&ccu CLK_VE>, + <&ccu CLK_DRAM_VE>; + clock-names = "ahb", "mod", "ram"; + + assigned-clocks = <&ccu CLK_VE>; + assigned-clock-rates = <320000000>; + + resets = <&ccu RST_VE>; + + interrupts = ; + + reg = <0x01c0e000 0x1000>; + }; + mmc0: mmc@1c0f000 { compatible = "allwinner,sun7i-a20-mmc"; reg = <0x01c0f000 0x1000>;