Re: [PATCH v3] platform/chrome: cros_hps_i2c: fix use-after-free in release() after unbind
From: Tzung-Bi Shih
Date: Fri Nov 13 2026 - 13:10:59 EST
On Fri, Nov 13, 2026 at 07:33:58AM +0000, Chad Aldreda wrote:
> hps_release() finds struct hps_drvdata through file->private_data and
> calls pm_runtime_put() on hps->client->dev. hps comes from
> devm_kzalloc(), so it is freed when the driver is unbound, and a later
> close() of a file opened before the unbind reads freed memory. If the
> client was removed with delete_device, the i2c_client may have been
> freed as well, and pm_runtime_put() runs on it.
>
> [...]
Applied to
https://git.kernel.org/pub/scm/linux/kernel/git/chrome-platform/linux.git for-next
[1/1] platform/chrome: cros_hps_i2c: fix use-after-free in release() after unbind
commit: 2c1aa3d09aad89def46cab40b6c14938833c352e
Thanks!