[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <173858364041.129720.4556770320956186916.b4-ty@linaro.org>
Date: Mon, 03 Feb 2025 12:54:00 +0100
From: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
To: krzk@...nel.org, cj.winklhofer@...il.com,
Chenyuan Yang <chenyuan0y@...il.com>
Cc: linux-kernel@...r.kernel.org, zijie98@...il.com
Subject: Re: [PATCH] w1: fix NULL pointer dereference in probe
On Sat, 11 Jan 2025 12:18:03 -0600, Chenyuan Yang wrote:
> 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.
>
> [...]
Applied, thanks!
[1/1] w1: fix NULL pointer dereference in probe
https://git.kernel.org/krzk/linux-w1/c/0dd6770a72f138dabea9eae87f3da6ffa68f0d06
Best regards,
--
Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
Powered by blists - more mailing lists