[Intel-gfx] [PATCH v9 1/7] drm/dp_helper: Add helper to check if the sink supports given format with DSC
Shankar, Uma
uma.shankar at intel.com
Mon Feb 20 20:37:44 UTC 2023
> -----Original Message-----
> From: Intel-gfx <intel-gfx-bounces at lists.freedesktop.org> On Behalf Of Suraj
> Kandpal
> Sent: Tuesday, February 7, 2023 1:14 PM
> To: intel-gfx at lists.freedesktop.org
> Subject: [Intel-gfx] [PATCH v9 1/7] drm/dp_helper: Add helper to check if the sink
> supports given format with DSC
>
> From: Ankit Nautiyal <ankit.k.nautiyal at intel.com>
>
> Add helper function to check if the DP sink supports DSC with the given output
> format.
Nit: You can drop "function" and "the" to truncate it, add o/p format to be clear.
Also I feel this can be squashed with 2nd patch. This seems to be a static function,
so scope is limited.
>
> Signed-off-by: Ankit Nautiyal <ankit.k.nautiyal at intel.com>
> ---
> include/drm/display/drm_dp_helper.h | 7 +++++++
> 1 file changed, 7 insertions(+)
>
> diff --git a/include/drm/display/drm_dp_helper.h
> b/include/drm/display/drm_dp_helper.h
> index ab55453f2d2c..d529d0254b68 100644
> --- a/include/drm/display/drm_dp_helper.h
> +++ b/include/drm/display/drm_dp_helper.h
> @@ -194,6 +194,13 @@ drm_dp_dsc_sink_max_slice_width(const u8
> dsc_dpcd[DP_DSC_RECEIVER_CAP_SIZE])
> DP_DSC_SLICE_WIDTH_MULTIPLIER;
> }
>
> +/* Check if sink supports DSC with given output format */
To stay consistent with rest of the file, please elaborate the function's purpose
and explain input parameters.
static inline
> +bool drm_dp_dsc_sink_supports_format(const u8
> +dsc_dpcd[DP_DSC_RECEIVER_CAP_SIZE], u8 output_format) {
> + return dsc_dpcd[DP_DSC_DEC_COLOR_FORMAT_CAP - DP_DSC_SUPPORT]
> &
> +output_format; }
> +
> /* Forward Error Correction Support on DP 1.4 */ static inline bool
> drm_dp_sink_supports_fec(const u8 fec_capable)
> --
> 2.25.1
More information about the Intel-gfx
mailing list