Re: [PATCH] ALSA: ac97: Fix possible NULL dereference in snd_ac97_mixer

From: Takashi Iwai
Date: Thu Jun 15 2023 - 02:44:03 EST


On Thu, 15 Jun 2023 04:17:32 +0200,
Su Hui wrote:
>
> smatch error:
> sound/pci/ac97/ac97_codec.c:2354 snd_ac97_mixer() error:
> we previously assumed 'rac97' could be null (see line 2072)
>
> remove redundant assignment, return error if rac97 is NULL.
>
> Fixes: da3cec35dd3c ("ALSA: Kill snd_assert() in sound/pci/*")
> Signed-off-by: Su Hui <suhui@xxxxxxxxxxxx>

Thanks, applied.


Takashi