All reports
Medium

kernel: ASoC: fsl-asoc-card: set priv-->pdev before using it

Affected versions

Affected versions
Unknown
Fixed version
Not reported
Affected versions
Unknown
Fixed version
Not reported
Affected versions
Unknown
Fixed version
Not reported

Exploitation

CVE-2024-42089

Probability of exploitation in the next 30 days: 0.23%

FIRST EPSS · 2026-11-22

Description

In the Linux kernel, the following vulnerability has been resolved: ASoC: fsl-asoc-card: set priv->pdev before using it priv->pdev pointer was set after being used in fsl_asoc_card_audmux_init(). Move this assignment at the start of the probe function, so sub-functions can correctly use pdev through priv. fsl_asoc_card_audmux_init() dereferences priv->pdev to get access to the dev struct, used with dev_err macros. As priv is zero-initialised, there would be a NULL pointer dereference. Note that if priv->dev is dereferenced before assignment but never used, for example if there is no error to be printed, the driver won't crash probably due to compiler optimisations.

A flaw was found in the fsl-asoc-card driver in the Linux kernel. This issue was fixed by ensuring the priv->pdev pointer is initialized before use. Previously, priv->pdev was used in the fsl_asoc_card_audmux_init() function before being assigned, potentially leading to a NULL pointer dereference and subsequent crashes.