CVE-2025-22084 w1: fix NULL pointer dereference in probe

Medium 5.5 Published Updated

A NULL pointer dereference in the Linux kernel w1 driver can cause a system crash during device probing.

Exploited in the wild
Not known
Login needed
Any signed-in user
Attackable
Local or same network only
Victim action needed
Not needed
Fix
Available

What is CVE-2025-22084?

CVE-2025-22084 is a medium-severity vulnerability in Linux kernel, published on 16 Apr 2025. It can only be exploited from the same machine or local network, with no action from the victim.

Official description

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

w1: fix NULL pointer dereference in probe

The w1_uart_probe() function calls w1_uart_serdev_open() (which includes devm_serdev_device_open()) before setting the client ops via serdev_device_set_client_ops(). This ordering can trigger a NULL pointer dereference in the serdev controller's receive_buf handler, as it assumes serdev->ops is valid when SERPORT_ACTIVE is set.

This is similar to the issue fixed in commit 5e700b384ec1 ("platform/chrome: cros_ec_uart: properly fix race condition") where devm_serdev_device_open() was called before fully initializing the device.

Fix the race by ensuring client ops are set before enabling the port via w1_uart_serdev_open().

Weakness: CWE-476

Which versions are affected by CVE-2025-22084?

It affects 1 product.

Products include Linux kernel.

How do I fix CVE-2025-22084?

Apply the vendor's patch.

Is CVE-2025-22084 being exploited?

There is no known exploitation of CVE-2025-22084 in the wild and no public exploit code.

All Linux kernel vulnerabilities

Sources

Also known as BELL-CVE-2025-22084, DEBIAN-CVE-2025-22084, GHSA-73pc-m2pm-2mr8, UBUNTU-CVE-2025-22084.

Is CVE-2025-22084 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free