Skip to content

Commit

Permalink
drm/amd/display: Don't use fsleep for PSR exit waits on dmub replay
Browse files Browse the repository at this point in the history
[ Upstream commit b5236da ]

[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: Rodrigo Siqueira <[email protected]>
Signed-off-by: Nicholas Kazlauskas <[email protected]>
Tested-by: Daniel Wheeler <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
Signed-off-by: Sasha Levin <[email protected]>
  • Loading branch information
Nicholas Kazlauskas authored and gregkh committed Sep 8, 2024
1 parent 0b9696a commit 80a9848
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion drivers/gpu/drm/amd/display/dc/dce/dmub_replay.c
Original file line number Diff line number Diff line change
Expand Up @@ -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 */
Expand Down

0 comments on commit 80a9848

Please sign in to comment.