<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/drivers/gpu/drm/amd/pm/powerplay, branch linux-6.14.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-6.14.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-6.14.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2025-04-25T08:51:13Z</updated>
<entry>
<title>drm/amd/pm/powerplay/hwmgr/vega20_thermal: Prevent division by zero</title>
<updated>2025-04-25T08:51:13Z</updated>
<author>
<name>Denis Arefev</name>
</author>
<published>2025-03-21T10:52:33Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=affd2241927a1e74c0aecd50c2d920dc4213c56d'/>
<id>urn:sha1:affd2241927a1e74c0aecd50c2d920dc4213c56d</id>
<content type='text'>
commit 4e3d9508c056d7e0a56b58d5c81253e2a0d22b6c upstream.

The user can set any speed value.
If speed is greater than UINT_MAX/8, division by zero is possible.

Found by Linux Verification Center (linuxtesting.org) with SVACE.

Fixes: 031db09017da ("drm/amd/powerplay/vega20: enable fan RPM and pwm settings V2")
Signed-off-by: Denis Arefev &lt;arefev@swemel.ru&gt;
Signed-off-by: Alex Deucher &lt;alexander.deucher@amd.com&gt;
Cc: stable@vger.kernel.org
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>drm/amd/pm/powerplay/hwmgr/smu7_thermal: Prevent division by zero</title>
<updated>2025-04-25T08:51:13Z</updated>
<author>
<name>Denis Arefev</name>
</author>
<published>2025-03-21T11:08:16Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=9e4f1e21fe7b93a8ef57db433071266c2590e260'/>
<id>urn:sha1:9e4f1e21fe7b93a8ef57db433071266c2590e260</id>
<content type='text'>
commit 7c246a05df51c52fe0852ce56ba10c41e6ed1f39 upstream.

The user can set any speed value.
If speed is greater than UINT_MAX/8, division by zero is possible.

Found by Linux Verification Center (linuxtesting.org) with SVACE.

Fixes: c52dcf49195d ("drm/amd/pp: Avoid divide-by-zero in fan_ctrl_set_fan_speed_rpm")
Signed-off-by: Denis Arefev &lt;arefev@swemel.ru&gt;
Signed-off-by: Alex Deucher &lt;alexander.deucher@amd.com&gt;
Cc: stable@vger.kernel.org
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>drm/amd/pm/powerplay: Prevent division by zero</title>
<updated>2025-04-25T08:51:12Z</updated>
<author>
<name>Denis Arefev</name>
</author>
<published>2025-03-21T11:08:15Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=05de66de280ea1bd0459c994bfd2dd332cfbc2a9'/>
<id>urn:sha1:05de66de280ea1bd0459c994bfd2dd332cfbc2a9</id>
<content type='text'>
commit 4b8c3c0d17c07f301011e2908fecd2ebdcfe3d1c upstream.

The user can set any speed value.
If speed is greater than UINT_MAX/8, division by zero is possible.

Found by Linux Verification Center (linuxtesting.org) with SVACE.

Fixes: c52dcf49195d ("drm/amd/pp: Avoid divide-by-zero in fan_ctrl_set_fan_speed_rpm")
Signed-off-by: Denis Arefev &lt;arefev@swemel.ru&gt;
Signed-off-by: Alex Deucher &lt;alexander.deucher@amd.com&gt;
Cc: stable@vger.kernel.org
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>drm/amdgpu: handle amdgpu_cgs_create_device() errors in amd_powerplay_create()</title>
<updated>2025-04-20T08:22:40Z</updated>
<author>
<name>Wentao Liang</name>
</author>
<published>2025-03-06T07:51:48Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=b784734811438f11533e2fb9e0deb327844bdb56'/>
<id>urn:sha1:b784734811438f11533e2fb9e0deb327844bdb56</id>
<content type='text'>
[ Upstream commit 1435e895d4fc967d64e9f5bf81e992ac32f5ac76 ]

Add error handling to propagate amdgpu_cgs_create_device() failures
to the caller. When amdgpu_cgs_create_device() fails, release hwmgr
and return -ENOMEM to prevent null pointer dereference.

[v1]-&gt;[v2]: Change error code from -EINVAL to -ENOMEM. Free hwmgr.

Signed-off-by: Wentao Liang &lt;vulab@iscas.ac.cn&gt;
Signed-off-by: Alex Deucher &lt;alexander.deucher@amd.com&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>drm/amdgpu: Fix potential NULL pointer dereference in atomctrl_get_smc_sclk_range_table</title>
<updated>2024-12-10T15:26:50Z</updated>
<author>
<name>Ivan Stepchenko</name>
</author>
<published>2024-12-02T08:00:43Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=357445e28ff004d7f10967aa93ddb4bffa5c3688'/>
<id>urn:sha1:357445e28ff004d7f10967aa93ddb4bffa5c3688</id>
<content type='text'>
The function atomctrl_get_smc_sclk_range_table() does not check the return
value of smu_atom_get_data_table(). If smu_atom_get_data_table() fails to
retrieve SMU_Info table, it returns NULL which is later dereferenced.

Found by Linux Verification Center (linuxtesting.org) with SVACE.

In practice this should never happen as this code only gets called
on polaris chips and the vbios data table will always be present on
those chips.

