]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
drm/i915: Expose the IN_FORMATS_ASYNC blob for all planes
authorVille Syrjälä <ville.syrjala@linux.intel.com>
Wed, 12 Nov 2025 23:30:29 +0000 (01:30 +0200)
committerVille Syrjälä <ville.syrjala@linux.intel.com>
Thu, 27 Nov 2025 22:37:17 +0000 (00:37 +0200)
Since old kernel versions wouldn't expose the IN_FORMATS_ASYNC blob,
userspace can't really use the absence of the blob to determine
that async flips aren't supported. Thus it seems better to always
expose the blob on all planes, whether they support async flips
or not. The blob will simply not indicate any format+modifier
combinations as supported on planes that aren't async flip capable.

Currently we expose the blob for all skl+ universal planes (even
though we implement async flips only for the first plane on each
pipe), and i9xx primary planes (for ilk+ we have async flips support,
for pre-ilk we do not). Complete the full set by also expsosing
the blob on pre-skl sprite planes, and cursors.

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Link: https://patch.msgid.link/20251112233030.24117-3-ville.syrjala@linux.intel.com
Reviewed-by: Jouni Högander <jouni.hogander@intel.com>
drivers/gpu/drm/i915/display/intel_cursor.c
drivers/gpu/drm/i915/display/intel_sprite.c

index a10b2425b94d20228908ebfccedd49a69f2e450b..63e6a4767aa9371c1f43a3c86697bf5370cd109a 100644 (file)
@@ -974,6 +974,7 @@ static const struct drm_plane_funcs intel_cursor_plane_funcs = {
        .atomic_duplicate_state = intel_plane_duplicate_state,
        .atomic_destroy_state = intel_plane_destroy_state,
        .format_mod_supported = intel_cursor_format_mod_supported,
+       .format_mod_supported_async = intel_plane_format_mod_supported_async,
 };
 
 static void intel_cursor_add_size_hints_property(struct intel_plane *plane)
index 69b6873a6044a6060747f085adb35d93fefd8ed5..9888a2a43fc5f83d57e732ddb53b224e3054d798 100644 (file)
@@ -1567,6 +1567,7 @@ static const struct drm_plane_funcs g4x_sprite_funcs = {
        .atomic_duplicate_state = intel_plane_duplicate_state,
        .atomic_destroy_state = intel_plane_destroy_state,
        .format_mod_supported = g4x_sprite_format_mod_supported,
+       .format_mod_supported_async = intel_plane_format_mod_supported_async,
 };
 
 static const struct drm_plane_funcs snb_sprite_funcs = {
@@ -1576,6 +1577,7 @@ static const struct drm_plane_funcs snb_sprite_funcs = {
        .atomic_duplicate_state = intel_plane_duplicate_state,
        .atomic_destroy_state = intel_plane_destroy_state,
        .format_mod_supported = snb_sprite_format_mod_supported,
+       .format_mod_supported_async = intel_plane_format_mod_supported_async,
 };
 
 static const struct drm_plane_funcs vlv_sprite_funcs = {
@@ -1585,6 +1587,7 @@ static const struct drm_plane_funcs vlv_sprite_funcs = {
        .atomic_duplicate_state = intel_plane_duplicate_state,
        .atomic_destroy_state = intel_plane_destroy_state,
        .format_mod_supported = vlv_sprite_format_mod_supported,
+       .format_mod_supported_async = intel_plane_format_mod_supported_async,
 };
 
 struct intel_plane *