Commit e8f04a3c authored by Nicholas Kazlauskas's avatar Nicholas Kazlauskas Committed by Wen Zhiwei
Browse files

drm/amd/display: Don't use fsleep for PSR exit waits on dmub replay

stable inclusion
from stable-v6.6.50
commit da696cbb47941c40b01cc10ea5504dc5a4ebac6e
category: bugfix
bugzilla: https://gitee.com/openeuler/kernel/issues/IAYKL6

Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=da696cbb47941c40b01cc10ea5504dc5a4ebac6e



--------------------------------

[ Upstream commit b5236da757adc75d7e52c69bdc233d29249a0d0c ]

[Why]
These functions can be called from high IRQ levels and the OS will hang
if it tries to use a usleep_highres or a msleep.

[How]
Replace the flseep with a udelay for dmub_replay_enable.

Reviewed-by: default avatarRodrigo Siqueira <Rodrigo.Siqueira@amd.com>
Signed-off-by: default avatarNicholas Kazlauskas <nicholas.kazlauskas@amd.com>
Tested-by: default avatarDaniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
Signed-off-by: default avatarWen Zhiwei <wenzhiwei@kylinos.cn>
parent 02b31360
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -102,7 +102,8 @@ static void dmub_replay_enable(struct dmub_replay *dmub, bool enable, bool wait,
					break;
			}

			fsleep(500);
			/* must *not* be fsleep - this can be called from high irq levels */
			udelay(500);
		}

		/* assert if max retry hit */