From patchwork Wed Feb 12 16:18:22 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arun R Murthy X-Patchwork-Id: 13972082 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 50919C021A8 for ; Wed, 12 Feb 2025 16:33:17 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 56BA110E90E; Wed, 12 Feb 2025 16:33:16 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="lZjucf5c"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.21]) by gabe.freedesktop.org (Postfix) with ESMTPS id F174A10E905; Wed, 12 Feb 2025 16:33:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1739377994; x=1770913994; h=from:date:subject:mime-version:content-transfer-encoding: message-id:references:in-reply-to:to:cc; bh=G1zixJ4W68V71cI4Evx7GFQRsL9ZlyLYWbvCYCeWstQ=; b=lZjucf5c7XyJ63tUZaUcCwyhL+qBnSpurEwE4JVWRAgtvddKgNzUWIV2 9H0OhjPATOQYd97G48gSWHU2Fort5dTAHeraQWKng7lBM5hADQL4zv3Xs ZdktRlnNpO1i8+lcvEH4iljqnNkUdwEd4bOa1Dcyq5q9T8km7sK26YQYo 9e0FfvRaA5xZD1BMa/Q6dcTmA3TzzI/ylCV2Vr03cfr80pwPfBU6+b3VG N78Vb2rZxiKRXqqTtQ8AXbJHNicvA13GkKvJw1y1C4lT69+qEK15n3cXb VIfI0keMtURKn64NoO0ibd9XVGWELJ0hgSq4UXT820/vllYUeerZYjypb w==; X-CSE-ConnectionGUID: zldTMkbWTCmnBs4QIJdknA== X-CSE-MsgGUID: J20pM8X8Qja5Dyd/u/iB+A== X-IronPort-AV: E=McAfee;i="6700,10204,11343"; a="39969126" X-IronPort-AV: E=Sophos;i="6.13,280,1732608000"; d="scan'208";a="39969126" Received: from fmviesa003.fm.intel.com ([10.60.135.143]) by orvoesa113.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 12 Feb 2025 08:33:14 -0800 X-CSE-ConnectionGUID: DXPRHQNPQJm8SBZ2qznY9g== X-CSE-MsgGUID: Ml7jb3YaQiOEEHvfMI5umQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.12,224,1728975600"; d="scan'208";a="116989300" Received: from srr4-3-linux-106-armuthy.iind.intel.com ([10.190.238.56]) by fmviesa003.fm.intel.com with ESMTP; 12 Feb 2025 08:33:11 -0800 From: Arun R Murthy Date: Wed, 12 Feb 2025 21:48:22 +0530 Subject: [PATCH v5 1/3] drm/plane: Add new plane property IN_FORMATS_ASYNC MIME-Version: 1.0 Message-Id: <20250212-asyn-v5-1-dc182281dca3@intel.com> References: <20250212-asyn-v5-0-dc182281dca3@intel.com> In-Reply-To: <20250212-asyn-v5-0-dc182281dca3@intel.com> To: dri-devel@lists.freedesktop.org, intel-gfx@lists.freedesktop.org, intel-xe@lists.freedesktop.org Cc: chaitanya.kumar.borah@intel.com, ville.syrjala@intel.com, Arun R Murthy X-Mailer: b4 0.15-dev X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" There exists a property IN_FORMATS which exposes the plane supported modifiers/formats to the user. In some platforms when asynchronous flip are used all of modifiers/formats mentioned in IN_FORMATS are not supported. This patch adds a new plane property IN_FORMATS_ASYNC to expose the async flip supported modifiers/formats so that user can use this information ahead and do flip with unsupported formats/modifiers. This will save flip failures. Add a new function pointer similar to format_mod_supported specifically for asynchronous flip. v2: Remove async variable from drm_plane (Ville) v3: Add new function pointer for async (Ville) v5: Typo corrected in commit message & some correction in the kernel documentation. (Chaitanya) Signed-off-by: Arun R Murthy Reviewed-by: Chaitanya Kumar Borah --- drivers/gpu/drm/drm_mode_config.c | 7 +++++++ drivers/gpu/drm/drm_plane.c | 5 +++++ include/drm/drm_mode_config.h | 6 ++++++ include/drm/drm_plane.h | 17 +++++++++++++++++ 4 files changed, 35 insertions(+) diff --git a/drivers/gpu/drm/drm_mode_config.c b/drivers/gpu/drm/drm_mode_config.c index 8642a2fb25a90116dab975aa0ab6b51deafb4b96..dbbef20753f834a85ae9ded748cff2b3f0e85043 100644 --- a/drivers/gpu/drm/drm_mode_config.c +++ b/drivers/gpu/drm/drm_mode_config.c @@ -388,6 +388,13 @@ static int drm_mode_create_standard_properties(struct drm_device *dev) return -ENOMEM; dev->mode_config.size_hints_property = prop; + prop = drm_property_create(dev, + DRM_MODE_PROP_IMMUTABLE | DRM_MODE_PROP_BLOB, + "IN_FORMATS_ASYNC", 0); + if (!prop) + return -ENOMEM; + dev->mode_config.async_modifiers_property = prop; + return 0; } diff --git a/drivers/gpu/drm/drm_plane.c b/drivers/gpu/drm/drm_plane.c index a28b22fdd7a41aca82d097d42237851da9a0a79b..c9d8871417722186d2b6f87197c9e15a70924b4f 100644 --- a/drivers/gpu/drm/drm_plane.c +++ b/drivers/gpu/drm/drm_plane.c @@ -141,6 +141,11 @@ * various bugs in this area with inconsistencies between the capability * flag and per-plane properties. * + * IN_FORMATS_ASYNC: + * Blob property which contains the set of buffer format and modifier + * pairs supported by this plane for asynchronous flips. The blob is a struct + * drm_format_modifier_blob. Userspace cannot change this property. + * * SIZE_HINTS: * Blob property which contains the set of recommended plane size * which can used for simple "cursor like" use cases (eg. no scaling). diff --git a/include/drm/drm_mode_config.h b/include/drm/drm_mode_config.h index 271765e2e9f2da62aaf0d258828ef4196e14822e..0c116d6dfd277262b1a4c0f097fce2d719f43844 100644 --- a/include/drm/drm_mode_config.h +++ b/include/drm/drm_mode_config.h @@ -936,6 +936,12 @@ struct drm_mode_config { */ struct drm_property *modifiers_property; + /** + * @async_modifiers_property: Plane property to list support modifier/format + * combination for asynchronous flips. + */ + struct drm_property *async_modifiers_property; + /** * @size_hints_property: Plane SIZE_HINTS property. */ diff --git a/include/drm/drm_plane.h b/include/drm/drm_plane.h index dd718c62ac31bf16606f3ee9f025a5b171cd1e67..4393a0e9edf91ccfd78ef62b168b9313187c1a81 100644 --- a/include/drm/drm_plane.h +++ b/include/drm/drm_plane.h @@ -549,6 +549,23 @@ struct drm_plane_funcs { */ bool (*format_mod_supported)(struct drm_plane *plane, uint32_t format, uint64_t modifier); + /** + * @format_mod_supported_async: + * + * This optional hook is used for the DRM to determine if for + * asynchronous flip the given format/modifier combination is valid for + * the plane. This allows the DRM to generate the correct format + * bitmask (which formats apply to which modifier), and to validate + * modifiers at atomic_check time. + * + * Returns: + * + * True if the given modifier is valid for that format on the plane. + * False otherwise. + */ + bool (*format_mod_supported_async)(struct drm_plane *plane, + uint32_t format, uint64_t modifier); + }; /** From patchwork Wed Feb 12 16:18:23 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arun R Murthy X-Patchwork-Id: 13972083 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id A735DC021A4 for ; Wed, 12 Feb 2025 16:33:18 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id A8F1F10E910; Wed, 12 Feb 2025 16:33:17 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="ARUNm6G3"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.21]) by gabe.freedesktop.org (Postfix) with ESMTPS id 3DEBD10E905; Wed, 12 Feb 2025 16:33:16 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1739377996; x=1770913996; h=from:date:subject:mime-version:content-transfer-encoding: message-id:references:in-reply-to:to:cc; bh=is6jENgogeyedVHuv/WlNYpfefBbYVRD9mREtoWHC3o=; b=ARUNm6G3NwEvvENPwsBF5DoSVrgWx/w5diTMMf9FcEnWj+tz9X5WV6UT 4MdsNmlqlgX9MlLV87c6GSR33c8oWcExBWycTr6852cciLAm1t4G9ofB6 grXTcZRoA22JtZDq0hcK+5vqBeU+GTQ3bDhU04SRnrSDvyQoR+7YvlUNA iVXwtwEVJvLLmA87dzOzR5t/o6M9wtXDgAc+eW19kvaFyzS0Pa2ZAGc6J VTHovJidTW0U8uwBmrgB/cHpjLQPXQcT9e5Qg+z9x+iDCveHkhzFWjn7C bdAg8GIOF/MjmotUUtxdVypn0/cljld6q/owxLUljQT/92zOh6kdVFfsa g==; X-CSE-ConnectionGUID: 8O6RUI/eT/KwY1QbJlMghA== X-CSE-MsgGUID: oqJECVLTT7ytwvy/5M60Cg== X-IronPort-AV: E=McAfee;i="6700,10204,11343"; a="39969129" X-IronPort-AV: E=Sophos;i="6.13,280,1732608000"; d="scan'208";a="39969129" Received: from fmviesa003.fm.intel.com ([10.60.135.143]) by orvoesa113.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 12 Feb 2025 08:33:16 -0800 X-CSE-ConnectionGUID: au7BUwWvSIWyrBTSpC8Mbg== X-CSE-MsgGUID: aI648bw3R+CD3OsOorSqPw== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.12,224,1728975600"; d="scan'208";a="116989305" Received: from srr4-3-linux-106-armuthy.iind.intel.com ([10.190.238.56]) by fmviesa003.fm.intel.com with ESMTP; 12 Feb 2025 08:33:14 -0800 From: Arun R Murthy Date: Wed, 12 Feb 2025 21:48:23 +0530 Subject: [PATCH v5 2/3] drm/plane: modify create_in_formats to accommodate async MIME-Version: 1.0 Message-Id: <20250212-asyn-v5-2-dc182281dca3@intel.com> References: <20250212-asyn-v5-0-dc182281dca3@intel.com> In-Reply-To: <20250212-asyn-v5-0-dc182281dca3@intel.com> To: dri-devel@lists.freedesktop.org, intel-gfx@lists.freedesktop.org, intel-xe@lists.freedesktop.org Cc: chaitanya.kumar.borah@intel.com, ville.syrjala@intel.com, Arun R Murthy X-Mailer: b4 0.15-dev X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" create_in_formats creates the list of supported format/modifiers for synchronous flips, modify the same function so as to take the format_mod_supported as argument and create list of format/modifier for async as well. v5: create_in_formats can return -ve value in failure case, correct the if condition to check the creation of blob Dont add the modifier for which none of the formats is not supported. Signed-off-by: Arun R Murthy --- drivers/gpu/drm/drm_plane.c | 46 +++++++++++++++++++++++++++++++++------------ 1 file changed, 34 insertions(+), 12 deletions(-) diff --git a/drivers/gpu/drm/drm_plane.c b/drivers/gpu/drm/drm_plane.c index c9d8871417722186d2b6f87197c9e15a70924b4f..01f67f1f5f29e37b8d0e0793c58bbe1bba337eb2 100644 --- a/drivers/gpu/drm/drm_plane.c +++ b/drivers/gpu/drm/drm_plane.c @@ -190,9 +190,12 @@ modifiers_ptr(struct drm_format_modifier_blob *blob) return (struct drm_format_modifier *)(((char *)blob) + blob->modifiers_offset); } -static int create_in_format_blob(struct drm_device *dev, struct drm_plane *plane) +static int create_in_format_blob(struct drm_device *dev, struct drm_plane *plane, + bool (*format_mod_supported) + (struct drm_plane *plane, + uint32_t format, + uint64_t modifier)) { - const struct drm_mode_config *config = &dev->mode_config; struct drm_property_blob *blob; struct drm_format_modifier *mod; size_t blob_size, formats_size, modifiers_size; @@ -234,24 +237,26 @@ static int create_in_format_blob(struct drm_device *dev, struct drm_plane *plane mod = modifiers_ptr(blob_data); for (i = 0; i < plane->modifier_count; i++) { for (j = 0; j < plane->format_count; j++) { - if (!plane->funcs->format_mod_supported || - plane->funcs->format_mod_supported(plane, - plane->format_types[j], - plane->modifiers[i])) { + if (!format_mod_supported || format_mod_supported + (plane, + plane->format_types[j], + plane->modifiers[i])) { mod->formats |= 1ULL << j; } } + if (!mod->formats) { + mod->modifier = 0; + blob_data->count_modifiers--; + continue; + } mod->modifier = plane->modifiers[i]; mod->offset = 0; mod->pad = 0; mod++; } - drm_object_attach_property(&plane->base, config->modifiers_property, - blob->base.id); - - return 0; + return blob->base.id; } /** @@ -368,6 +373,7 @@ static int __drm_universal_plane_init(struct drm_device *dev, }; unsigned int format_modifier_count = 0; int ret; + int blob_id; /* plane index is used with 32bit bitmasks */ if (WARN_ON(config->num_total_plane >= 32)) @@ -474,8 +480,24 @@ static int __drm_universal_plane_init(struct drm_device *dev, drm_plane_create_hotspot_properties(plane); } - if (format_modifier_count) - create_in_format_blob(dev, plane); + if (format_modifier_count) { + blob_id = create_in_format_blob(dev, plane, + plane->funcs->format_mod_supported); + if (blob_id > 0) + drm_object_attach_property(&plane->base, + config->modifiers_property, + blob_id); + } + + if (plane->funcs->format_mod_supported_async) { + blob_id = create_in_format_blob(dev, plane, + plane->funcs->format_mod_supported_async); + if (blob_id > 0) + drm_object_attach_property(&plane->base, + config->async_modifiers_property, + blob_id); + } + return 0; } From patchwork Wed Feb 12 16:18:24 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arun R Murthy X-Patchwork-Id: 13972084 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id E2ACCC021A6 for ; Wed, 12 Feb 2025 16:33:20 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 4BB2610E916; Wed, 12 Feb 2025 16:33:20 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="a3ZeadJY"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.21]) by gabe.freedesktop.org (Postfix) with ESMTPS id 8045710E911; Wed, 12 Feb 2025 16:33:18 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1739377998; x=1770913998; h=from:date:subject:mime-version:content-transfer-encoding: message-id:references:in-reply-to:to:cc; bh=bPb4HGtPc1jw3HZ2PILjHq8rNQ6CKsUqMy94wB2IVAE=; b=a3ZeadJYMUMVlBJ40WLLhgrcIyM2+DkAZXxYGm31XTvPuMGzHvZfGSni CLcgmUSoi6sYCDkHke5Q5fghTJIVlmWVFa8fI0oSkhmyLAYs3slitl1Xq 6RhHfo4EFXxGQZL+efxo19NZXXLqG6Pw7IC8HbG6dA8wYTcHiGqNHcA04 Cq74ftWam5Dv3qtk9iAxxOmqGI4LsOuTgFjj82gg6j7IQfMi7gk716mju tPQVizxIX5Tu/Ey7kZETMymgPfewS0gihrmTGXixObU139OaamSWpRQ5Q pYS9KzTqDrBry1oH0mZmphXj6XgWZvkwrwTMifQpNnxv2+x8zBJMhNVM5 g==; X-CSE-ConnectionGUID: czN1DSufQdGibDpforgghA== X-CSE-MsgGUID: XK9jlCjQTRuVlG6lv8MLgA== X-IronPort-AV: E=McAfee;i="6700,10204,11343"; a="39969133" X-IronPort-AV: E=Sophos;i="6.13,280,1732608000"; d="scan'208";a="39969133" Received: from fmviesa003.fm.intel.com ([10.60.135.143]) by orvoesa113.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 12 Feb 2025 08:33:18 -0800 X-CSE-ConnectionGUID: 4H8SIfHcR8qpEHO4OETAsQ== X-CSE-MsgGUID: QzFEoXf5QFSIc8uGMqRkeg== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.12,224,1728975600"; d="scan'208";a="116989312" Received: from srr4-3-linux-106-armuthy.iind.intel.com ([10.190.238.56]) by fmviesa003.fm.intel.com with ESMTP; 12 Feb 2025 08:33:16 -0800 From: Arun R Murthy Date: Wed, 12 Feb 2025 21:48:24 +0530 Subject: [PATCH v5 3/3] drm/i915/display: Add i915 hook for format_mod_supported_async MIME-Version: 1.0 Message-Id: <20250212-asyn-v5-3-dc182281dca3@intel.com> References: <20250212-asyn-v5-0-dc182281dca3@intel.com> In-Reply-To: <20250212-asyn-v5-0-dc182281dca3@intel.com> To: dri-devel@lists.freedesktop.org, intel-gfx@lists.freedesktop.org, intel-xe@lists.freedesktop.org Cc: chaitanya.kumar.borah@intel.com, ville.syrjala@intel.com, Arun R Murthy X-Mailer: b4 0.15-dev X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Hook up the newly added plane function pointer format_mod_supported_async to populate the modifiers/formats supported by asynchronous flips. v5: Correct the if condition for modifier support check (Chaitanya) Signed-off-by: Arun R Murthy Reviewed-by: Chaitanya Kumar Borah --- drivers/gpu/drm/i915/display/skl_universal_plane.c | 56 ++++++++++++++++------ 1 file changed, 41 insertions(+), 15 deletions(-) diff --git a/drivers/gpu/drm/i915/display/skl_universal_plane.c b/drivers/gpu/drm/i915/display/skl_universal_plane.c index ba5db553c374259f8f3246c1408b55d32c8794e5..2743b031d1092ccc74b4144bd06dba8790f722e7 100644 --- a/drivers/gpu/drm/i915/display/skl_universal_plane.c +++ b/drivers/gpu/drm/i915/display/skl_universal_plane.c @@ -511,6 +511,33 @@ skl_plane_max_stride(struct intel_plane *plane, modifier, rotation, max_pixels, max_bytes); } +static bool intel_plane_async_formats(struct intel_plane *plane, uint32_t format) +{ + switch (format) { + case DRM_FORMAT_RGB565: + case DRM_FORMAT_XRGB8888: + case DRM_FORMAT_XBGR8888: + case DRM_FORMAT_ARGB8888: + case DRM_FORMAT_ABGR8888: + case DRM_FORMAT_XRGB2101010: + case DRM_FORMAT_XBGR2101010: + case DRM_FORMAT_XRGB16161616F: + case DRM_FORMAT_XBGR16161616F: + return true; + default: + return false; + } +} + +static bool intel_plane_format_mod_supported_async(struct drm_plane *plane, + uint32_t format, + uint64_t modifier) +{ + if (!intel_plane_can_async_flip(to_intel_plane(plane), modifier)) + return false; + + return intel_plane_async_formats(to_intel_plane(plane), format); +} static bool tgl_plane_can_async_flip(u64 modifier) { @@ -2559,30 +2586,29 @@ static bool tgl_plane_format_mod_supported(struct drm_plane *_plane, } } +#define INTEL_PLANE_FUNCS \ + .update_plane = drm_atomic_helper_update_plane, \ + .disable_plane = drm_atomic_helper_disable_plane, \ + .destroy = intel_plane_destroy, \ + .atomic_duplicate_state = intel_plane_duplicate_state, \ + .atomic_destroy_state = intel_plane_destroy_state, \ + .format_mod_supported_async = intel_plane_format_mod_supported_async + static const struct drm_plane_funcs skl_plane_funcs = { - .update_plane = drm_atomic_helper_update_plane, - .disable_plane = drm_atomic_helper_disable_plane, - .destroy = intel_plane_destroy, - .atomic_duplicate_state = intel_plane_duplicate_state, - .atomic_destroy_state = intel_plane_destroy_state, + INTEL_PLANE_FUNCS, + .format_mod_supported = skl_plane_format_mod_supported, }; static const struct drm_plane_funcs icl_plane_funcs = { - .update_plane = drm_atomic_helper_update_plane, - .disable_plane = drm_atomic_helper_disable_plane, - .destroy = intel_plane_destroy, - .atomic_duplicate_state = intel_plane_duplicate_state, - .atomic_destroy_state = intel_plane_destroy_state, + INTEL_PLANE_FUNCS, + .format_mod_supported = icl_plane_format_mod_supported, }; static const struct drm_plane_funcs tgl_plane_funcs = { - .update_plane = drm_atomic_helper_update_plane, - .disable_plane = drm_atomic_helper_disable_plane, - .destroy = intel_plane_destroy, - .atomic_duplicate_state = intel_plane_duplicate_state, - .atomic_destroy_state = intel_plane_destroy_state, + INTEL_PLANE_FUNCS, + .format_mod_supported = tgl_plane_format_mod_supported, };