lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAFJ_xbprw7UKREWgRAq3dDAA9oC_3cWoozn5pCY8w9By4dASag@mail.gmail.com>
Date:   Tue, 12 Jan 2021 12:34:15 +0100
From:   Łukasz Majczak <lma@...ihalf.com>
To:     Pierre-Louis Bossart <pierre-louis.bossart@...ux.intel.com>,
        Liam Girdwood <liam.r.girdwood@...ux.intel.com>,
        Mateusz Gorski <mateusz.gorski@...ux.intel.com>
Cc:     Marcin Wojtas <mw@...ihalf.com>,
        Radoslaw Biernacki <rad@...ihalf.com>,
        Alex Levin <levinale@...gle.com>,
        Guenter Roeck <groeck@...gle.com>, alsa-devel@...a-project.org,
        linux-kernel@...r.kernel.org, stable@...r.kernel.org
Subject: Re: [PATCH v2] ASoC: Intel: Skylake: Check the kcontrol against NULL

Hi,

This is just a kind reminder. Is there anything more required to
upstream this patch?

Best regards,
Lukasz


czw., 17 gru 2020 o 14:06 Lukasz Majczak <lma@...ihalf.com> napisał(a):
>
> There is no check for the kcontrol against NULL and in some cases
> it causes kernel to crash.
>
> Fixes: 2d744ecf2b984 ("ASoC: Intel: Skylake: Automatic DMIC format configuration according to information from NHLT")
> Cc: <stable@...r.kernel.org> # 5.4+
> Signed-off-by: Lukasz Majczak <lma@...ihalf.com>
> Reviewed-by: Mateusz Gorski <mateusz.gorski@...ux.intel.com>
> ---
>  sound/soc/intel/skylake/skl-topology.c | 14 ++++++++++----
>  1 file changed, 10 insertions(+), 4 deletions(-)
>  v1 -> v2: fixed coding style
>
> diff --git a/sound/soc/intel/skylake/skl-topology.c b/sound/soc/intel/skylake/skl-topology.c
> index ae466cd592922..8f0bfda7096a9 100644
> --- a/sound/soc/intel/skylake/skl-topology.c
> +++ b/sound/soc/intel/skylake/skl-topology.c
> @@ -3618,12 +3618,18 @@ static void skl_tplg_complete(struct snd_soc_component *component)
>         int i;
>
>         list_for_each_entry(dobj, &component->dobj_list, list) {
> -               struct snd_kcontrol *kcontrol = dobj->control.kcontrol;
> -               struct soc_enum *se =
> -                       (struct soc_enum *)kcontrol->private_value;
> -               char **texts = dobj->control.dtexts;
> +               struct snd_kcontrol *kcontrol;
> +               struct soc_enum *se;
> +               char **texts;
>                 char chan_text[4];
>
> +               kcontrol = dobj->control.kcontrol;
> +               if (!kcontrol)
> +                       continue;
> +
> +               se = (struct soc_enum *)kcontrol->private_value;
> +               texts = dobj->control.dtexts;
> +
>                 if (dobj->type != SND_SOC_DOBJ_ENUM ||
>                     dobj->control.kcontrol->put !=
>                     skl_tplg_multi_config_set_dmic)
> --
> 2.25.1
>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