@@ -348,8 +348,10 @@ void ipu_dc_enable(struct ipu_dc *dc)
mutex_lock(&priv->mutex);
- if (!priv->use_count)
+ if (!priv->use_count) {
+ dev_dbg(priv->dev, "DC enable\n");
ipu_module_enable(priv->ipu, IPU_CONF_DC_EN);
+ }
priv->use_count++;
@@ -420,8 +422,10 @@ void ipu_dc_disable(struct ipu_dc *dc)
mutex_lock(&priv->mutex);
priv->use_count--;
- if (!priv->use_count)
+ if (!priv->use_count) {
+ dev_dbg(priv->dev, "DC disable\n");
ipu_module_disable(priv->ipu, IPU_CONF_DC_EN);
+ }
if (priv->use_count < 0)
priv->use_count = 0;
@@ -649,6 +649,7 @@ int ipu_di_enable(struct ipu_di *di)
if (ret)
return ret;
+ dev_dbg(di->ipu->dev, "DI%d enable\n", di->id);
ipu_module_enable(di->ipu, di->module);
return 0;
@@ -659,6 +660,7 @@ int ipu_di_disable(struct ipu_di *di)
{
WARN_ON(IS_ERR(di->clk_di_pixel));
+ dev_dbg(di->ipu->dev, "DI%d disable\n", di->id);
ipu_module_disable(di->ipu, di->module);
clk_disable_unprepare(di->clk_di_pixel);
@@ -127,8 +127,10 @@ int ipu_dmfc_enable_channel(struct dmfc_channel *dmfc)
struct ipu_dmfc_priv *priv = dmfc->priv;
mutex_lock(&priv->mutex);
- if (!priv->use_count)
+ if (!priv->use_count) {
+ dev_dbg(priv->dev, "DMFC enable\n");
ipu_module_enable(priv->ipu, IPU_CONF_DMFC_EN);
+ }
priv->use_count++;
@@ -162,6 +164,7 @@ void ipu_dmfc_disable_channel(struct dmfc_channel *dmfc)
if (!priv->use_count) {
ipu_dmfc_wait_fifos(priv);
+ dev_dbg(priv->dev, "DMFC disable\n");
ipu_module_disable(priv->ipu, IPU_CONF_DMFC_EN);
}
@@ -369,8 +369,10 @@ int ipu_dp_enable(struct ipu_dp *dp)
mutex_lock(&priv->mutex);
- if (!priv->use_count)
+ if (!priv->use_count) {
+ dev_dbg(priv->dev, "DP enable\n");
ipu_module_enable(priv->ipu, IPU_CONF_DP_EN);
+ }
priv->use_count++;
@@ -441,8 +443,10 @@ void ipu_dp_disable(struct ipu_dp *dp)
priv->use_count--;
- if (!priv->use_count)
+ if (!priv->use_count) {
+ dev_dbg(priv->dev, "DP disable\n");
ipu_module_disable(priv->ipu, IPU_CONF_DP_EN);
+ }
if (priv->use_count < 0)
priv->use_count = 0;
Add debug messages when these modules are globally disabled or enabled in the IPU_CONF register. Signed-off-by: Steve Longerbeam <steve_longerbeam@mentor.com> --- drivers/gpu/ipu-v3/ipu-dc.c | 8 ++++++-- drivers/gpu/ipu-v3/ipu-di.c | 2 ++ drivers/gpu/ipu-v3/ipu-dmfc.c | 5 ++++- drivers/gpu/ipu-v3/ipu-dp.c | 8 ++++++-- 4 files changed, 18 insertions(+), 5 deletions(-)