<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=Windows-1252">
<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:#0078D7;margin:15pt;" align="Left">
[AMD Official Use Only - Internal Distribution Only]<br>
</p>
<br>
<div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Reviewed-by: Alex Deucher <alexander.deucher@amd.com><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> Das, Nirmoy <Nirmoy.Das@amd.com><br>
<b>Sent:</b> Thursday, August 27, 2020 11:58 AM<br>
<b>To:</b> amd-gfx@lists.freedesktop.org <amd-gfx@lists.freedesktop.org><br>
<b>Cc:</b> Deucher, Alexander <Alexander.Deucher@amd.com>; Das, Nirmoy <Nirmoy.Das@amd.com><br>
<b>Subject:</b> [PATCH 1/1] drm/amdgpu: fix compiler warnings</font>
<div> </div>
</div>
<div class="BodyFragment"><font size="2"><span style="font-size:11pt;">
<div class="PlainText">Fixes below compiler warnings:<br>
 CC [M]  drivers/gpu/drm/amd/amdgpu/amdgpu_device.o<br>
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c:381:1: warning: ‘static’ is not at beginning of declaration [-Wold-style-declaration]<br>
  381 | void static inline amdgpu_mm_wreg_mmio(struct amdgpu_device *adev, uint32_t reg, uint32_t v, uint32_t acc_flags)<br>
      | ^~~~<br>
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c:381:1: warning: ‘inline’ is not at beginning of declaration [-Wold-style-declaration]<br>
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c: In function ‘amdgpu_device_fini’:<br>
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c:3381:6: warning: variable ‘r’ set but not used [-Wunused-but-set-variable]<br>
 3381 |  int r;<br>
      |      ^<br>
<br>
Signed-off-by: Nirmoy Das <nirmoy.das@amd.com><br>
---<br>
 drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 8 ++++----<br>
 1 file changed, 4 insertions(+), 4 deletions(-)<br>
<br>
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c<br>
index 696a61cc3ac6..6518e444bead 100644<br>
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c<br>
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c<br>
@@ -378,7 +378,9 @@ void amdgpu_mm_wreg8(struct amdgpu_device *adev, uint32_t offset, uint8_t value)<br>
                 BUG();<br>
 }<br>
 <br>
-void static inline amdgpu_mm_wreg_mmio(struct amdgpu_device *adev, uint32_t reg, uint32_t v, uint32_t acc_flags)<br>
+static inline void amdgpu_mm_wreg_mmio(struct amdgpu_device *adev,<br>
+                                      uint32_t reg, uint32_t v,<br>
+                                      uint32_t acc_flags)<br>
 {<br>
         trace_amdgpu_mm_wreg(adev->pdev->device, reg, v);<br>
 <br>
@@ -3378,8 +3380,6 @@ int amdgpu_device_init(struct amdgpu_device *adev,<br>
  */<br>
 void amdgpu_device_fini(struct amdgpu_device *adev)<br>
 {<br>
-       int r;<br>
-<br>
         dev_info(adev->dev, "amdgpu: finishing device.\n");<br>
         flush_delayed_work(&adev->delayed_init_work);<br>
         adev->shutdown = true;<br>
@@ -3402,7 +3402,7 @@ void amdgpu_device_fini(struct amdgpu_device *adev)<br>
         if (adev->pm_sysfs_en)<br>
                 amdgpu_pm_sysfs_fini(adev);<br>
         amdgpu_fbdev_fini(adev);<br>
-       r = amdgpu_device_ip_fini(adev);<br>
+       amdgpu_device_ip_fini(adev);<br>
         release_firmware(adev->firmware.gpu_info_fw);<br>
         adev->firmware.gpu_info_fw = NULL;<br>
         adev->accel_working = false;<br>
-- <br>
2.28.0<br>
<br>
</div>
</span></font></div>
</div>
</body>
</html>