linux/drivers/clk/keystone
Johan Hovold 3dfe2e1531 clk: keystone: syscon-clk: fix regmap leak on probe failure
commit 9c75986a29 upstream.

The mmio regmap allocated during probe is never freed.

Switch to using the device managed allocator so that the regmap is
released on probe failures (e.g. probe deferral) and on driver unbind.

Fixes: a250cd4c19 ("clk: keystone: syscon-clk: Do not use syscon helper to build regmap")
Cc: stable@vger.kernel.org	# 6.15
Cc: Andrew Davis <afd@ti.com>
Signed-off-by: Johan Hovold <johan@kernel.org>
Signed-off-by: Stephen Boyd <sboyd@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
History 2026-01-02 12:57:05 +01:00
..
gate.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
Kconfig treewide: replace '---help---' in Kconfig files with 'help' 2020-06-14 01:57:21 +09:00
Makefile clk: keystone: Add new driver to handle syscon based clocks 2020-03-20 17:07:21 -07:00
pll.c clk: keystone: pll: fix a couple NULL vs IS_ERR() checks 2023-10-18 17:52:55 -07:00
sci-clk.c clk: keystone: sci-clk: use devm_kmemdup_array() 2025-09-19 22:30:01 -07:00
syscon-clk.c clk: keystone: syscon-clk: fix regmap leak on probe failure 2026-01-02 12:57:05 +01:00