[DPU PATCH 11/15] drm/msm: Remove dpu module parameters

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



We don't use dpucustom, and the suspend blanking should be done by
userspace instead of in kernel.

Signed-off-by: Sean Paul <seanpaul@xxxxxxxxxxxx>
---
 drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c   | 51 -----------------------
 drivers/gpu/drm/msm/disp/dpu1/dpu_kms.h   |  7 ----
 drivers/gpu/drm/msm/disp/dpu1/dpu_plane.c | 12 ------
 3 files changed, 70 deletions(-)

diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c
index ddba0873466b..edb5d40f9160 100644
--- a/drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c
+++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c
@@ -55,27 +55,8 @@ static const char * const iommu_ports[] = {
 #define DPU_DEBUGFS_DIR "msm_dpu"
 #define DPU_DEBUGFS_HWMASKNAME "hw_log_mask"
 
-/**
- * dpucustom - enable certain driver customizations for dpu clients
- *	Enabling this modifies the standard DRM behavior slightly and assumes
- *	that the clients have specific knowledge about the modifications that
- *	are involved, so don't enable this unless you know what you're doing.
- *
- *	Parts of the driver that are affected by this setting may be located by
- *	searching for invocations of the 'dpu_is_custom_client()' function.
- *
- *	This is disabled by default.
- */
-static bool dpucustom;
-module_param(dpucustom, bool, 0400);
-MODULE_PARM_DESC(dpucustom, "Enable customizations for dpu clients");
-
 static int dpu_kms_hw_init(struct msm_kms *kms);
 static int _dpu_kms_mmu_destroy(struct dpu_kms *dpu_kms);
-bool dpu_is_custom_client(void)
-{
-	return dpucustom;
-}
 
 static unsigned long dpu_iomap_size(struct platform_device *pdev,
 				    const char *name)
@@ -606,10 +587,6 @@ static int _dpu_kms_drm_obj_init(struct dpu_kms *dpu_kms)
 	int primary_planes_idx = 0, i, ret;
 	int max_crtc_count;
 
-	u32 sspp_id[MAX_PLANES];
-	u32 master_plane_id[MAX_PLANES];
-	u32 num_virt_planes = 0;
-
 	if (!dpu_kms || !dpu_kms->dev || !dpu_kms->dev->dev) {
 		DPU_ERROR("invalid dpu_kms\n");
 		return -EINVAL;
@@ -646,27 +623,6 @@ static int _dpu_kms_drm_obj_init(struct dpu_kms *dpu_kms)
 
 		if (primary)
 			primary_planes[primary_planes_idx++] = plane;
-
-		if (dpu_hw_sspp_multirect_enabled(&catalog->sspp[i]) &&
-			dpu_is_custom_client()) {
-			int priority =
-				catalog->sspp[i].sblk->smart_dma_priority;
-			sspp_id[priority - 1] = catalog->sspp[i].id;
-			master_plane_id[priority - 1] = plane->base.id;
-			num_virt_planes++;
-		}
-	}
-
-	/* Initialize smart DMA virtual planes */
-	for (i = 0; i < num_virt_planes; i++) {
-		plane = dpu_plane_init(dev, sspp_id[i], false,
-			(1UL << max_crtc_count) - 1, master_plane_id[i]);
-		if (IS_ERR(plane)) {
-			DPU_ERROR("dpu_plane for virtual SSPP init failed\n");
-			ret = PTR_ERR(plane);
-			goto fail;
-		}
-		priv->planes[priv->num_planes++] = plane;
 	}
 
 	max_crtc_count = min(max_crtc_count, primary_planes_idx);
@@ -681,13 +637,6 @@ static int _dpu_kms_drm_obj_init(struct dpu_kms *dpu_kms)
 		priv->crtcs[priv->num_crtcs++] = crtc;
 	}
 
-	if (dpu_is_custom_client()) {
-		/* All CRTCs are compatible with all planes */
-		for (i = 0; i < priv->num_planes; i++)
-			priv->planes[i]->possible_crtcs =
-				(1 << priv->num_crtcs) - 1;
-	}
-
 	/* All CRTCs are compatible with all encoders */
 	for (i = 0; i < priv->num_encoders; i++)
 		priv->encoders[i]->possible_crtcs = (1 << priv->num_crtcs) - 1;
diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_kms.h b/drivers/gpu/drm/msm/disp/dpu1/dpu_kms.h
index 6308bd84e6a9..3437598ceef1 100644
--- a/drivers/gpu/drm/msm/disp/dpu1/dpu_kms.h
+++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_kms.h
@@ -163,13 +163,6 @@ struct vsync_info {
 
 #define to_dpu_kms(x) container_of(x, struct dpu_kms, base)
 
-/**
- * dpu_is_custom_client - whether or not to enable non-standard customizations
- *
- * Return: Whether or not the 'dpuclient' module parameter was set on boot up
- */
-bool dpu_is_custom_client(void);
-
 /**
  * dpu_kms_is_suspend_state - whether or not the system is pm suspended
  * @dev: Pointer to drm device
diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_plane.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_plane.c
index c2088a3bfba7..ae05d4d002a9 100644
--- a/drivers/gpu/drm/msm/disp/dpu1/dpu_plane.c
+++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_plane.c
@@ -31,14 +31,6 @@
 #include "dpu_vbif.h"
 #include "dpu_plane.h"
 
-static bool suspend_blank = true;
-module_param(suspend_blank, bool, 0400);
-MODULE_PARM_DESC(suspend_blank,
-		"If set, active planes will force their outputs to black,\n"
-		"by temporarily enabling the color fill, when recovering\n"
-		"from a system resume instead of attempting to display the\n"
-		"last provided frame buffer.");
-
 #define DPU_DEBUG_PLANE(pl, fmt, ...) DPU_DEBUG("plane%d " fmt,\
 		(pl) ? (pl)->base.base.id : -1, ##__VA_ARGS__)
 
@@ -1245,10 +1237,6 @@ void dpu_plane_flush(struct drm_plane *plane)
 	else if (pdpu->pipe_hw && pdpu->csc_ptr && pdpu->pipe_hw->ops.setup_csc)
 		pdpu->pipe_hw->ops.setup_csc(pdpu->pipe_hw, pdpu->csc_ptr);
 
-	/* force black color fill during suspend */
-	if (dpu_kms_is_suspend_state(plane->dev) && suspend_blank)
-		_dpu_plane_color_fill(pdpu, 0x0, 0x0);
-
 	/* flag h/w flush complete */
 	if (plane->state)
 		pstate->pending = false;
-- 
Sean Paul, Software Engineer, Google / Chromium OS

--
To unsubscribe from this list: send the line "unsubscribe linux-arm-msm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [Linux for Sparc]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux