[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ba585faa-d761-45ed-9e44-784097b3439a@linux.intel.com>
Date: Mon, 8 Apr 2024 10:37:29 -0500
From: Pierre-Louis Bossart <pierre-louis.bossart@...ux.intel.com>
To: Dan Carpenter <dan.carpenter@...aro.org>, Brent Lu <brent.lu@...el.com>
Cc: Cezary Rojewski <cezary.rojewski@...el.com>,
Liam Girdwood <liam.r.girdwood@...ux.intel.com>,
Peter Ujfalusi <peter.ujfalusi@...ux.intel.com>,
Bard Liao <yung-chuan.liao@...ux.intel.com>,
Ranjani Sridharan <ranjani.sridharan@...ux.intel.com>,
Kai Vehmanen <kai.vehmanen@...ux.intel.com>, Mark Brown
<broonie@...nel.org>, Jaroslav Kysela <perex@...ex.cz>,
Takashi Iwai <tiwai@...e.com>, Terry Cheong <htcheong@...omium.org>,
Uday M Bhat <uday.m.bhat@...el.com>,
Kuninori Morimoto <kuninori.morimoto.gx@...esas.com>,
Mac Chiang <mac.chiang@...el.com>, apoorv <apoorv@...el.com>,
alsa-devel@...a-project.org, linux-sound@...r.kernel.org,
linux-kernel@...r.kernel.org, kernel-janitors@...r.kernel.org
Subject: Re: [PATCH] ASoC: Intel: sof_rt5682: Fix uninitialized variable in
probe
On 4/8/24 02:35, Dan Carpenter wrote:
> Initialize "is_legacy_cpu" to false to prevent an uninitialized variable
> bug.
>
> Fixes: 8efcd4864652 ("ASoC: Intel: sof_rt5682: use common module for sof_card_private initialization")
> Signed-off-by: Dan Carpenter <dan.carpenter@...aro.org>
Good catch.
Acked-by: Pierre-Louis Bossart <pierre-louis.bossart@...ux.intel.com>
> ---
> sound/soc/intel/boards/sof_rt5682.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/sound/soc/intel/boards/sof_rt5682.c b/sound/soc/intel/boards/sof_rt5682.c
> index aadd341a202c..966bcd3e8bdc 100644
> --- a/sound/soc/intel/boards/sof_rt5682.c
> +++ b/sound/soc/intel/boards/sof_rt5682.c
> @@ -606,7 +606,7 @@ static int sof_audio_probe(struct platform_device *pdev)
> {
> struct snd_soc_acpi_mach *mach = pdev->dev.platform_data;
> struct sof_card_private *ctx;
> - bool is_legacy_cpu;
> + bool is_legacy_cpu = false;
> int ret;
>
> if (pdev->id_entry && pdev->id_entry->driver_data)
Powered by blists - more mailing lists