From patchwork Thu Aug 23 11:49:51 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxime Jourdan X-Patchwork-Id: 10573763 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 5D5A7920 for ; Thu, 23 Aug 2018 12:01:04 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 4A7852BDC0 for ; Thu, 23 Aug 2018 12:01:04 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 3DF3C2BE15; Thu, 23 Aug 2018 12:01:04 +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,MAILING_LIST_MULTI,RCVD_IN_DNSWL_NONE 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 E64F62BDB6 for ; Thu, 23 Aug 2018 12:01:03 +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=bNaSeW8wD8/9g+N0LvTCA7WIWOKRgIV/VXfi3GeMiFY=; b=KMc 7Z/Z+f7dxSWIVhUpEk/n1BajWmRwWWvvgOdvzSkpdB3Hi8B682Ho/OZobja5aSr2VaLLyPhykXti7 SUpI9CCzrl54EXT2GD6TfT1/sczdxIzyJ1rtiYMlTysGIO1ikwREiRYIqcObeYipVFDUI28tq4NvL E5XWch2jxkpVEu/6dZV8ExviXq1HPIA94EPNfUh/Uk0lXaHK3SRnLUYqX/WAVfs1zWB8xA1bfNp4h cGhgGUM370N3Y5BUnAdRYFTEVhNEG1TbLgXdPW7z04QcMC5rb9/o7x3dtPSfM+7DbB4c0veQ1tUsr duEUCzaOxiOKpjW1jFU4B3/GyfPsh2w==; 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 1fsoIP-0006Kh-9m; Thu, 23 Aug 2018 12:01:01 +0000 Received: from mail-wr1-x441.google.com ([2a00:1450:4864:20::441]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1fsoIK-0006GN-80 for linux-arm-kernel@lists.infradead.org; Thu, 23 Aug 2018 12:00:58 +0000 Received: by mail-wr1-x441.google.com with SMTP id j26-v6so4429241wre.2 for ; Thu, 23 Aug 2018 05:00:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id; bh=g1mfP/sOo/HQjJ7c7Fb0EYo8huXwFK/AM/SI3qAjqoU=; b=ShXQ+qF+cO44SQLJkTkZyvmZwCKIEiyLgCYDL5oIAxZ3jvStRMbCudlZwZe/Pnv3jp 7XvaddEnUrgfOsYAVtF6lJv/qG/p93CePArRxGUMM3v1prWDDK/LckLsFxPLr+2gbeHg wK2W3T2F7WgMtvNPRNv/qacCJ4wAULCdLz3YTc22e6b0zDnMrk55nWbR9+bQsXKMylb3 jv92OnAhPvxCnPmim1Lp9FXHMaekGNnNqRiPOCn5TM5TDYYlOkZxL2wI2QSB6vujmAc2 gzneUzecmIFnKumXyNWdZ8dpwbUX7K117pmkyoFUj67sMQWUDivtsSm5lDvewrAjt3s/ /6lg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=g1mfP/sOo/HQjJ7c7Fb0EYo8huXwFK/AM/SI3qAjqoU=; b=oz4e9RABah1bqY7gC2QF35w8aJYxYrsfKhSXUCWraCs3oKxg3cuDX2DJ+KWJQTK71t roFEAH9y/AxPv46RRjMTW/78SDGMxJpQmU4cMsXbV3uVSm+sJW+LbYJDxmoWI5nY5Pyf hEyanSL/JbPREp8HWY91Ef7c4bpWo1zg+RhuF1AavF9NBa2MA79Mr6ox94Tzgtcvf/I3 R+5gaBfpgHaCxhlLBgUAQ71D5kgWzIiRahg4zM1fv/t8mPnmGtoR3TN4AujOZzccV9+y QLWCTxdIyXr+3u3JO/mkaehgfgClL0CzctCuSYkRMrWW6/V2ypcupxK8h8h2v89uDGOC FTSQ== X-Gm-Message-State: APzg51AaJPXeADqti5nGxGvVrElV2mMHRb6XytSJiwrhlDFm+G23vuEk H/gif/uGYQjz/hmET55OTGpMtg== X-Google-Smtp-Source: ANB0VdZ1eQ867GNMeKV7jfPEvgyYzZLk9x5cwA86rRtVQDs2+8pd3AiPCKOLO5I43bw9+VjmLS7tFw== X-Received: by 2002:adf:e5c4:: with SMTP id a4-v6mr2337085wrn.190.1535025643617; Thu, 23 Aug 2018 05:00:43 -0700 (PDT) Received: from localhost.localdomain (81-67-76-113.rev.numericable.fr. [81.67.76.113]) by smtp.gmail.com with ESMTPSA id y10-v6sm2830419wrl.87.2018.08.23.05.00.42 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 23 Aug 2018 05:00:42 -0700 (PDT) From: Maxime Jourdan To: linux-amlogic@lists.infradead.org Subject: [PATCH v3 0/3] soc: amlogic: add meson-canvas Date: Thu, 23 Aug 2018 13:49:51 +0200 Message-Id: <20180823114954.30704-1-mjourdan@baylibre.com> X-Mailer: git-send-email 2.18.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20180823_050056_287235_D53653BC X-CRM114-Status: GOOD ( 11.52 ) 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: Maxime Jourdan , devicetree@vger.kernel.org, Neil Armstrong , Kevin Hilman , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Jerome Brunet 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. Changes since v2: [1] - Don't include the drm changes in the serie. - Remove the syscon node in the dts and doc - Rename meson_canvas_setup to meson_canvas_config Changes since v1: [0] - Convert ops struct to a public API - Added comments - Hid the of-node probe code behind meson_canvas_get - Changed device lock to a spinlock with irqsave [0]: https://lkml.org/lkml/2018/8/1/1512 [1]: https://lkml.org/lkml/2018/8/7/894 Maxime Jourdan (3): dt-bindings: soc: amlogic: add meson-canvas documentation soc: amlogic: add meson-canvas driver ARM64: dts: meson-gx: add dmcbus and canvas nodes. .../bindings/soc/amlogic/amlogic,canvas.txt | 29 +++ arch/arm64/boot/dts/amlogic/meson-gx.dtsi | 13 ++ drivers/soc/amlogic/Kconfig | 7 + drivers/soc/amlogic/Makefile | 1 + drivers/soc/amlogic/meson-canvas.c | 185 ++++++++++++++++++ include/linux/soc/amlogic/meson-canvas.h | 65 ++++++ 6 files changed, 300 insertions(+) create mode 100644 Documentation/devicetree/bindings/soc/amlogic/amlogic,canvas.txt create mode 100644 drivers/soc/amlogic/meson-canvas.c create mode 100644 include/linux/soc/amlogic/meson-canvas.h