@@ -182,41 +182,6 @@ int exynos_drm_crtc_init(struct exynos_drm_crtc *exynos_crtc,
&exynos_crtc_funcs, NULL);
}
-struct exynos_drm_crtc *exynos_drm_crtc_create(struct drm_device *drm_dev,
- struct drm_plane *plane,
- enum exynos_drm_output_type type,
- const struct exynos_drm_crtc_ops *ops,
- void *ctx)
-{
- struct exynos_drm_crtc *exynos_crtc;
- struct drm_crtc *crtc;
- int ret;
-
- exynos_crtc = kzalloc(sizeof(*exynos_crtc), GFP_KERNEL);
- if (!exynos_crtc)
- return ERR_PTR(-ENOMEM);
-
- exynos_crtc->type = type;
- exynos_crtc->ops = ops;
- exynos_crtc->ctx = ctx;
-
- crtc = &exynos_crtc->base;
-
- ret = drm_crtc_init_with_planes(drm_dev, crtc, plane, NULL,
- &exynos_crtc_funcs, NULL);
- if (ret < 0)
- goto err_crtc;
-
- drm_crtc_helper_add(crtc, &exynos_crtc_helper_funcs);
-
- return exynos_crtc;
-
-err_crtc:
- plane->funcs->destroy(plane);
- kfree(exynos_crtc);
- return ERR_PTR(ret);
-}
-
struct exynos_drm_crtc *exynos_drm_crtc_get_by_type(struct drm_device *drm_dev,
enum exynos_drm_output_type out_type)
{
@@ -20,11 +20,6 @@
int exynos_drm_crtc_init(struct exynos_drm_crtc *exynos_crtc,
struct drm_device *drm_dev);
-struct exynos_drm_crtc *exynos_drm_crtc_create(struct drm_device *drm_dev,
- struct drm_plane *plane,
- enum exynos_drm_output_type out_type,
- const struct exynos_drm_crtc_ops *ops,
- void *context);
void exynos_drm_crtc_wait_pending_update(struct exynos_drm_crtc *exynos_crtc);
void exynos_drm_crtc_finish_update(struct exynos_drm_crtc *exynos_crtc,
struct exynos_drm_plane *exynos_plane);
@@ -147,14 +147,12 @@ struct exynos_drm_clk {
* @base: crtc object.
* @type: one of EXYNOS_DISPLAY_TYPE_LCD and HDMI.
* @ops: pointer to callbacks for exynos drm specific functionality
- * @ctx: A pointer to the crtc's implementation specific context
* @pipe_clk: A pointer to the crtc's pipeline clock.
*/
struct exynos_drm_crtc {
struct drm_crtc base;
enum exynos_drm_output_type type;
const struct exynos_drm_crtc_ops *ops;
- void *ctx;
struct exynos_drm_clk *pipe_clk;
bool i80_mode : 1;
};
Since exynos_drm_crtc is always embedded exynos_drm_crtc_create helper and ctx field can be removed. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> --- drivers/gpu/drm/exynos/exynos_drm_crtc.c | 35 ------------------------ drivers/gpu/drm/exynos/exynos_drm_crtc.h | 5 ---- drivers/gpu/drm/exynos/exynos_drm_drv.h | 2 -- 3 files changed, 42 deletions(-)