Re: [PATCH 22/27] drm/i915/pxp: Expose session state for display protection flip

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

 



Hi Anshuman,

Quoted "Currently this api used by Patch 27 of this series, uses gem object user flag (obj->user_flags) to pass as gem_object_metadata but it is unused ? why do  we need this gem_object_metadata ?"

Yes, you are correct, the argument gem_object_metadata of intel_pxp_gem_object_status() isn't required anymore.

This is because the original design is to allow display driver passing the object metadata, so PXP can check if the object is still valid base on the metadata.

But in the current design, we don't need this gem_object_metadata and we should consider to remove it. I will provide an update revision removing this argument, thanks for the feedback!

Best regards,
Sean

-----Original Message-----
From: Anshuman Gupta <anshuman.gupta@xxxxxxxxx> 
Sent: Tuesday, November 17, 2020 12:39 AM
To: Huang, Sean Z <sean.z.huang@xxxxxxxxx>
Cc: Intel-gfx@xxxxxxxxxxxxxxxxxxxxx; Bommu, Krishnaiah <krishnaiah.bommu@xxxxxxxxx>
Subject: Re:  [PATCH 22/27] drm/i915/pxp: Expose session state for display protection flip

On 2020-11-16 at 02:38:10 +0530, Huang, Sean Z wrote:
> Implement the intel_pxp_gem_object_status() to allow ring0 i915 
> display querying the current PXP session state. In the design,
> ring0 display should not perform protection flip on the protected 
> buffers if there is no PXP session alive.
> 
> Signed-off-by: Huang, Sean Z <sean.z.huang@xxxxxxxxx>
> ---
>  drivers/gpu/drm/i915/pxp/intel_pxp.c | 8 ++++++++  
> drivers/gpu/drm/i915/pxp/intel_pxp.h | 2 ++
>  2 files changed, 10 insertions(+)
> 
> diff --git a/drivers/gpu/drm/i915/pxp/intel_pxp.c 
> b/drivers/gpu/drm/i915/pxp/intel_pxp.c
> index 44d17ae27b94..05fe143675b1 100644
> --- a/drivers/gpu/drm/i915/pxp/intel_pxp.c
> +++ b/drivers/gpu/drm/i915/pxp/intel_pxp.c
> @@ -334,3 +334,11 @@ void intel_pxp_irq_handler(struct intel_gt *gt, 
> u16 iir)
>  end:
>  	return;
>  }
> +
> +bool intel_pxp_gem_object_status(struct drm_i915_private *i915, u64 
> +gem_object_metadata)
Currently this api used by Patch 27 of this series, uses gem object user flag (obj->user_flags) to pass as gem_object_metadata but it is unused ? why do  we need this gem_object_metadata ?

Thanks,
Anshuman Gupta.
> +{
> +	if (i915->pxp.r0ctx && i915->pxp.r0ctx->flag_display_hm_surface_keys)
> +		return true;
> +	else
> +		return false;
> +}
> diff --git a/drivers/gpu/drm/i915/pxp/intel_pxp.h 
> b/drivers/gpu/drm/i915/pxp/intel_pxp.h
> index c0119ccdab08..eb0e548ce434 100644
> --- a/drivers/gpu/drm/i915/pxp/intel_pxp.h
> +++ b/drivers/gpu/drm/i915/pxp/intel_pxp.h
> @@ -111,4 +111,6 @@ int 
> i915_pxp_global_terminate_complete_callback(struct drm_i915_private 
> *i915);  int intel_pxp_init(struct drm_i915_private *i915);  void 
> intel_pxp_uninit(struct drm_i915_private *i915);
>  
> +bool intel_pxp_gem_object_status(struct drm_i915_private *i915, u64 
> +gem_object_metadata);
> +
>  #endif
> --
> 2.17.1
> 
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
> https://lists.freedesktop.org/mailman/listinfo/intel-gfx
_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/intel-gfx



[Index of Archives]     [AMD Graphics]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux