From c90c7feeca2f5839ad6824f816c0bd207602a2f4 Mon Sep 17 00:00:00 2001 From: Vara Reddy Date: Fri, 10 Nov 2017 17:02:02 -0800 Subject: [PATCH] drm/msm/sde: continue with hw init if splash memory is not found For continuous splash screen disabled use cases, it is possible that no reserved memory region for the splash screen buffer is specified. In such cases, set software sate to continuous splash disabled and continue with the driver hardware initialization sequence. Change-Id: I274335340111f4c77da9a06fd6b42c4e71cdea67 Signed-off-by: Aravind Venkateswaran --- drivers/gpu/drm/msm/sde/sde_kms.c | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/msm/sde/sde_kms.c b/drivers/gpu/drm/msm/sde/sde_kms.c index 1f2b3d3ba0c4..bb85e71881a2 100644 --- a/drivers/gpu/drm/msm/sde/sde_kms.c +++ b/drivers/gpu/drm/msm/sde/sde_kms.c @@ -2680,6 +2680,7 @@ static int sde_kms_hw_init(struct msm_kms *kms) struct sde_kms *sde_kms; struct drm_device *dev; struct msm_drm_private *priv; + bool splash_mem_found = false; int i, rc = -EINVAL; if (!kms) { @@ -2774,8 +2775,10 @@ static int sde_kms_hw_init(struct msm_kms *kms) rc = _sde_kms_get_splash_data(&sde_kms->splash_data); if (rc) { - SDE_ERROR("sde splash data fetch failed: %d\n", rc); - goto error; + SDE_DEBUG("sde splash data fetch failed: %d\n", rc); + splash_mem_found = false; + } else { + splash_mem_found = true; } rc = sde_power_resource_enable(&priv->phandle, sde_kms->core_client, @@ -2801,7 +2804,12 @@ static int sde_kms_hw_init(struct msm_kms *kms) sde_dbg_init_dbg_buses(sde_kms->core_rev); - _sde_kms_cont_splash_res_init(sde_kms); + /* + * Attempt continuous splash handoff only if reserved + * splash memory is found. + */ + if (splash_mem_found) + _sde_kms_cont_splash_res_init(sde_kms); /* Initialize reg dma block which is a singleton */ rc = sde_reg_dma_init(sde_kms->reg_dma, sde_kms->catalog,