]> git.baikalelectronics.ru Git - kernel.git/commit
drm/i915: Fix dbuf slice config lookup
authorVille Syrjälä <ville.syrjala@linux.intel.com>
Mon, 7 Feb 2022 13:26:59 +0000 (15:26 +0200)
committerVille Syrjälä <ville.syrjala@linux.intel.com>
Tue, 8 Feb 2022 14:50:58 +0000 (16:50 +0200)
commit27f82c98f4471ef97e97e3d45c33a10020b82c93
treeb517cd85a22d8fb7a47222c8b9bdc6f62e6ca0ce
parent8755b185c000b0b884502bc0d294b46b20495e51
drm/i915: Fix dbuf slice config lookup

Apparently I totally fumbled the loop condition when I
removed the ARRAY_SIZE() stuff from the dbuf slice config
lookup. Comparing the loop index with the active_pipes bitmask
is utter nonsense, what we want to do is check to see if the
mask is zero or not.

Note that the code actually ended up working correctly despite
the fumble, up until commit 9afe3adec9d8 ("drm/i915: Allow
!join_mbus cases for adlp+ dbuf configuration") when things
broke for real.

Cc: stable@vger.kernel.org
Fixes: 1f7df8bda6a1 ("drm/i915: Use a sentinel to terminate the dbuf slice arrays")
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20220207132700.481-1-ville.syrjala@linux.intel.com
Reviewed-by: Jani Nikula <jani.nikula@intel.com>
drivers/gpu/drm/i915/intel_pm.c