From patchwork Wed Aug 1 18:51:24 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxime Jourdan X-Patchwork-Id: 10552805 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 07CD415E2 for ; Wed, 1 Aug 2018 18:52:18 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 00BDC2B9F8 for ; Wed, 1 Aug 2018 18:52:18 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id E92872BA7A; Wed, 1 Aug 2018 18:52:17 +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=-2.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,FREEMAIL_FROM,MAILING_LIST_MULTI 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 6CADA2B9F8 for ; Wed, 1 Aug 2018 18:52: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:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id: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:In-Reply-To: References:List-Owner; bh=+As48NEWFk1YKKSaKhD0Gvud/ga2VthyMZcVsWxldzA=; b=Yci ywEq3/ojDQmaN8zKYrhg17BpWdxzPSNBD1IAE/dZvwvJ+rmVCmNyebMV4IBR3hDk51Uk11mq+c+Aq VfXw1pqP/TcwHEACs8E8Vgw0f4eJ3xivDyfEwvhWkwo+7qfgYsmBn42h2tr7MagfJheiCydzZ6+P8 Eph/AQq2qV75JH2rF4Q38sTF1kKfbOut1459RJmsnDRUZHLD1xlzFagMkqDG/Sme0UZBbrRMLnb8Y rouTAPFF5S32DiJkL1HY5puB0Hw4opi6wvEwGxIzfluaqqnWbO7Qd/4pEVF33OEESZ8724QVQfCSD Cd1qqZVeEmvUsUOgtWLubHnu12gyAYg==; 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 1fkwEF-00030I-U6; Wed, 01 Aug 2018 18:52:11 +0000 Received: from smtp10.smtpout.orange.fr ([80.12.242.132] helo=smtp.smtpout.orange.fr) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1fkwEB-0002x7-RG for linux-arm-kernel@lists.infradead.org; Wed, 01 Aug 2018 18:52:09 +0000 Received: from localhost.localdomain ([81.67.76.113]) by mwinf5d86 with ME id Huro1y0012Sg6Vd03urr0A; Wed, 01 Aug 2018 20:51:52 +0200 X-ME-Helo: localhost.localdomain X-ME-Auth: bWF4aS5qb3VyZGFuQHdhbmFkb28uZnI= X-ME-Date: Wed, 01 Aug 2018 20:51:52 +0200 X-ME-IP: 81.67.76.113 From: Maxime Jourdan To: linux-amlogic@lists.infradead.org Subject: [PATCH 0/4] soc: amlogic: add meson-canvas driver Date: Wed, 1 Aug 2018 20:51:24 +0200 Message-Id: <20180801185128.23440-1-maxi.jourdan@wanadoo.fr> X-Mailer: git-send-email 2.17.1 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20180801_115208_253138_362F2F50 X-CRM114-Status: GOOD ( 11.50 ) 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: devicetree@vger.kernel.org, Neil Armstrong , Kevin Hilman , linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, Maxime Jourdan , linux-arm-kernel@lists.infradead.org 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 Amlogic SoCs feature a set of 256 canvas that act as pixel buffer descriptors. Some IPs like the display and video decoders access those pixels by using canvas IDs rather than direct phy addresses. As such, allocating/manipulating canvases can be done concurrently and there is a need for a standalone, lock-aware canvas provider module. Currently, canvas code lies in the drm/meson module as it is the sole user. This patchset adds such canvas provider module and converts drm/meson to using it, stripping/moving the current canvas code. Maxime Jourdan (4): soc: amlogic: add meson-canvas driver dt-bindings: soc: amlogic: add meson-canvas documentation ARM64: dts: meson-gx: add dmcbus and canvas nodes. drm/meson: convert to the new canvas module .../bindings/display/amlogic,meson-vpu.txt | 9 +- .../soc/amlogic/amlogic,meson-canvas.txt | 36 ++++ arch/arm64/boot/dts/amlogic/meson-gx.dtsi | 24 ++- drivers/gpu/drm/meson/Kconfig | 1 + drivers/gpu/drm/meson/Makefile | 2 +- drivers/gpu/drm/meson/meson_canvas.c | 70 ------- drivers/gpu/drm/meson/meson_canvas.h | 42 ---- drivers/gpu/drm/meson/meson_crtc.c | 5 +- drivers/gpu/drm/meson/meson_drv.c | 35 ++-- drivers/gpu/drm/meson/meson_drv.h | 5 +- drivers/gpu/drm/meson/meson_plane.c | 3 +- drivers/gpu/drm/meson/meson_viu.c | 1 - drivers/soc/amlogic/Kconfig | 7 + drivers/soc/amlogic/Makefile | 1 + drivers/soc/amlogic/meson-canvas.c | 182 ++++++++++++++++++ include/linux/soc/amlogic/meson-canvas.h | 37 ++++ 16 files changed, 319 insertions(+), 141 deletions(-) create mode 100644 Documentation/devicetree/bindings/soc/amlogic/amlogic,meson-canvas.txt delete mode 100644 drivers/gpu/drm/meson/meson_canvas.c delete mode 100644 drivers/gpu/drm/meson/meson_canvas.h create mode 100644 drivers/soc/amlogic/meson-canvas.c create mode 100644 include/linux/soc/amlogic/meson-canvas.h