Skip to content

Commit

Permalink
drm: xlnx: zynqmp_disp: layer may be null while releasing
Browse files Browse the repository at this point in the history
layer->info can be null if we have an error on the first layer in
zynqmp_disp_create_layers

Fixes: 1836fd5 ("drm: xlnx: zynqmp_dpsub: Minimize usage of global flag")
Signed-off-by: Steffen Dirkwinkel <s.dirkwinkel@beckhoff.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20241028133941.54264-1-lists@steffen.cc
  • Loading branch information
Steffen Dirkwinkel authored and Tomi Valkeinen committed Oct 30, 2024
1 parent 28edaac commit 223842c
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions drivers/gpu/drm/xlnx/zynqmp_disp.c
Original file line number Diff line number Diff line change
Expand Up @@ -1200,6 +1200,9 @@ static void zynqmp_disp_layer_release_dma(struct zynqmp_disp *disp,
{
unsigned int i;

if (!layer->info)
return;

for (i = 0; i < layer->info->num_channels; i++) {
struct zynqmp_disp_layer_dma *dma = &layer->dmas[i];

Expand Down

0 comments on commit 223842c

Please sign in to comment.