APPLIED: [SRU][Eoan][PATCH 0/1] Fix the crash of sof driver in the -41 kernel
Khaled Elmously
khalid.elmously at canonical.com
Wed Mar 11 05:47:39 UTC 2020
On 2020-02-22 17:20:53 , Hui Wang wrote:
> BugLink: http://bugs.launchpad.net/bugs/1864061
>
> In the -41 kernel, we introduced a patch from stable kernel, that
> make the sof driver crash, and there is a fix patch in the 5.6-rc1,
> and this fix patch is already in the stable and is merged to focal
> kernel, now we backport this patch to Eoan kernel if -42 doesn't
> introduce this fix patch from stable.
>
> The patch introduced the crash:
> commit 063821115e02229d5fd3de31bad270d5e30aeb41
> Author: Dragos Tarcatu <dragos_tarcatu at mentor.com>
> Date: Mon Dec 9 18:39:38 2019 -0600
>
> ASoC: topology: Check return value for snd_soc_add_dai_link()
>
> BugLink: https://bugs.launchpad.net/bugs/1861929
>
> [ Upstream commit 76d2703649321c296df7ec0dafd50add96215de4 ]
>
> snd_soc_add_dai_link() might fail. This situation occurs for
> instance in a very specific use case where a PCM device and a
> Back End DAI link are given identical names in the topology.
> When this happens, soc_new_pcm_runtime() fails and then
> snd_soc_add_dai_link() returns -ENOMEM when called from
> soc_tplg_fe_link_create(). Because of that, the link will not
> get added into the card list, so any attempt to remove it later
> ends up in a panic.
>
> Fix that by checking the return status and free the memory in case
> of an error.
>
> Reviewed-by: Ranjani Sridharan <ranjani.sridharan at linux.intel.com>
> Signed-off-by: Dragos Tarcatu <dragos_tarcatu at mentor.com>
> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart at linux.intel.com>
> Link: https://lore.kernel.org/r/20191210003939.15752-2-pierre-louis.bossart@linux.intel.com
> Signed-off-by: Mark Brown <broonie at kernel.org>
> Signed-off-by: Sasha Levin <sashal at kernel.org>
> Signed-off-by: Kamal Mostafa <kamal at canonical.com>
> Signed-off-by: Khalid Elmously <khalid.elmously at canonical.com>
>
>
> [Impact]
> During the boot, the sof driver crash because the hdmi_pcm_list
> is not initialized before it is used.
>
> [Fix]
> This bug is fixed in the mainline kernel v5.6-rc1, now backport
> this patch to ubuntu kernel
>
> [Test Case]
> Boot the -41 kernel with this patch added.
> blacklist the snd_soc_skl
> the kernel can boot successfully, and sof driver worked well
>
> [Regression Risk]
> Low, the patches are backported from upstream kernel, and I tested
> this patch on Lenovo and Dell dmic machines. Focal kernel already
> has this patch and works well.
>
>
> Jaroslav Kysela (1):
> ASoC: topology: fix soc_tplg_fe_link_create() - link->dobj
> initialization order
>
> sound/soc/soc-topology.c | 7 ++++---
> 1 file changed, 4 insertions(+), 3 deletions(-)
>
> --
> 2.17.1
>
>
> --
> kernel-team mailing list
> kernel-team at lists.ubuntu.com
> https://lists.ubuntu.com/mailman/listinfo/kernel-team
More information about the kernel-team
mailing list