CVE-2024-42089
JSON

5.5medium

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

Severity
5.5medium CVSS:3.1 by NVD
Exploit likelihood
0.23% (higher than 15% of CVEs; EPSS, by FIRST)
Published
Last changed
Assigned by
Linux

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.

Affected

Product or packageVersionsReported by
Linux Linuxfrom 708b4351f08c08ea93f773fb9197bdd3f3b08273 before ae81535ce2503aabc4adab3472f4338070cdeb6a, from 708b4351f08c08ea93f773fb9197bdd3f3b08273 before 8896e18b7c366f8faf9344abfd0971435f1c723a, from 708b4351f08c08ea93f773fb9197bdd3f3b08273 before 3662eb2170e59b58ad479982dc1084889ba757b9, from 708b4351f08c08ea93f773fb9197bdd3f3b08273 before 544ab46b7ece6d6bebbdee5d5659c0a0f804a99a, from 708b4351f08c08ea93f773fb9197bdd3f3b08273 before 8faf91e58425c2f6ce773250dfd995f1c2d461ac, from 708b4351f08c08ea93f773fb9197bdd3f3b08273 before 29bc9e7c75398b0d12fc30955f2e9b2dd29ffaed, from 708b4351f08c08ea93f773fb9197bdd3f3b08273 before 7c18b4d89ff9c810b6e562408afda5ce165c4ea6, from 708b4351f08c08ea93f773fb9197bdd3f3b08273 before 90f3feb24172185f1832636264943e8b5e289245 and 1 more
Not affected: before 3.18, from 4.19.317 up to 4.19.*, from 5.4.279 up to 5.4.*, from 5.10.221 up to 5.10.*, from 5.15.162 up to 5.15.*, from 6.1.97 up to 6.1.*
CVE List
linux linux_kernelfrom 3.18 before 4.19.317, from 4.20 before 5.4.279, from 5.5 before 5.10.221, from 5.11 before 5.15.162, from 5.16 before 6.1.97, from 6.2 before 6.6.37, from 6.7 before 6.9.8, 6.10NVD

Classification

CWE-476

SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial.

What each source says

CVE List

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.

NVD (es)

En el kernel de Linux, se ha resuelto la siguiente vulnerabilidad: ASoC: fsl-asoc-card: establezca priv->pdev antes de usarlo. El puntero priv->pdev se configuró después de usarse en fsl_asoc_card_audmux_init(). Mueva esta asignación al inicio de la función de sonda, para que las subfunciones puedan usar correctamente pdev a través de priv. fsl_asoc_card_audmux_init() elimina la referencia a priv->pdev para obtener acceso a la estructura dev, utilizada con las macros dev_err. Como priv está inicializado en cero, habría una desreferencia del puntero NULL. Tenga en cuenta que si se elimina la referencia a priv->dev antes de la asignación pero nunca se usa, por ejemplo, si no hay ningún error que imprimir, el controlador nofallará probablemente debido a las optimizaciones del compilador.

References

Sources

SourceRecordLicence
CVE ListCVE-2024-42089 changed 2026-05-11CVE Terms of Use
NVDCVE-2024-42089 changed 2026-06-17Public domain