diff mbox series

[RFC] drm/komeda: Creates plane alpha and blend mode properties

Message ID 1553841845-20174-1-git-send-email-lowry.li@arm.com (mailing list archive)
State New, archived
Headers show
Series [RFC] drm/komeda: Creates plane alpha and blend mode properties | expand

Commit Message

Lowry Li (Arm Technology China) March 29, 2019, 6:44 a.m. UTC
Creates plane alpha and blend mode properties attached to plane.

Signed-off-by: Lowry Li <lowry.li@arm.com>
---
 drivers/gpu/drm/arm/display/komeda/komeda_plane.c | 11 +++++++++++
 1 file changed, 11 insertions(+)

Comments

Ayan Halder March 29, 2019, 4:25 p.m. UTC | #1
On Fri, Mar 29, 2019 at 06:44:45AM +0000, Lowry Li (Arm Technology China) wrote:
> Creates plane alpha and blend mode properties attached to plane.
> 
> Signed-off-by: Lowry Li <lowry.li@arm.com>
> ---
>  drivers/gpu/drm/arm/display/komeda/komeda_plane.c | 11 +++++++++++
>  1 file changed, 11 insertions(+)
> 
> diff --git a/drivers/gpu/drm/arm/display/komeda/komeda_plane.c b/drivers/gpu/drm/arm/display/komeda/komeda_plane.c
> index af51f0c..0ebec39 100644
> --- a/drivers/gpu/drm/arm/display/komeda/komeda_plane.c
> +++ b/drivers/gpu/drm/arm/display/komeda/komeda_plane.c
> @@ -212,6 +212,17 @@ static int komeda_plane_add(struct komeda_kms_dev *kms,
>  
>  	drm_plane_helper_add(plane, &komeda_plane_helper_funcs);
>  
> +	err = drm_plane_create_alpha_property(plane);
> +	if (err)
> +		goto cleanup;
> +
> +	err = drm_plane_create_blend_mode_property(plane,
> +			BIT(DRM_MODE_BLEND_PIXEL_NONE) |
> +			BIT(DRM_MODE_BLEND_PREMULTI)   |
> +			BIT(DRM_MODE_BLEND_COVERAGE));
> +	if (err)
> +		goto cleanup;
> +
>  	return 0;
>  cleanup:
>  	komeda_plane_destroy(plane);
> -- 

Please rebase and test your patches on drm-misc-next. 
https://drm.pages.freedesktop.org/maintainer-tools/repositories.html

> 1.9.1
diff mbox series

Patch

diff --git a/drivers/gpu/drm/arm/display/komeda/komeda_plane.c b/drivers/gpu/drm/arm/display/komeda/komeda_plane.c
index af51f0c..0ebec39 100644
--- a/drivers/gpu/drm/arm/display/komeda/komeda_plane.c
+++ b/drivers/gpu/drm/arm/display/komeda/komeda_plane.c
@@ -212,6 +212,17 @@  static int komeda_plane_add(struct komeda_kms_dev *kms,
 
 	drm_plane_helper_add(plane, &komeda_plane_helper_funcs);
 
+	err = drm_plane_create_alpha_property(plane);
+	if (err)
+		goto cleanup;
+
+	err = drm_plane_create_blend_mode_property(plane,
+			BIT(DRM_MODE_BLEND_PIXEL_NONE) |
+			BIT(DRM_MODE_BLEND_PREMULTI)   |
+			BIT(DRM_MODE_BLEND_COVERAGE));
+	if (err)
+		goto cleanup;
+
 	return 0;
 cleanup:
 	komeda_plane_destroy(plane);