diff mbox

[PATCHv3,10/30] drm/omap: output: use dev_err instead of DSSERR

Message ID 1490706496-4959-11-git-send-email-tomi.valkeinen@ti.com (mailing list archive)
State New, archived
Headers show

Commit Message

Tomi Valkeinen March 28, 2017, 1:07 p.m. UTC
We don't have omapdss's custom error printing functions in the common
omapdss-base module, to which we want to move output.c.

This patch changes output.c to use dev_err instead of DSSERR so that it
doesn't depend on DSSERR.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
---
 drivers/gpu/drm/omapdrm/dss/output.c | 13 ++++++++-----
 1 file changed, 8 insertions(+), 5 deletions(-)

Comments

Laurent Pinchart March 29, 2017, 8:32 a.m. UTC | #1
Hi Tomi,

Thank you for the patch.

On Tuesday 28 Mar 2017 16:07:56 Tomi Valkeinen wrote:
> We don't have omapdss's custom error printing functions in the common
> omapdss-base module, to which we want to move output.c.
> 
> This patch changes output.c to use dev_err instead of DSSERR so that it
> doesn't depend on DSSERR.
> 
> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>

Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

> ---
>  drivers/gpu/drm/omapdrm/dss/output.c | 13 ++++++++-----
>  1 file changed, 8 insertions(+), 5 deletions(-)
> 
> diff --git a/drivers/gpu/drm/omapdrm/dss/output.c
> b/drivers/gpu/drm/omapdrm/dss/output.c index a901af5a9bc3..0858958677a1
> 100644
> --- a/drivers/gpu/drm/omapdrm/dss/output.c
> +++ b/drivers/gpu/drm/omapdrm/dss/output.c
> @@ -35,14 +35,15 @@ int omapdss_output_set_device(struct omap_dss_device
> *out, mutex_lock(&output_lock);
> 
>  	if (out->dst) {
> -		DSSERR("output already has device %s connected to it\n",
> +		dev_err(out->dev,
> +			"output already has device %s connected to it\n",
>  			out->dst->name);
>  		r = -EINVAL;
>  		goto err;
>  	}
> 
>  	if (out->output_type != dssdev->type) {
> -		DSSERR("output type and display type don't match\n");
> +		dev_err(out->dev, "output type and display type don't 
match\n");
>  		r = -EINVAL;
>  		goto err;
>  	}
> @@ -67,14 +68,16 @@ int omapdss_output_unset_device(struct omap_dss_device
> *out) mutex_lock(&output_lock);
> 
>  	if (!out->dst) {
> -		DSSERR("output doesn't have a device connected to it\n");
> +		dev_err(out->dev,
> +			"output doesn't have a device connected to it\n");
>  		r = -EINVAL;
>  		goto err;
>  	}
> 
>  	if (out->dst->state != OMAP_DSS_DISPLAY_DISABLED) {
> -		DSSERR("device %s is not disabled, cannot unset device\n",
> -				out->dst->name);
> +		dev_err(out->dev,
> +			"device %s is not disabled, cannot unset device\n",
> +			out->dst->name);
>  		r = -EINVAL;
>  		goto err;
>  	}
diff mbox

Patch

diff --git a/drivers/gpu/drm/omapdrm/dss/output.c b/drivers/gpu/drm/omapdrm/dss/output.c
index a901af5a9bc3..0858958677a1 100644
--- a/drivers/gpu/drm/omapdrm/dss/output.c
+++ b/drivers/gpu/drm/omapdrm/dss/output.c
@@ -35,14 +35,15 @@  int omapdss_output_set_device(struct omap_dss_device *out,
 	mutex_lock(&output_lock);
 
 	if (out->dst) {
-		DSSERR("output already has device %s connected to it\n",
+		dev_err(out->dev,
+			"output already has device %s connected to it\n",
 			out->dst->name);
 		r = -EINVAL;
 		goto err;
 	}
 
 	if (out->output_type != dssdev->type) {
-		DSSERR("output type and display type don't match\n");
+		dev_err(out->dev, "output type and display type don't match\n");
 		r = -EINVAL;
 		goto err;
 	}
@@ -67,14 +68,16 @@  int omapdss_output_unset_device(struct omap_dss_device *out)
 	mutex_lock(&output_lock);
 
 	if (!out->dst) {
-		DSSERR("output doesn't have a device connected to it\n");
+		dev_err(out->dev,
+			"output doesn't have a device connected to it\n");
 		r = -EINVAL;
 		goto err;
 	}
 
 	if (out->dst->state != OMAP_DSS_DISPLAY_DISABLED) {
-		DSSERR("device %s is not disabled, cannot unset device\n",
-				out->dst->name);
+		dev_err(out->dev,
+			"device %s is not disabled, cannot unset device\n",
+			out->dst->name);
 		r = -EINVAL;
 		goto err;
 	}