CVE-2025-38266
Severity CVSS v4.0:
Pending analysis
Type:
Unavailable / Other
Publication date:
10/07/2025
Last modified:
10/07/2025
Description
In the Linux kernel, the following vulnerability has been resolved:<br />
<br />
pinctrl: mediatek: eint: Fix invalid pointer dereference for v1 platforms<br />
<br />
Commit 3ef9f710efcb ("pinctrl: mediatek: Add EINT support for multiple<br />
addresses") introduced an access to the &#39;soc&#39; field of struct<br />
mtk_pinctrl in mtk_eint_do_init() and for that an include of<br />
pinctrl-mtk-common-v2.h.<br />
<br />
However, pinctrl drivers relying on the v1 common driver include<br />
pinctrl-mtk-common.h instead, which provides another definition of<br />
struct mtk_pinctrl that does not contain an &#39;soc&#39; field.<br />
<br />
Since mtk_eint_do_init() can be called both by v1 and v2 drivers, it<br />
will now try to dereference an invalid pointer when called on v1<br />
platforms. This has been observed on Genio 350 EVK (MT8365), which<br />
crashes very early in boot (the kernel trace can only be seen with<br />
earlycon).<br />
<br />
In order to fix this, since &#39;struct mtk_pinctrl&#39; was only needed to get<br />
a &#39;struct mtk_eint_pin&#39;, make &#39;struct mtk_eint_pin&#39; a parameter<br />
of mtk_eint_do_init() so that callers need to supply it, removing<br />
mtk_eint_do_init()&#39;s dependency on any particular &#39;struct mtk_pinctrl&#39;.