drm/msm: stop storing the array of CRTCs in struct msm_drm_private
PATCH v7 1/1 drm/msm: stop storing the array of CRTCs in struct msm_drm_private
The array of CRTC in the struct msm_drm_private duplicates a list of CRTCs in the drm_device. Drop it and use the existing list for CRTC enumeration.
---
This was a part of https://patchwork.freedesktop.org/series/105302/
Changes since v6:
- Dropped applied patches
- Dropped msm_drm_thread::crtc as suggested by Abhinav
--- drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c | 2 +- drivers/gpu/drm/msm/disp/mdp4/mdp4_kms.c | 2 +- drivers/gpu/drm/msm/disp/mdp5/mdp5_kms.c | 2 +- drivers/gpu/drm/msm/msm_drv.c | 42 ++++++++++++------------ drivers/gpu/drm/msm/msm_drv.h | 2 -- 5 files changed, 24 insertions(+), 26 deletions(-)
drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c +1 -1
@@ -773,7 +773,7 @@ static int _dpu_kms_drm_obj_init(struct dpu_kms *dpu_kms) ret =PTR_ERR (crtc);return ret; } - priv->crtcs[priv->num_crtcs++] = crtc; + priv->num_crtcs++; }/* All CRTCs are compatible with all encoders */
drivers/gpu/drm/msm/disp/mdp4/mdp4_kms.c +1 -1
@@ -332,7 +332,7 @@ static int modeset_init(struct mdp4_kms *mdp4_kms) goto fail; } - priv->crtcs[priv->num_crtcs++] = crtc; + priv->num_crtcs++; }/*
drivers/gpu/drm/msm/disp/mdp5/mdp5_kms.c +1 -1
@@ -497,7 +497,7 @@ static int modeset_init(struct mdp5_kms *mdp5_kms)DRM_DEV_ERROR (dev->dev,"failed to construct crtc %d (%d)\n" , i, ret); goto fail; } - priv->crtcs[priv->num_crtcs++] = crtc; + priv->num_crtcs++; }/*
drivers/gpu/drm/msm/msm_drv.c +21 -21
102 lines not on this page · raw message
drivers/gpu/drm/msm/msm_drv.h +0 -2
@@ -97,7 +97,6 @@ struct msm_display_topology {/* Commit/Event thread specific structure */ struct msm_drm_thread {struct drm_device *dev; -unsigned int crtc_id;struct kthread_worker *worker; };
@@ -198,7 +197,6 @@ struct msm_drm_private {struct workqueue_struct *wq;unsigned int num_crtcs; -struct drm_crtc *crtcs[MAX_CRTCS ];struct msm_drm_thread event_thread[MAX_CRTCS ];
Signature · 1 line
2.39.2
Quoted 5 lines · Dmitry Baryshkov
The array of CRTC in the struct
msm_drm_privateduplicates a list of CRTCs in thedrm_device. Drop it and use the existing list for CRTC enumeration.Signed-off-by Dmitry Baryshkov <[email protected]>
Quoted 8 lines
---
This was a part of https://patchwork.freedesktop.org/series/105302/Changes since v6:
- Dropped applied patches
- Droppedmsm_drm_thread::crtcas suggested by Abhinav---
Dmitry Baryshkov
AppliedQuoted 5 lines · Dmitry Baryshkov
The array of CRTC in the struct
msm_drm_privateduplicates a list of CRTCs in thedrm_device. Drop it and use the existing list for CRTC enumeration.
Applied, thanks!
[1/1] drm/msm: stop storing the array of CRTCs in struct msm_drm_private
https://gitlab.freedesktop.org/lumag/msm/-/commit/274f16147462
Best regards,
Signature · 1 line
Dmitry Baryshkov <[email protected]>