Re: [PATCH 3/5] net: gianfar: fix device leak when querying time stamp info
From: Simon Horman <horms@kernel.org>
Date: 2025-07-26 20:49:37
Also in:
lkml, stable
From: Simon Horman <horms@kernel.org>
Date: 2025-07-26 20:49:37
Also in:
lkml, stable
On Fri, Jul 25, 2025 at 07:12:11PM +0200, Johan Hovold wrote:
Make sure to drop the reference to the ptp device taken by
of_find_device_by_node() when querying the time stamping capabilities.
Note that holding a reference to the ptp device does not prevent its
driver data from going away.
Fixes: 7349a74ea75c ("net: ethernet: gianfar_ethtool: get phc index through drvdata")
Cc: stable@vger.kernel.org # 4.18
Cc: Yangbo Lu <yangbo.lu@nxp.com>
Signed-off-by: Johan Hovold <johan@kernel.org>Reviewed-by: Simon Horman <horms@kernel.org>