From patchwork Mon May 26 14:19:39 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Philipp Zabel X-Patchwork-Id: 4242791 Return-Path: X-Original-To: patchwork-linux-fbdev@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 801F2BF90B for ; Mon, 26 May 2014 14:20:09 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 5ED0920149 for ; Mon, 26 May 2014 14:20:08 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id C35FD20222 for ; Mon, 26 May 2014 14:20:06 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752444AbaEZOUG (ORCPT ); Mon, 26 May 2014 10:20:06 -0400 Received: from metis.ext.pengutronix.de ([92.198.50.35]:37546 "EHLO metis.ext.pengutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752452AbaEZOUF (ORCPT ); Mon, 26 May 2014 10:20:05 -0400 Received: from dude.hi.pengutronix.de ([10.1.0.7] helo=dude.pengutronix.de) by metis.ext.pengutronix.de with esmtp (Exim 4.72) (envelope-from ) id 1Wovka-0004LD-31; Mon, 26 May 2014 16:19:40 +0200 From: Philipp Zabel To: Greg Kroah-Hartman , Russell King , Dave Airlie Cc: Tomi Valkeinen , Shawn Guo , dri-devel@lists.freedesktop.org, linux-fbdev@vger.kernel.org, devel@driverdev.osuosl.org, drm-devel@vger.kernel.org, kernel@pengutronix.de, Philipp Zabel , Lucas Stach Subject: [PATCH v2 1/5] gpu: ipu-v3: Move i.MX IPUv3 core driver out of staging Date: Mon, 26 May 2014 16:19:39 +0200 Message-Id: <1401113983-23132-2-git-send-email-p.zabel@pengutronix.de> X-Mailer: git-send-email 2.0.0.rc2 In-Reply-To: <1401113983-23132-1-git-send-email-p.zabel@pengutronix.de> References: <1401113983-23132-1-git-send-email-p.zabel@pengutronix.de> X-SA-Exim-Connect-IP: 10.1.0.7 X-SA-Exim-Mail-From: p.zabel@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-fbdev@vger.kernel.org Sender: linux-fbdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org X-Spam-Status: No, score=-7.5 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The i.MX Image Processing Unit (IPU) contains a number of image processing blocks that sit right in the middle between DRM and V4L2. Some of the modules, such as Display Controller, Processor, and Interface (DC, DP, DI) or CMOS Sensor Interface (CSI) and their FIFOs could be assigned to either framework, but others, such as the dma controller (IDMAC) and image converter (IC) can be used by both. The IPUv3 core driver provides an internal API to access the modules, to be used by both DRM and V4L2 IPUv3 drivers. Signed-off-by: Lucas Stach Signed-off-by: Philipp Zabel Acked-by: Greg Kroah-Hartman --- Changes since RFC: - Rebased onto current staging-next - Removed an unrelated change to ipu_pixelformat_to_colorspace - Avoided moving around the IPU_PIX_FMT_GBR24 #define --- drivers/gpu/Makefile | 1 + drivers/gpu/ipu-v3/Kconfig | 7 +++++++ drivers/{staging/imx-drm => gpu}/ipu-v3/Makefile | 2 +- drivers/{staging/imx-drm => gpu}/ipu-v3/ipu-common.c | 2 +- drivers/{staging/imx-drm => gpu}/ipu-v3/ipu-dc.c | 3 +-- drivers/{staging/imx-drm => gpu}/ipu-v3/ipu-di.c | 2 +- drivers/{staging/imx-drm => gpu}/ipu-v3/ipu-dmfc.c | 2 +- drivers/{staging/imx-drm => gpu}/ipu-v3/ipu-dp.c | 2 +- drivers/{staging/imx-drm => gpu}/ipu-v3/ipu-prv.h | 2 +- drivers/staging/imx-drm/Kconfig | 11 +---------- drivers/staging/imx-drm/Makefile | 1 - drivers/staging/imx-drm/imx-hdmi.c | 2 +- drivers/staging/imx-drm/imx-tve.c | 2 +- drivers/staging/imx-drm/ipuv3-crtc.c | 2 +- drivers/staging/imx-drm/ipuv3-plane.c | 2 +- drivers/video/Kconfig | 1 + .../staging/imx-drm/ipu-v3 => include/video}/imx-ipu-v3.h | 0 17 files changed, 21 insertions(+), 23 deletions(-) create mode 100644 drivers/gpu/ipu-v3/Kconfig rename drivers/{staging/imx-drm => gpu}/ipu-v3/Makefile (59%) rename drivers/{staging/imx-drm => gpu}/ipu-v3/ipu-common.c (99%) rename drivers/{staging/imx-drm => gpu}/ipu-v3/ipu-dc.c (99%) rename drivers/{staging/imx-drm => gpu}/ipu-v3/ipu-di.c (99%) rename drivers/{staging/imx-drm => gpu}/ipu-v3/ipu-dmfc.c (99%) rename drivers/{staging/imx-drm => gpu}/ipu-v3/ipu-dp.c (99%) rename drivers/{staging/imx-drm => gpu}/ipu-v3/ipu-prv.h (99%) rename {drivers/staging/imx-drm/ipu-v3 => include/video}/imx-ipu-v3.h (100%) diff --git a/drivers/staging/imx-drm/ipu-v3/imx-ipu-v3.h b/include/video/imx-ipu-v3.h similarity index 100% rename from drivers/staging/imx-drm/ipu-v3/imx-ipu-v3.h rename to include/video/imx-ipu-v3.h diff --git a/drivers/gpu/Makefile b/drivers/gpu/Makefile index d8a22c2..70da9eb 100644 --- a/drivers/gpu/Makefile +++ b/drivers/gpu/Makefile @@ -1,2 +1,3 @@ obj-y += drm/ vga/ obj-$(CONFIG_TEGRA_HOST1X) += host1x/ +obj-$(CONFIG_IMX_IPUV3_CORE) += ipu-v3/ diff --git a/drivers/gpu/ipu-v3/Kconfig b/drivers/gpu/ipu-v3/Kconfig new file mode 100644 index 0000000..2f228a2 --- /dev/null +++ b/drivers/gpu/ipu-v3/Kconfig @@ -0,0 +1,7 @@ +config IMX_IPUV3_CORE + tristate "IPUv3 core support" + depends on SOC_IMX5 || SOC_IMX6Q || SOC_IMX6SL || ARCH_MULTIPLATFORM + depends on RESET_CONTROLLER + help + Choose this if you have a i.MX5/6 system and want to use the Image + Processing Unit. This option only enables IPU base support. diff --git a/drivers/staging/imx-drm/ipu-v3/Makefile b/drivers/gpu/ipu-v3/Makefile similarity index 59% rename from drivers/staging/imx-drm/ipu-v3/Makefile rename to drivers/gpu/ipu-v3/Makefile index 28ed72e..d21cc37 100644 --- a/drivers/staging/imx-drm/ipu-v3/Makefile +++ b/drivers/gpu/ipu-v3/Makefile @@ -1,3 +1,3 @@ -obj-$(CONFIG_DRM_IMX_IPUV3_CORE) += imx-ipu-v3.o +obj-$(CONFIG_IMX_IPUV3_CORE) += imx-ipu-v3.o imx-ipu-v3-objs := ipu-common.o ipu-dc.o ipu-di.o ipu-dp.o ipu-dmfc.o diff --git a/drivers/staging/imx-drm/ipu-v3/ipu-common.c b/drivers/gpu/ipu-v3/ipu-common.c similarity index 99% rename from drivers/staging/imx-drm/ipu-v3/ipu-common.c rename to drivers/gpu/ipu-v3/ipu-common.c index a1f7b20..ad99477 100644 --- a/drivers/staging/imx-drm/ipu-v3/ipu-common.c +++ b/drivers/gpu/ipu-v3/ipu-common.c @@ -31,7 +31,7 @@ #include -#include "imx-ipu-v3.h" +#include