Merge tag 'ieee802154-for-davem-2021-06-03' of git://git.kernel.org/pub/scm/linux...
[linux-2.6-microblaze.git] / drivers / gpu / drm / panel / panel-feixin-k101-im2ba02.c
index 5461065..2a602ae 100644 (file)
@@ -13,7 +13,6 @@
 #include <drm/drm_mipi_dsi.h>
 #include <drm/drm_modes.h>
 #include <drm/drm_panel.h>
-#include <drm/drm_print.h>
 
 #define K101_IM2BA02_INIT_CMD_LEN      2
 
@@ -374,13 +373,11 @@ static int k101_im2ba02_unprepare(struct drm_panel *panel)
 
        ret = mipi_dsi_dcs_set_display_off(ctx->dsi);
        if (ret < 0)
-               DRM_DEV_ERROR(panel->dev, "failed to set display off: %d\n",
-                             ret);
+               dev_err(panel->dev, "failed to set display off: %d\n", ret);
 
        ret = mipi_dsi_dcs_enter_sleep_mode(ctx->dsi);
        if (ret < 0)
-               DRM_DEV_ERROR(panel->dev, "failed to enter sleep mode: %d\n",
-                             ret);
+               dev_err(panel->dev, "failed to enter sleep mode: %d\n", ret);
 
        msleep(200);
 
@@ -416,10 +413,10 @@ static int k101_im2ba02_get_modes(struct drm_panel *panel,
 
        mode = drm_mode_duplicate(connector->dev, &k101_im2ba02_default_mode);
        if (!mode) {
-               DRM_DEV_ERROR(&ctx->dsi->dev, "failed to add mode %ux%ux@%u\n",
-                             k101_im2ba02_default_mode.hdisplay,
-                             k101_im2ba02_default_mode.vdisplay,
-                             drm_mode_vrefresh(&k101_im2ba02_default_mode));
+               dev_err(&ctx->dsi->dev, "failed to add mode %ux%u@%u\n",
+                       k101_im2ba02_default_mode.hdisplay,
+                       k101_im2ba02_default_mode.vdisplay,
+                       drm_mode_vrefresh(&k101_im2ba02_default_mode));
                return -ENOMEM;
        }
 
@@ -460,13 +457,13 @@ static int k101_im2ba02_dsi_probe(struct mipi_dsi_device *dsi)
        ret = devm_regulator_bulk_get(&dsi->dev, ARRAY_SIZE(ctx->supplies),
                                      ctx->supplies);
        if (ret < 0) {
-               DRM_DEV_ERROR(&dsi->dev, "Couldn't get regulators\n");
+               dev_err(&dsi->dev, "Couldn't get regulators\n");
                return ret;
        }
 
        ctx->reset = devm_gpiod_get(&dsi->dev, "reset", GPIOD_OUT_LOW);
        if (IS_ERR(ctx->reset)) {
-               DRM_DEV_ERROR(&dsi->dev, "Couldn't get our reset GPIO\n");
+               dev_err(&dsi->dev, "Couldn't get our reset GPIO\n");
                return PTR_ERR(ctx->reset);
        }
 
@@ -477,9 +474,7 @@ static int k101_im2ba02_dsi_probe(struct mipi_dsi_device *dsi)
        if (ret)
                return ret;
 
-       ret = drm_panel_add(&ctx->panel);
-       if (ret < 0)
-               return ret;
+       drm_panel_add(&ctx->panel);
 
        dsi->mode_flags = MIPI_DSI_MODE_VIDEO;
        dsi->format = MIPI_DSI_FMT_RGB888;