<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<p style="font-family:Arial;font-size:10pt;color:#0000FF;margin:5pt;" align="Left">
[AMD Official Use Only]<br>
</p>
<br>
<div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Please include a patch description even if it's similar to the subject.<br>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Alex</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div id="appendonsend"></div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> amd-gfx <amd-gfx-bounces@lists.freedesktop.org> on behalf of Stanley.Yang <Stanley.Yang@amd.com><br>
<b>Sent:</b> Wednesday, January 19, 2022 6:30 AM<br>
<b>To:</b> amd-gfx@lists.freedesktop.org <amd-gfx@lists.freedesktop.org>; Zhang, Hawking <Hawking.Zhang@amd.com>; Ziya, Mohammad zafar <Mohammadzafar.Ziya@amd.com>; Clements, John <John.Clements@amd.com>; Zhou1, Tao <Tao.Zhou1@amd.com><br>
<b>Cc:</b> Yang, Stanley <Stanley.Yang@amd.com><br>
<b>Subject:</b> [PATCH Review 1/1] drm/amdgpu: remove unused variable warning</font>
<div> </div>
</div>
<div class="BodyFragment"><font size="2"><span style="font-size:11pt;">
<div class="PlainText">Change-Id: Ic2a488ee253a913d806bd33ee9c90e31a71af320<br>
Signed-off-by: Stanley.Yang <Stanley.Yang@amd.com><br>
---<br>
drivers/gpu/drm/amd/amdgpu/umc_v6_7.c | 23 -----------------------<br>
drivers/gpu/drm/amd/amdgpu/umc_v8_7.c | 6 ------<br>
2 files changed, 29 deletions(-)<br>
<br>
diff --git a/drivers/gpu/drm/amd/amdgpu/umc_v6_7.c b/drivers/gpu/drm/amd/amdgpu/umc_v6_7.c<br>
index 6953426f0bed..526de1ca9b8d 100644<br>
--- a/drivers/gpu/drm/amd/amdgpu/umc_v6_7.c<br>
+++ b/drivers/gpu/drm/amd/amdgpu/umc_v6_7.c<br>
@@ -61,22 +61,9 @@ static void umc_v6_7_ecc_info_query_correctable_error_count(struct amdgpu_device<br>
uint32_t channel_index,<br>
unsigned long *error_count)<br>
{<br>
- uint32_t ecc_err_cnt;<br>
uint64_t mc_umc_status;<br>
struct amdgpu_ras *ras = amdgpu_ras_get_context(adev);<br>
<br>
- /*<br>
- * select the lower chip and check the error count<br>
- * skip add error count, calc error counter only from mca_umc_status<br>
- */<br>
- ecc_err_cnt = ras->umc_ecc.ecc[channel_index].ce_count_lo_chip;<br>
-<br>
- /*<br>
- * select the higher chip and check the err counter<br>
- * skip add error count, calc error counter only from mca_umc_status<br>
- */<br>
- ecc_err_cnt = ras->umc_ecc.ecc[channel_index].ce_count_hi_chip;<br>
-<br>
/* check for SRAM correctable error<br>
MCUMC_STATUS is a 64 bit register */<br>
mc_umc_status = ras->umc_ecc.ecc[channel_index].mca_umc_status;<br>
@@ -110,15 +97,11 @@ static void umc_v6_7_ecc_info_query_ras_error_count(struct amdgpu_device *adev,<br>
<br>
uint32_t umc_inst = 0;<br>
uint32_t ch_inst = 0;<br>
- uint32_t umc_reg_offset = 0;<br>
uint32_t channel_index = 0;<br>
<br>
/*TODO: driver needs to toggle DF Cstate to ensure<br>
* safe access of UMC registers. Will add the protection */<br>
LOOP_UMC_INST_AND_CH(umc_inst, ch_inst) {<br>
- umc_reg_offset = get_umc_v6_7_reg_offset(adev,<br>
- umc_inst,<br>
- ch_inst);<br>
channel_index = get_umc_v6_7_channel_index(adev,<br>
umc_inst,<br>
ch_inst);<br>
@@ -133,7 +116,6 @@ static void umc_v6_7_ecc_info_query_ras_error_count(struct amdgpu_device *adev,<br>
<br>
static void umc_v6_7_ecc_info_query_error_address(struct amdgpu_device *adev,<br>
struct ras_err_data *err_data,<br>
- uint32_t umc_reg_offset,<br>
uint32_t ch_inst,<br>
uint32_t umc_inst)<br>
{<br>
@@ -192,18 +174,13 @@ static void umc_v6_7_ecc_info_query_ras_error_address(struct amdgpu_device *adev<br>
<br>
uint32_t umc_inst = 0;<br>
uint32_t ch_inst = 0;<br>
- uint32_t umc_reg_offset = 0;<br>
<br>
/*TODO: driver needs to toggle DF Cstate to ensure<br>
* safe access of UMC resgisters. Will add the protection<br>
* when firmware interface is ready */<br>
LOOP_UMC_INST_AND_CH(umc_inst, ch_inst) {<br>
- umc_reg_offset = get_umc_v6_7_reg_offset(adev,<br>
- umc_inst,<br>
- ch_inst);<br>
umc_v6_7_ecc_info_query_error_address(adev,<br>
err_data,<br>
- umc_reg_offset,<br>
ch_inst,<br>
umc_inst);<br>
}<br>
diff --git a/drivers/gpu/drm/amd/amdgpu/umc_v8_7.c b/drivers/gpu/drm/amd/amdgpu/umc_v8_7.c<br>
index 05f79eea307c..cd57f39df7d1 100644<br>
--- a/drivers/gpu/drm/amd/amdgpu/umc_v8_7.c<br>
+++ b/drivers/gpu/drm/amd/amdgpu/umc_v8_7.c<br>
@@ -114,7 +114,6 @@ static void umc_v8_7_ecc_info_query_ras_error_count(struct amdgpu_device *adev,<br>
<br>
static void umc_v8_7_ecc_info_query_error_address(struct amdgpu_device *adev,<br>
struct ras_err_data *err_data,<br>
- uint32_t umc_reg_offset,<br>
uint32_t ch_inst,<br>
uint32_t umc_inst)<br>
{<br>
@@ -173,19 +172,14 @@ static void umc_v8_7_ecc_info_query_ras_error_address(struct amdgpu_device *adev<br>
<br>
uint32_t umc_inst = 0;<br>
uint32_t ch_inst = 0;<br>
- uint32_t umc_reg_offset = 0;<br>
<br>
/* TODO: driver needs to toggle DF Cstate to ensure<br>
* safe access of UMC resgisters. Will add the protection<br>
* when firmware interface is ready<br>
*/<br>
LOOP_UMC_INST_AND_CH(umc_inst, ch_inst) {<br>
- umc_reg_offset = get_umc_v8_7_reg_offset(adev,<br>
- umc_inst,<br>
- ch_inst);<br>
umc_v8_7_ecc_info_query_error_address(adev,<br>
err_data,<br>
- umc_reg_offset,<br>
ch_inst,<br>
umc_inst);<br>
}<br>
-- <br>
2.17.1<br>
<br>
</div>
</span></font></div>
</div>
</body>
</html>