Fixes: a23eefa2f461 ("drm/amd/powerplay: enable dpm for baffin.")
Signed-off-by: Ivan Stepchenko &lt;sid@itb.spb.ru&gt;
Signed-off-by: Alex Deucher &lt;alexander.deucher@amd.com&gt;
</content>
</entry>
<entry>
<title>drm/amdgpu: pass ip_block in set_clockgating_state</title>
<updated>2024-12-10T15:26:47Z</updated>
<author>
<name>Boyuan Zhang</name>
</author>
<published>2024-10-07T23:43:31Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=f2ba8c3d510695c68ede786b3a37a9aa170ddfae'/>
<id>urn:sha1:f2ba8c3d510695c68ede786b3a37a9aa170ddfae</id>
<content type='text'>
Pass ip_block instead of adev in set_clockgating_state() callback
functions. Modify set_clockgating_state()for all correspoding ip blocks.

v2: remove all changes for is_idle(), remove type casting

Signed-off-by: Boyuan Zhang &lt;boyuan.zhang@amd.com&gt;
Acked-by: Christian König &lt;christian.koenig@amd.com&gt;
Reviewed-by: Sunil Khatri &lt;sunil.khatri@amd.com&gt;
Signed-off-by: Alex Deucher &lt;alexander.deucher@amd.com&gt;
</content>
</entry>
<entry>
<title>drm/amdgpu: pass ip_block in set_powergating_state</title>
<updated>2024-12-10T15:26:47Z</updated>
<author>
<name>Boyuan Zhang</name>
</author>
<published>2024-09-29T19:17:51Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=80d80511241cd3f532704dc4abbb604425552396'/>
<id>urn:sha1:80d80511241cd3f532704dc4abbb604425552396</id>
<content type='text'>
Pass ip_block instead of adev in set_powergating_state callback function.
Modify set_powergating_state ip functions for all correspoding ip blocks.

v2: fix a ip block index error.

v3: remove type casting

Signed-off-by: Boyuan Zhang &lt;boyuan.zhang@amd.com&gt;
Suggested-by: Christian König &lt;christian.koenig@amd.com&gt;
Acked-by: Christian König &lt;christian.koenig@amd.com&gt;
Acked-by: Alex Deucher &lt;alexander.deucher@amd.com&gt;
Reviewed-by: Sunil Khatri &lt;sunil.khatri@amd.com&gt;
Signed-off-by: Alex Deucher &lt;alexander.deucher@amd.com&gt;
</content>
</entry>
<entry>
<title>drm/amd/pm: add inst to set_powergating_by_smu</title>
<updated>2024-12-10T15:26:47Z</updated>
<author>
<name>Boyuan Zhang</name>
</author>
<published>2024-10-03T03:25:45Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=697cb5cc2549c5aa8da541ec5d815500edc35f88'/>
<id>urn:sha1:697cb5cc2549c5aa8da541ec5d815500edc35f88</id>
<content type='text'>
Add an instance parameter to set_powergating_by_smu() function, and
re-write all amd_pm functions accordingly. Then use the instance to
call smu_dpm_set_vcn_enable().

v2: remove duplicated functions.

remove for-loop in smu_dpm_set_power_gate(), and temporarily move it to
to amdgpu_dpm_set_powergating_by_smu(), in order to keep the exact same
logic as before, until further separation in next patch.

v3: add instance number in error message.

Signed-off-by: Boyuan Zhang &lt;boyuan.zhang@amd.com&gt;
Acked-by: Christian König &lt;christian.koenig@amd.com&gt;
Reviewed-by: Alex Deucher &lt;alexander.deucher@amd.com&gt;
Signed-off-by: Alex Deucher &lt;alexander.deucher@amd.com&gt;
</content>
</entry>
<entry>
<title>drm/amd/pm: Fix an error handling path in vega10_enable_se_edc_force_stall_config()</title>
<updated>2024-12-10T15:26:47Z</updated>
<author>
<name>Christophe JAILLET</name>
</author>
<published>2024-11-19T20:23:18Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=a3300782d5375e280ba7040f323d01960bfe3396'/>
<id>urn:sha1:a3300782d5375e280ba7040f323d01960bfe3396</id>
<content type='text'>
In case of error after a amdgpu_gfx_rlc_enter_safe_mode() call, it is not
balanced by a corresponding amdgpu_gfx_rlc_exit_safe_mode() call.

Add the missing call.

Fixes: 9b7b8154cdb8 ("drm/amd/powerplay: added didt support for vega10")
Signed-off-by: Christophe JAILLET &lt;christophe.jaillet@wanadoo.fr&gt;
Signed-off-by: Alex Deucher &lt;alexander.deucher@amd.com&gt;
</content>
</entry>
<entry>
<title>drm/amd/pm: remove redundant tools_size check</title>
<updated>2024-11-20T14:38:12Z</updated>
<author>
<name>Bhavin Sharma</name>
</author>
<published>2024-11-14T15:11:12Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=6ecccc093ec439c04d62b40bda76240389d104a8'/>
<id>urn:sha1:6ecccc093ec439c04d62b40bda76240389d104a8</id>
<content type='text'>
The check for tools_size being non-zero is redundant as tools_size is
explicitly set to a non-zero value (0x19000). Removing the if condition
simplifies the code without altering functionality.

Signed-off-by: Bhavin Sharma &lt;bhavin.sharma@siliconsignals.io&gt;
Signed-off-by: Alex Deucher &lt;alexander.deucher@amd.com&gt;
</content>
</entry>
</feed>
