CVE-2026-89885 PUBLISHED

media: platform: mtk-mdp3: Fix SCP device refcounting

Assigner: Linux
Reserved: 11.09.2026 Published: 16.09.2026 Updated: 16.09.2026

In the Linux kernel, the following vulnerability has been resolved:

media: platform: mtk-mdp3: Fix SCP device refcounting

mdp_probe() first tries to get the SCP handle with scp_get(). When that fails, it falls back to looking up the SCP platform device with __get_pdev_by_id() and then reads its driver data.

The fallback lookup returns the platform device with a reference, just like scp_get() does. However, the fallback path currently drops that reference immediately after platform_get_drvdata(). The driver later still calls scp_put(mdp->scp) unconditionally from the probe error path and from mdp_video_device_release(), which drops the SCP device reference again.

Keep the fallback reference until the existing scp_put() call, so that the fallback path follows the same ownership rules as the scp_get() path.

Metrics

CVSS Vector: CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
CVSS Score: 8.4

AV:L - The extra put_device is in mdp_probe()/mdp_video_device_release of the MediaTek MDP3 platform driver, reached only via local driver-model bind on MT8183/MT8195 (boot, deferred probe, module load, or sysfs rebind). No network, Bluetooth/Wi-Fi, or USB path reaches this SCP refcounting. AC:L - On MT8183 the MDP RDMA node has no mediatek,scp phandle, so scp_get() fails and the compatible fallback is the production path. That path drops the of_find_device_by_node() ref then later scp_put() extra-puts; cmdq mailbox EPROBE_DEFER after the fallback makes this deterministic with no race. PR:N - mdp_probe() runs in driver-core context with no capable() or credential check. On MediaTek Chromebooks, phones, and embedded boards, MDP3 commonly deferred-probes at boot after the SCP fallback, so the extra put fires without a user account. UI:N - Platform probe and deferred-probe retries run unattended at boot or module bind on affected hardware. Opening /dev/video, mounting a filesystem, or plugging a device is not required. S:U - The extra put_device() use-after-free is of the host SCP platform_device inside the same kernel security authority. It does not cross a VM, IOMMU/DMA, or sandbox boundary. C:H - scp_put() extra-puts the SCP platform_device, which can run device_release and free the still-bound struct device. A use-after-free of that object enables reclaim and kernel-memory disclosure. I:H - The same device UAF is heap corruption of struct platform_device/mtk_scp still used by the SCP driver and other scp_get() holders, enabling heap spray, arbitrary write, and control-flow hijack. A:H - Freeing the SCP device while it remains registered, or later dereferencing the dangling scp pointer from MDP3/vcodec, causes a kernel oops or panic.

Product Status

Vendor Linux
Product Linux
Versions Default: unaffected
  • affected from db4d27e6bbbf511f9cdb33f682535a0a3cb7c403 to dce13bd9bade3ecc1acb7579397f24743850997f (excl.)
  • affected from 31ba1a4d7a5d9466f6ef4910a372b8200f8aad19 to 252850653569fdb1a259937e02325cf32c8f0970 (excl.)
  • affected from 8f6f3aa21517ef34d50808af0c572e69580dca20 to 0259ade4c4ceaf1e184a7c1aea8071ad398f9b6f (excl.)
  • affected from 8f6f3aa21517ef34d50808af0c572e69580dca20 to 55793e4665b7f15151e6f5ab51ca980e73abed5d (excl.)
  • affected from 6.12.64 to 6.12.110 (excl.)
  • affected from 6.18.4 to 6.18.51 (excl.)
Vendor Linux
Product Linux
Versions Default: affected
  • Version 6.19 is affected
  • unaffected from 0 to 6.19 (excl.)
  • unaffected from 6.12.110 to 6.12.* (incl.)
  • unaffected from 6.18.51 to 6.18.* (incl.)
  • unaffected from 7.2.5 to 7.2.* (incl.)
  • unaffected from 7.3-rc1 to * (incl.)

References