We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent a89f056 commit 31f9f9dCopy full SHA for 31f9f9d
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
@@ -10489,8 +10489,8 @@ dm_get_plane_scale(struct drm_plane_state *plane_state,
10489
int plane_src_w, plane_src_h;
10490
10491
dm_get_oriented_plane_size(plane_state, &plane_src_w, &plane_src_h);
10492
- *out_plane_scale_w = plane_state->crtc_w * 1000 / plane_src_w;
10493
- *out_plane_scale_h = plane_state->crtc_h * 1000 / plane_src_h;
+ *out_plane_scale_w = plane_src_w ? plane_state->crtc_w * 1000 / plane_src_w : 0;
+ *out_plane_scale_h = plane_src_h ? plane_state->crtc_h * 1000 / plane_src_h : 0;
10494
}
10495
10496
static int dm_check_crtc_cursor(struct drm_atomic_state *state,
0 commit comments