Skip to content

Commit bf52dc4

Browse files
vsyrjalarodrigovivi
authored andcommitted
drm/i915: Don't zero out the Y plane's watermarks
Don't zero out the watermarks for the Y plane since we've already computed them when computing the UV plane's watermarks (since the UV plane always appears before ethe Y plane when iterating through the planes). This leads to allocating no DDB for the Y plane since .min_ddb_alloc also gets zeroed. And that of course leads to underruns when scanning out planar formats. Cc: stable@vger.kernel.org Cc: Stanislav Lisovskiy <stanislav.lisovskiy@intel.com> Fixes: dbf7138 ("drm/i915: Nuke intel_atomic_crtc_state_for_each_plane_state() from skl+ wm code") Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20210327005945.4929-1-ville.syrjala@linux.intel.com Reviewed-by: Stanislav Lisovskiy <stanislav.lisovskiy@intel.com> (cherry picked from commit f99b805) Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
1 parent 1166416 commit bf52dc4

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

drivers/gpu/drm/i915/intel_pm.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5471,12 +5471,12 @@ static int icl_build_plane_wm(struct intel_crtc_state *crtc_state,
54715471
struct skl_plane_wm *wm = &crtc_state->wm.skl.raw.planes[plane_id];
54725472
int ret;
54735473

5474-
memset(wm, 0, sizeof(*wm));
5475-
54765474
/* Watermarks calculated in master */
54775475
if (plane_state->planar_slave)
54785476
return 0;
54795477

5478+
memset(wm, 0, sizeof(*wm));
5479+
54805480
if (plane_state->planar_linked_plane) {
54815481
const struct drm_framebuffer *fb = plane_state->hw.fb;
54825482
enum plane_id y_plane_id = plane_state->planar_linked_plane->id;

0 commit comments

Comments
 (0)