diff options
author | Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 2018-03-05 15:02:22 +0200 |
---|---|---|
committer | Tomi Valkeinen <tomi.valkeinen@ti.com> | 2018-09-03 16:13:27 +0300 |
commit | 2ee767922e1bc7ede9ceb7aed9a14141480836a7 (patch) | |
tree | 46eb1f71530ca4e198d48852095463326ab7c339 /drivers/gpu/drm/omapdrm/omap_drv.h | |
parent | ac3b13189333c224e800b3421ac89536d0109b78 (diff) | |
download | linux-2ee767922e1bc7ede9ceb7aed9a14141480836a7.tar.gz |
drm/omap: Group CRTC, encoder, connector and dssdev in a structure
Create an omap_drm_pipeline structure to model display pipelines, made
of a CRTC, an encoder, a connector and a DSS display device. This allows
grouping related parameters together instead of storing them in
independent arrays and thus improves code readability.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Sebastian Reichel <sebastian.reichel@collabora.co.uk>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Diffstat (limited to 'drivers/gpu/drm/omapdrm/omap_drv.h')
-rw-r--r-- | drivers/gpu/drm/omapdrm/omap_drv.h | 20 |
1 files changed, 9 insertions, 11 deletions
diff --git a/drivers/gpu/drm/omapdrm/omap_drv.h b/drivers/gpu/drm/omapdrm/omap_drv.h index 006c868c528d..bc9b954fcc31 100644 --- a/drivers/gpu/drm/omapdrm/omap_drv.h +++ b/drivers/gpu/drm/omapdrm/omap_drv.h @@ -45,6 +45,13 @@ struct omap_drm_usergart; +struct omap_drm_pipeline { + struct drm_crtc *crtc; + struct drm_encoder *encoder; + struct drm_connector *connector; + struct omap_dss_device *display; +}; + struct omap_drm_private { struct drm_device *ddev; struct device *dev; @@ -54,21 +61,12 @@ struct omap_drm_private { struct dispc_device *dispc; const struct dispc_ops *dispc_ops; - unsigned int num_dssdevs; - struct omap_dss_device *dssdevs[8]; - - unsigned int num_crtcs; - struct drm_crtc *crtcs[8]; + unsigned int num_pipes; + struct omap_drm_pipeline pipes[8]; unsigned int num_planes; struct drm_plane *planes[8]; - unsigned int num_encoders; - struct drm_encoder *encoders[8]; - - unsigned int num_connectors; - struct drm_connector *connectors[8]; - struct drm_fb_helper *fbdev; struct workqueue_struct *wq; |