]> git.itanic.dy.fi Git - linux-stable/commit
drm/i915: Check pipe source size when using skl+ scalers
authorVille Syrjälä <ville.syrjala@linux.intel.com>
Tue, 18 Apr 2023 17:55:14 +0000 (20:55 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 17 May 2023 12:01:58 +0000 (14:01 +0200)
commit9a2ca2d932cf17e2f7e06dce49cfc886d8217e6e
tree0d941f6f9e453da4affee8d784006e3426378419
parent8551c4b7c8ffb42f759547e5c39da5980abf2432
drm/i915: Check pipe source size when using skl+ scalers

commit d944eafed618a8507270b324ad9d5405bb7f0b3e upstream.

The skl+ scalers only sample 12 bits of PIPESRC so we can't
do any plane scaling at all when the pipe source size is >4k.

Make sure the pipe source size is also below the scaler's src
size limits. Might not be 100% accurate, but should at least be
safe. We can refine the limits later if we discover that recent
hw is less restricted.

Cc: stable@vger.kernel.org
Tested-by: Ross Zwisler <zwisler@google.com>
Closes: https://gitlab.freedesktop.org/drm/intel/-/issues/8357
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20230418175528.13117-2-ville.syrjala@linux.intel.com
Reviewed-by: Jani Nikula <jani.nikula@intel.com>
(cherry picked from commit 691248d4135fe3fae64b4ee0676bc96a7fd6950c)
Signed-off-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/gpu/drm/i915/display/skl_scaler.c