diff options
author | Ville Syrjälä <[email protected]> | 2022-11-07 21:25:40 +0200 |
---|---|---|
committer | Ville Syrjälä <[email protected]> | 2022-11-12 01:36:43 +0200 |
commit | a01befa0a281b504587166d0d02d178791ae60b4 (patch) | |
tree | 82edbd45e16d8095e7ffe04fba51605069a08685 | |
parent | 265751a513adfec50bcb7354fc287a9bd3a62129 (diff) |
drm/hisilicon: Use drm_mode_init() for on-stack modes
Initialize on-stack modes with drm_mode_init() to guarantee
no stack garbage in the list head.
Cc: Xinliang Liu <[email protected]>
Cc: Tian Tao <[email protected]>
Cc: John Stultz <[email protected]>
Cc: Xinwei Kong <[email protected]>
Cc: Chen Feng <[email protected]>
Signed-off-by: Ville Syrjälä <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
Reviewed-by: Daniel Vetter <[email protected]>
-rw-r--r-- | drivers/gpu/drm/hisilicon/kirin/dw_drm_dsi.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/hisilicon/kirin/dw_drm_dsi.c b/drivers/gpu/drm/hisilicon/kirin/dw_drm_dsi.c index a0d5aa727d58..d9978b79828c 100644 --- a/drivers/gpu/drm/hisilicon/kirin/dw_drm_dsi.c +++ b/drivers/gpu/drm/hisilicon/kirin/dw_drm_dsi.c @@ -658,7 +658,7 @@ static enum drm_mode_status dsi_encoder_mode_valid(struct drm_encoder *encoder, * reset adj_mode to the mode value each time, * so we don't adjust the mode twice */ - drm_mode_copy(&adj_mode, mode); + drm_mode_init(&adj_mode, mode); crtc_funcs = crtc->helper_private; if (crtc_funcs && crtc_funcs->mode_fixup) |