All of lore.kernel.org
 help / color / mirror / Atom feed
From: rmk+kernel@arm.linux.org.uk (Russell King)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 19/34] imx-drm: remove imx-fb.c
Date: Tue, 18 Feb 2014 20:11:13 +0000	[thread overview]
Message-ID: <E1WFr0b-0007jb-Rr@rmk-PC.arm.linux.org.uk> (raw)
In-Reply-To: <20140218200900.GM21483@n2100.arm.linux.org.uk>

imx-fb.c doesn't need to be separate from imx-drm-core.c - all it is
doing is setting up the minimum and maximum sizes of the scanout
buffers, and setting up the mode_config function pointers.  Move the
contents into imx-drm-core.c and kill this file.

Acked-by: Philipp Zabel <p.zabel@pengutronix.de>
Acked-by: Shawn Guo <shawn.guo@linaro.org>
Reviewed-by: Fabio Estevam <fabio.estevam@freescale.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
---
 drivers/staging/imx-drm/Makefile       |  2 +-
 drivers/staging/imx-drm/imx-drm-core.c | 16 +++++++++++-
 drivers/staging/imx-drm/imx-fb.c       | 47 ----------------------------------
 3 files changed, 16 insertions(+), 49 deletions(-)
 delete mode 100644 drivers/staging/imx-drm/imx-fb.c

diff --git a/drivers/staging/imx-drm/Makefile b/drivers/staging/imx-drm/Makefile
index 5239f908ceec..129e3a3f59f1 100644
--- a/drivers/staging/imx-drm/Makefile
+++ b/drivers/staging/imx-drm/Makefile
@@ -1,5 +1,5 @@
 
-imxdrm-objs := imx-drm-core.o imx-fb.o
+imxdrm-objs := imx-drm-core.o
 
 obj-$(CONFIG_DRM_IMX) += imxdrm.o
 
diff --git a/drivers/staging/imx-drm/imx-drm-core.c b/drivers/staging/imx-drm/imx-drm-core.c
index 5a60886b3a6b..3e3fd281fe6e 100644
--- a/drivers/staging/imx-drm/imx-drm-core.c
+++ b/drivers/staging/imx-drm/imx-drm-core.c
@@ -381,6 +381,10 @@ static void imx_drm_connector_unregister(
 	drm_mode_group_reinit(imxdrm->drm);
 }
 
+static struct drm_mode_config_funcs imx_drm_mode_config_funcs = {
+	.fb_create = drm_fb_cma_create,
+};
+
 /*
  * Main DRM initialisation. This binds, initialises and registers
  * with DRM the subcomponents of the driver.
@@ -406,8 +410,18 @@ static int imx_drm_driver_load(struct drm_device *drm, unsigned long flags)
 	 */
 	drm->irq_enabled = true;
 
+	/*
+	 * set max width and height as default value(4096x4096).
+	 * this value would be used to check framebuffer size limitation
+	 * at drm_mode_addfb().
+	 */
+	drm->mode_config.min_width = 64;
+	drm->mode_config.min_height = 64;
+	drm->mode_config.max_width = 4096;
+	drm->mode_config.max_height = 4096;
+	drm->mode_config.funcs = &imx_drm_mode_config_funcs;
+
 	drm_mode_config_init(drm);
-	imx_drm_mode_config_init(drm);
 
 	mutex_lock(&imxdrm->mutex);
 
diff --git a/drivers/staging/imx-drm/imx-fb.c b/drivers/staging/imx-drm/imx-fb.c
deleted file mode 100644
index 03a7b4e14f67..000000000000
--- a/drivers/staging/imx-drm/imx-fb.c
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * i.MX drm driver
- *
- * Copyright (C) 2012 Sascha Hauer, Pengutronix
- *
- * Based on Samsung Exynos code
- *
- * Copyright (c) 2011 Samsung Electronics Co., Ltd.
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- */
-#include <linux/module.h>
-#include <drm/drmP.h>
-#include <drm/drm_crtc.h>
-#include <drm/drm_crtc_helper.h>
-#include <drm/drm_gem_cma_helper.h>
-#include <drm/drm_fb_cma_helper.h>
-
-#include "imx-drm.h"
-
-static struct drm_mode_config_funcs imx_drm_mode_config_funcs = {
-	.fb_create = drm_fb_cma_create,
-};
-
-void imx_drm_mode_config_init(struct drm_device *dev)
-{
-	dev->mode_config.min_width = 64;
-	dev->mode_config.min_height = 64;
-
-	/*
-	 * set max width and height as default value(4096x4096).
-	 * this value would be used to check framebuffer size limitation
-	 * at drm_mode_addfb().
-	 */
-	dev->mode_config.max_width = 4096;
-	dev->mode_config.max_height = 4096;
-
-	dev->mode_config.funcs = &imx_drm_mode_config_funcs;
-}
-- 
1.8.3.1

  parent reply	other threads:[~2014-02-18 20:11 UTC|newest]

