[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CADnq5_PN99cigjruAv38y2KHHdrNY2VAqKhD_K3yUoO01Q4b_w@mail.gmail.com>
Date: Mon, 25 Nov 2019 09:39:21 -0500
From: Alex Deucher <alexdeucher@...il.com>
To: Colin King <colin.king@...onical.com>
Cc: Rex Zhu <rex.zhu@....com>, Evan Quan <evan.quan@....com>,
Alex Deucher <alexander.deucher@....com>,
Christian König <christian.koenig@....com>,
David Zhou <David1.Zhou@....com>,
David Airlie <airlied@...ux.ie>,
Daniel Vetter <daniel@...ll.ch>,
amd-gfx list <amd-gfx@...ts.freedesktop.org>,
Maling list - DRI developers
<dri-devel@...ts.freedesktop.org>, kernel-janitors@...r.kernel.org,
LKML <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] drm/amd/powerplay: remove redundant assignment to
variables HiSidd and LoSidd
On Fri, Nov 22, 2019 at 6:04 PM Colin King <colin.king@...onical.com> wrote:
>
> From: Colin Ian King <colin.king@...onical.com>
>
> The variables HiSidd and LoSidd are being initialized with values that
> are never read and are being updated a little later with a new value.
> The initialization is redundant and can be removed.
>
> Addresses-Coverity: ("Unused value")
> Signed-off-by: Colin Ian King <colin.king@...onical.com>
Applied. Thanks!
Alex
> ---
> drivers/gpu/drm/amd/powerplay/smumgr/ci_smumgr.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/powerplay/smumgr/ci_smumgr.c b/drivers/gpu/drm/amd/powerplay/smumgr/ci_smumgr.c
> index 15590fd86ef4..868e2d5f6e62 100644
> --- a/drivers/gpu/drm/amd/powerplay/smumgr/ci_smumgr.c
> +++ b/drivers/gpu/drm/amd/powerplay/smumgr/ci_smumgr.c
> @@ -653,8 +653,8 @@ static int ci_min_max_v_gnbl_pm_lid_from_bapm_vddc(struct pp_hwmgr *hwmgr)
> static int ci_populate_bapm_vddc_base_leakage_sidd(struct pp_hwmgr *hwmgr)
> {
> struct ci_smumgr *smu_data = (struct ci_smumgr *)(hwmgr->smu_backend);
> - uint16_t HiSidd = smu_data->power_tune_table.BapmVddCBaseLeakageHiSidd;
> - uint16_t LoSidd = smu_data->power_tune_table.BapmVddCBaseLeakageLoSidd;
> + uint16_t HiSidd;
> + uint16_t LoSidd;
> struct phm_cac_tdp_table *cac_table = hwmgr->dyn_state.cac_dtp_table;
>
> HiSidd = (uint16_t)(cac_table->usHighCACLeakage / 100 * 256);
> --
> 2.24.0
>
> _______________________________________________
> dri-devel mailing list
> dri-devel@...ts.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel
Powered by blists - more mailing lists