drm: omapdrm: Cleanup drm_display_mode print str
authorShayenne Moura <shayenneluzmoura@gmail.com>
Thu, 20 Dec 2018 12:26:10 +0000 (10:26 -0200)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Wed, 9 Jan 2019 21:07:15 +0000 (22:07 +0100)
This patch adjust the print string of drm_display_mode object
to remove drm_mode_object dependency in omapdrm files.

Signed-off-by: Shayenne Moura <shayenneluzmoura@gmail.com>
Reviewed-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Link: https://patchwork.freedesktop.org/patch/msgid/cb6079fa6de6fda8d865a1d2a61d7cf10019ae88.1545308167.git.shayenneluzmoura@gmail.com
drivers/gpu/drm/omapdrm/omap_connector.c
drivers/gpu/drm/omapdrm/omap_crtc.c

index b81302c4bf9e6d49a678ff8e34829b8c0bc7dbc3..874d8f3cbff650aa0cb324ecb30f9571c35496b5 100644 (file)
@@ -305,14 +305,9 @@ static int omap_connector_mode_valid(struct drm_connector *connector,
        drm_mode_destroy(dev, new_mode);
 
 done:
-       DBG("connector: mode %s: "
-                       "%d:\"%s\" %d %d %d %d %d %d %d %d %d %d 0x%x 0x%x",
+       DBG("connector: mode %s: " DRM_MODE_FMT,
                        (ret == MODE_OK) ? "valid" : "invalid",
-                       mode->base.id, mode->name, mode->vrefresh, mode->clock,
-                       mode->hdisplay, mode->hsync_start,
-                       mode->hsync_end, mode->htotal,
-                       mode->vdisplay, mode->vsync_start,
-                       mode->vsync_end, mode->vtotal, mode->type, mode->flags);
+                       DRM_MODE_ARG(mode));
 
        return ret;
 }
index caffc547ef97e385cb913f77fd3ebe55a082d486..40acf4ce7c9f3a59f6e79971d25d11c192aa0a10 100644 (file)
@@ -427,12 +427,8 @@ static void omap_crtc_mode_set_nofb(struct drm_crtc *crtc)
        struct omap_crtc *omap_crtc = to_omap_crtc(crtc);
        struct drm_display_mode *mode = &crtc->state->adjusted_mode;
 
-       DBG("%s: set mode: %d:\"%s\" %d %d %d %d %d %d %d %d %d %d 0x%x 0x%x",
-           omap_crtc->name, mode->base.id, mode->name,
-           mode->vrefresh, mode->clock,
-           mode->hdisplay, mode->hsync_start, mode->hsync_end, mode->htotal,
-           mode->vdisplay, mode->vsync_start, mode->vsync_end, mode->vtotal,
-           mode->type, mode->flags);
+       DBG("%s: set mode: " DRM_MODE_FMT,
+           omap_crtc->name, DRM_MODE_ARG(mode));
 
        drm_display_mode_to_videomode(mode, &omap_crtc->vm);
 }