]> git.baikalelectronics.ru Git - kernel.git/commit
drm/amd/powerplay: fix various dereferences of a pointer before it is null checked
authorColin Ian King <colin.king@canonical.com>
Thu, 12 Dec 2019 18:16:57 +0000 (18:16 +0000)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 18 Dec 2019 21:09:05 +0000 (16:09 -0500)
commit5063dad35a2910e25b733e6e6bd4776f58c53205
tree126e3c5cb63e58c5a50318fd42a33bb79bfc56dc
parentd590f58758fd060b775d94f9f9a91ba6482e4bf0
drm/amd/powerplay: fix various dereferences of a pointer before it is null checked

There are several occurrances of the pointer hwmgr being dereferenced
before it is null checked.  Fix these by performing the dereference
of hwmgr after it has been null checked.

Addresses-Coverity: ("Dereference before null check")
Fixes: 051336948c1182 ("drm/amd/powerplay: enable pp one vf mode for vega10")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/powerplay/amd_powerplay.c
drivers/gpu/drm/amd/powerplay/hwmgr/hwmgr.c