Re: [PATCH 03/22] drm: Add color correction blobs in CRTC state

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Shashank,

On 9 October 2015 at 20:28, Shashank Sharma <shashank.sharma@xxxxxxxxx> wrote:
> This patch adds new variables in CRTC state, to hold respective color
> correction blobs. These blobs will be required during the atomic commit
> for writing the color correction values in correction registers.
>
> Signed-off-by: Shashank Sharma <shashank.sharma@xxxxxxxxx>
> Signed-off-by: Kausal Malladi <kausalmalladi@xxxxxxxxx>
> ---
>  drivers/gpu/drm/drm_atomic_helper.c | 12 ++++++++++++
>  include/drm/drm_crtc.h              |  7 ++++++-
>  2 files changed, 18 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/drm_atomic_helper.c b/drivers/gpu/drm/drm_atomic_helper.c
> index 87a2a44..d73ca9b9 100644
> --- a/drivers/gpu/drm/drm_atomic_helper.c
> +++ b/drivers/gpu/drm/drm_atomic_helper.c
> @@ -2193,6 +2193,12 @@ void __drm_atomic_helper_crtc_duplicate_state(struct drm_crtc *crtc,
>
>         if (state->mode_blob)
>                 drm_property_reference_blob(state->mode_blob);
> +       if (state->ctm_blob)
> +               drm_property_reference_blob(state->ctm_blob);
> +       if (state->palette_after_ctm_blob)
> +               drm_property_reference_blob(state->palette_after_ctm_blob);
> +       if (state->palette_before_ctm_blob)
> +               drm_property_reference_blob(state->palette_before_ctm_blob);
>         state->mode_changed = false;
>         state->active_changed = false;
>         state->planes_changed = false;
> @@ -2238,6 +2244,12 @@ void __drm_atomic_helper_crtc_destroy_state(struct drm_crtc *crtc,
>  {
>         if (state->mode_blob)
>                 drm_property_unreference_blob(state->mode_blob);
> +       if (state->ctm_blob)
> +               drm_property_unreference_blob(state->ctm_blob);
> +       if (state->palette_after_ctm_blob)
> +               drm_property_unreference_blob(state->palette_after_ctm_blob);
> +       if (state->palette_before_ctm_blob)
> +               drm_property_unreference_blob(state->palette_before_ctm_blob);
>  }
>  EXPORT_SYMBOL(__drm_atomic_helper_crtc_destroy_state);
>
> diff --git a/include/drm/drm_crtc.h b/include/drm/drm_crtc.h
> index 6e0f177..9cd4123 100644
> --- a/include/drm/drm_crtc.h
> +++ b/include/drm/drm_crtc.h
> @@ -302,6 +302,11 @@ struct drm_crtc_state {
>         /* blob property to expose current mode to atomic userspace */
>         struct drm_property_blob *mode_blob;
>
> +       /* blob properties to hold the color properties' blobs */
> +       struct drm_property_blob *palette_before_ctm_blob;
> +       struct drm_property_blob *palette_after_ctm_blob;
> +       struct drm_property_blob *ctm_blob;
> +
>         struct drm_pending_vblank_event *event;
>
>         struct drm_atomic_state *state;
> @@ -1151,7 +1156,7 @@ struct drm_mode_config {
>         struct drm_property *cm_palette_after_ctm_property;
>         struct drm_property *cm_ctm_property;
>
> -       /* Coor management capabilities query */
> +       /* Color management capabilities query */
This should be part of the previous patch.

Regards,
Emil
_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/intel-gfx




[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux