From: V sujith kumar Reddy Date: Mon, 8 May 2023 07:05:08 +0000 (+0530) Subject: ASoC: SOF: amd: Fix NULL pointer crash in acp_sof_ipc_msg_data function X-Git-Tag: v6.6.7~1940^2~11^2~40 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=051d71e073614a72ad423d6dacba37a7eeff274d;p=platform%2Fkernel%2Flinux-starfive.git ASoC: SOF: amd: Fix NULL pointer crash in acp_sof_ipc_msg_data function Check substream and runtime variables before assigning. Signed-off-by: V sujith kumar Reddy substream; - struct acp_dsp_stream *stream = substream->runtime->private_data; + struct acp_dsp_stream *stream; + + if (!substream || !substream->runtime) + return -ESTRPIPE; + + stream = substream->runtime->private_data; if (!stream) return -ESTRPIPE;