[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CADnq5_PbjTWCgY-WrNdYna+Dr6F0+OiMEcjk5FpEk9VUSM9U-g@mail.gmail.com>
Date: Fri, 12 Nov 2021 17:58:12 -0500
From: Alex Deucher <alexdeucher@...il.com>
To: CGEL <cgel.zte@...il.com>
Cc: "Wentland, Harry" <harry.wentland@....com>,
Dmytro Laktyushkin <Dmytro.Laktyushkin@....com>,
"Leo (Sunpeng) Li" <sunpeng.li@....com>,
LKML <linux-kernel@...r.kernel.org>,
Zeal Robot <zealci@....com.cn>,
xinhui pan <Xinhui.Pan@....com>,
"Siqueira, Rodrigo" <Rodrigo.Siqueira@....com>,
amd-gfx list <amd-gfx@...ts.freedesktop.org>,
"Kazlauskas, Nicholas" <nicholas.kazlauskas@....com>,
Dave Airlie <airlied@...ux.ie>, Jerry Zuo <Jerry.Zuo@....com>,
Vladimir Stempen <vladimir.stempen@....com>,
Maling list - DRI developers
<dri-devel@...ts.freedesktop.org>,
"Deucher, Alexander" <alexander.deucher@....com>,
Ye Guojin <ye.guojin@....com.cn>, Jun Lei <Jun.Lei@....com>,
Christian Koenig <christian.koenig@....com>,
Jimmy Kizito <Jimmy.Kizito@....com>
Subject: Re: [PATCH] drm/amd/display: fix cond_no_effect.cocci warnings
Applied. Thanks!
Alex
On Fri, Nov 12, 2021 at 1:17 AM <cgel.zte@...il.com> wrote:
>
> From: Ye Guojin <ye.guojin@....com.cn>
>
> This was found by coccicheck:
> ./drivers/gpu/drm/amd/display/dc/core/dc_resource.c, 2516, 7-9, WARNING
> possible condition with no effect (if == else)
>
> hdmi_info.bits.YQ0_YQ1 is always YYC_QUANTIZATION_LIMITED_RANGE.
>
> Reported-by: Zeal Robot <zealci@....com.cn>
> Signed-off-by: Ye Guojin <ye.guojin@....com.cn>
> ---
> drivers/gpu/drm/amd/display/dc/core/dc_resource.c | 12 +-----------
> 1 file changed, 1 insertion(+), 11 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/display/dc/core/dc_resource.c b/drivers/gpu/drm/amd/display/dc/core/dc_resource.c
> index fabe1b83bd4f..564163a85d2c 100644
> --- a/drivers/gpu/drm/amd/display/dc/core/dc_resource.c
> +++ b/drivers/gpu/drm/amd/display/dc/core/dc_resource.c
> @@ -2509,17 +2509,7 @@ static void set_avi_info_frame(
>
> /* TODO : We should handle YCC quantization */
> /* but we do not have matrix calculation */
> - if (stream->qy_bit == 1) {
> - if (color_space == COLOR_SPACE_SRGB ||
> - color_space == COLOR_SPACE_2020_RGB_FULLRANGE)
> - hdmi_info.bits.YQ0_YQ1 = YYC_QUANTIZATION_LIMITED_RANGE;
> - else if (color_space == COLOR_SPACE_SRGB_LIMITED ||
> - color_space == COLOR_SPACE_2020_RGB_LIMITEDRANGE)
> - hdmi_info.bits.YQ0_YQ1 = YYC_QUANTIZATION_LIMITED_RANGE;
> - else
> - hdmi_info.bits.YQ0_YQ1 = YYC_QUANTIZATION_LIMITED_RANGE;
> - } else
> - hdmi_info.bits.YQ0_YQ1 = YYC_QUANTIZATION_LIMITED_RANGE;
> + hdmi_info.bits.YQ0_YQ1 = YYC_QUANTIZATION_LIMITED_RANGE;
>
> ///VIC
> format = stream->timing.timing_3d_format;
> --
> 2.25.1
>
Powered by blists - more mailing lists