diff options
| author | Laurent Pinchart <[email protected]> | 2018-09-21 14:00:29 +0000 |
|---|---|---|
| committer | Tomi Valkeinen <[email protected]> | 2019-03-18 09:42:13 +0000 |
| commit | 41322aa691950431ccef115e85b2d6bba654bd70 (patch) | |
| tree | 93dd103cda65ab7f3bdbec984991cd5371b82871 /drivers/gpu/drm/omapdrm/omap_connector.c | |
| parent | drm/omap: Factor out common mode validation code (diff) | |
| download | kernel-41322aa691950431ccef115e85b2d6bba654bd70.tar.gz kernel-41322aa691950431ccef115e85b2d6bba654bd70.zip | |
drm/omap: Pass drm_display_mode to .check_timings() and .set_timings()
The omap_dss_device .check_timings() and .set_timings() operations
operate on struct videomode, while the DRM API operates on struct
drm_display_mode. This forces conversion from to videomode in the
callers. While that's not a problem per se, it creates a difference with
the drm_bridge API.
Replace the videomode parameter to the .check_timings() and
.set_timings() operations with a drm_display_mode. This pushed the
conversion to videomode down to the DSS devices in some cases. If needed
they will be converted to operate on drm_display_mode natively.
Signed-off-by: Laurent Pinchart <[email protected]>
Reviewed-by: Sebastian Reichel <[email protected]>
Tested-by: Sebastian Reichel <[email protected]>
Signed-off-by: Tomi Valkeinen <[email protected]>
Diffstat (limited to 'drivers/gpu/drm/omapdrm/omap_connector.c')
| -rw-r--r-- | drivers/gpu/drm/omapdrm/omap_connector.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/drivers/gpu/drm/omapdrm/omap_connector.c b/drivers/gpu/drm/omapdrm/omap_connector.c index 6fceb020e86c..9be33d9b8485 100644 --- a/drivers/gpu/drm/omapdrm/omap_connector.c +++ b/drivers/gpu/drm/omapdrm/omap_connector.c @@ -245,22 +245,19 @@ enum drm_mode_status omap_connector_mode_fixup(struct omap_dss_device *dssdev, const struct drm_display_mode *mode, struct drm_display_mode *adjusted_mode) { - struct videomode vm = { 0 }; int ret; - drm_display_mode_to_videomode(mode, &vm); + drm_mode_copy(adjusted_mode, mode); for (; dssdev; dssdev = dssdev->next) { if (!dssdev->ops->check_timings) continue; - ret = dssdev->ops->check_timings(dssdev, &vm); + ret = dssdev->ops->check_timings(dssdev, adjusted_mode); if (ret) return MODE_BAD; } - drm_display_mode_from_videomode(&vm, adjusted_mode); - return MODE_OK; } |
