Skip to content

Commit 72a1eb3

Browse files
Aurabindo Pillaialexdeucher
authored andcommitted
drm/amd/display: use GFP_NOWAIT for allocation in interrupt handler
schedule_dc_vmin_vmax() is called by dm_crtc_high_irq(). Hence, we cannot have the former sleep. Use GFP_NOWAIT for allocation in this function. Fixes: c210b75 ("drm/amd/display: fix dmub access race condition") Cc: Mario Limonciello <[email protected]> Cc: Alex Deucher <[email protected]> Reviewed-by: Sun peng (Leo) Li <[email protected]> Signed-off-by: Aurabindo Pillai <[email protected]> Signed-off-by: Alex Deucher <[email protected]> (cherry picked from commit c04812cbe2f247a1c1e53a9b6c5e659963fe4065) Cc: [email protected]
1 parent bec947c commit 72a1eb3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -551,13 +551,13 @@ static void schedule_dc_vmin_vmax(struct amdgpu_device *adev,
551551
struct dc_stream_state *stream,
552552
struct dc_crtc_timing_adjust *adjust)
553553
{
554-
struct vupdate_offload_work *offload_work = kzalloc(sizeof(*offload_work), GFP_KERNEL);
554+
struct vupdate_offload_work *offload_work = kzalloc(sizeof(*offload_work), GFP_NOWAIT);
555555
if (!offload_work) {
556556
drm_dbg_driver(adev_to_drm(adev), "Failed to allocate vupdate_offload_work\n");
557557
return;
558558
}
559559

560-
struct dc_crtc_timing_adjust *adjust_copy = kzalloc(sizeof(*adjust_copy), GFP_KERNEL);
560+
struct dc_crtc_timing_adjust *adjust_copy = kzalloc(sizeof(*adjust_copy), GFP_NOWAIT);
561561
if (!adjust_copy) {
562562
drm_dbg_driver(adev_to_drm(adev), "Failed to allocate adjust_copy\n");
563563
kfree(offload_work);

0 commit comments

Comments
 (0)