Thread overview: 35+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-02-18 20:09 [PATCH 00/34] imx-drm stuff again Russell King - ARM Linux
2014-02-18 20:09 ` [PATCH 01/34] imx-drm: imx-hdmi: convert HDMI clock settings to tabular form Russell King
2014-02-18 20:09 ` [PATCH 02/34] imx-drm: imx-hdmi: clean up setting CSC registers Russell King
2014-02-18 20:09 ` [PATCH 03/34] imx-drm: imx-hdmi: provide register modification function Russell King
2014-02-18 20:09 ` [PATCH 04/34] imx-drm: imx-hdmi: clean up setting of vp_conf Russell King
2014-02-18 20:10 ` [PATCH 05/34] imx-drm: imx-hdmi: fix CTS/N setup at init time Russell King
2014-02-18 20:10 ` [PATCH 06/34] imx-drm: ipu-v3: more inteligent DI clock selection Russell King
2014-02-18 20:10 ` [PATCH 07/34] imx-drm: ipu-v3: don't use clk_round_rate() before clk_set_rate() Russell King
2014-02-18 20:10 ` [PATCH 08/34] imx-drm: ipu-v3: more clocking fixes Russell King
2014-02-18 20:10 ` [PATCH 09/34] imx-drm: add imx6 DT configuration for HDMI Russell King
2014-02-18 20:10 ` [PATCH 10/34] imx-drm: update and fix imx6 DT descriptions for v3 HDMI driver Russell King
2014-02-18 20:10 ` [PATCH 11/34] imx-drm: imx-drm-core: sanitise imx_drm_encoder_get_mux_id() Russell King
2014-02-18 20:10 ` [PATCH 12/34] imx-drm: imx-drm-core: use array instead of list for CRTCs Russell King
2014-02-18 20:10 ` [PATCH 13/34] imx-drm: provide common connector mode validation function Russell King
2014-02-18 20:10 ` [PATCH 14/34] imx-drm: simplify setup of panel format Russell King
2014-02-18 20:10 ` [PATCH 15/34] imx-drm: convert to componentised device support Russell King
2014-02-18 20:10 ` [PATCH 16/34] imx-drm: imx-hdmi: convert to a component device Russell King
2014-02-18 20:11 ` [PATCH 17/34] imx-drm: delay publishing sysfs connector entries Russell King
2014-02-18 20:11 ` [PATCH 18/34] imx-drm: remove separate imx-fbdev Russell King
2014-02-18 20:11 ` Russell King [this message]
2014-02-18 20:11 ` [PATCH 20/34] imx-drm: use supplied drm_device where possible Russell King
2014-02-18 20:11 ` [PATCH 21/34] imx-drm: imx-drm-core: provide helper function to parse possible crtcs Russell King
2014-02-18 20:11 ` [PATCH 22/34] imx-drm: imx-drm-core: provide common connector and encoder cleanup functions Russell King
2014-02-18 20:11 ` [PATCH 23/34] imx-drm: parallel-display,imx-tve,imx-ldb: initialise drm components directly Russell King
2014-02-18 20:11 ` [PATCH 24/34] imx-drm: imx-hdmi: " Russell King
2014-02-18 20:11 ` [PATCH 25/34] imx-drm: imx-drm-core: remove imx_drm_connector and imx_drm_encoder code Russell King
2014-02-18 20:11 ` [PATCH 26/34] imx-drm: imx-drm-core: get rid of drm_mode_group_init_legacy_group() Russell King
2014-02-18 20:11 ` [PATCH 27/34] imx-drm: imx-drm-core: kill off mutex Russell King
2014-02-18 20:12 ` [PATCH 28/34] imx-drm: imx-drm-core: move allocation of imxdrm device to driver load function Russell King
2014-02-18 20:12 ` [PATCH 29/34] imx-drm: imx-drm-core: various cleanups Russell King
2014-02-18 20:12 ` [PATCH 30/34] imx-drm: imx-drm-core: add core hotplug connector support Russell King
2014-02-18 20:12 ` [PATCH 31/34] imx-drm: imx-hdmi: add hotplug support to HDMI component Russell King
2014-02-18 20:12 ` [PATCH 32/34] imx-drm: dw-hdmi-audio: add audio driver Russell King
2014-02-18 20:12 ` [PATCH 33/34] imx-drm: dw-hdmi-audio: parse ELD from HDMI driver Russell King
2014-02-18 20:12 ` [PATCH 34/34] imx-drm: add CEC " Russell King

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=E1WFr0b-0007jb-Rr@rmk-PC.arm.linux.org.uk \
    --to=rmk+kernel@arm.linux.org.uk \
    --cc=linux-arm-kernel@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.