diff mbox series

[PATCHv4,01/36] drm/framebuffer: Add optional modifier info

Message ID 20191213155907.16581-2-andrzej.p@collabora.com (mailing list archive)
State New, archived
Headers show
Series AFBC support for Rockchip | expand

Commit Message

Andrzej Pietrasiewicz Dec. 13, 2019, 3:58 p.m. UTC
modifier_info is a pointer to an optional modifier-related information.
Managing the memory needed for that information is the responsibility
of drivers.

Signed-off-by: Andrzej Pietrasiewicz <andrzej.p@collabora.com>
---
 include/drm/drm_framebuffer.h | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

Comments

James Qian Wang Feb. 17, 2020, 5:50 a.m. UTC | #1
Hi Andrzej:

Sorry for late due to the outbreak of coronavirus in china.

Reviewed-by: James Qian Wang <james.qian.wang@arm.com>

James.

On Fri, Dec 13, 2019 at 04:58:32PM +0100, Andrzej Pietrasiewicz wrote:
> modifier_info is a pointer to an optional modifier-related information.
> Managing the memory needed for that information is the responsibility
> of drivers.
> 
> Signed-off-by: Andrzej Pietrasiewicz <andrzej.p@collabora.com>
> ---
>  include/drm/drm_framebuffer.h | 16 ++++++++++++++++
>  1 file changed, 16 insertions(+)
> 
> diff --git a/include/drm/drm_framebuffer.h b/include/drm/drm_framebuffer.h
> index c0e0256e3e98..2b3341b526d7 100644
> --- a/include/drm/drm_framebuffer.h
> +++ b/include/drm/drm_framebuffer.h
> @@ -29,6 +29,7 @@
>  
>  #include <drm/drm_mode_object.h>
>  
> +struct drm_afbc;
>  struct drm_clip_rect;
>  struct drm_device;
>  struct drm_file;
> @@ -139,6 +140,21 @@ struct drm_framebuffer {
>  	 * @format: framebuffer format information
>  	 */
>  	const struct drm_format_info *format;
> +
> +	union {
> +		/**
> +		 * @modifier_info: pointer to an optional modifier-related
> +		 * information. Managing the memory holding that information
> +		 * is driver's responsibility.
> +		 */
> +		void *modifier_info;
> +
> +		/**
> +		 * @afbc_info: afbc-specific pointer
> +		 */
> +		struct drm_afbc *afbc_info;
> +	};
> +
>  	/**
>  	 * @funcs: framebuffer vfunc table
>  	 */
diff mbox series

Patch

diff --git a/include/drm/drm_framebuffer.h b/include/drm/drm_framebuffer.h
index c0e0256e3e98..2b3341b526d7 100644
--- a/include/drm/drm_framebuffer.h
+++ b/include/drm/drm_framebuffer.h
@@ -29,6 +29,7 @@ 
 
 #include <drm/drm_mode_object.h>
 
+struct drm_afbc;
 struct drm_clip_rect;
 struct drm_device;
 struct drm_file;
@@ -139,6 +140,21 @@  struct drm_framebuffer {
 	 * @format: framebuffer format information
 	 */
 	const struct drm_format_info *format;
+
+	union {
+		/**
+		 * @modifier_info: pointer to an optional modifier-related
+		 * information. Managing the memory holding that information
+		 * is driver's responsibility.
+		 */
+		void *modifier_info;
+
+		/**
+		 * @afbc_info: afbc-specific pointer
+		 */
+		struct drm_afbc *afbc_info;
+	};
+
 	/**
 	 * @funcs: framebuffer vfunc table
 	 */