summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNatalie Vock <natalie.vock@gmx.de>2026-02-23 14:45:37 +0300
committerAlex Deucher <alexander.deucher@amd.com>2026-02-26 00:54:24 +0300
commitb42dae2ebc5c84a68de63ec4ffdfec49362d53f1 (patch)
treecb419b984c807b4bf2742349abe295ecb714716d
parentfcec012c664247531aed3e662f4280ff804d1476 (diff)
downloadlinux-b42dae2ebc5c84a68de63ec4ffdfec49362d53f1.tar.xz
drm/amd/display: Use GFP_ATOMIC in dc_create_stream_for_sink
This can be called while preemption is disabled, for example by dcn32_internal_validate_bw which is called with the FPU active. Fixes "BUG: scheduling while atomic" messages I encounter on my Navi31 machine. Signed-off-by: Natalie Vock <natalie.vock@gmx.de> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
-rw-r--r--drivers/gpu/drm/amd/display/dc/core/dc_stream.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/drm/amd/display/dc/core/dc_stream.c b/drivers/gpu/drm/amd/display/dc/core/dc_stream.c
index 246893d80f1f..baf820e6eae8 100644
--- a/drivers/gpu/drm/amd/display/dc/core/dc_stream.c
+++ b/drivers/gpu/drm/amd/display/dc/core/dc_stream.c
@@ -170,11 +170,11 @@ struct dc_stream_state *dc_create_stream_for_sink(
if (sink == NULL)
goto fail;
- stream = kzalloc_obj(struct dc_stream_state);
+ stream = kzalloc_obj(struct dc_stream_state, GFP_ATOMIC);
if (stream == NULL)
goto fail;
- stream->update_scratch = kzalloc((int32_t) dc_update_scratch_space_size(), GFP_KERNEL);
+ stream->update_scratch = kzalloc((int32_t) dc_update_scratch_space_size(), GFP_ATOMIC);
if (stream->update_scratch == NULL)
goto fail;