mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH v2 0/2] cpufreq: mediatek-hw: Fix initialization resource leaks
@ 2026-11-19  5:28 Haoxiang Li
  2026-11-19  5:28 ` [PATCH v2 1/2] cpufreq: mediatek-hw: Release resources when hardware enable fails Haoxiang Li
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Haoxiang Li @ 2026-11-19  5:28 UTC (permalink / raw)
  To: viresh.kumar, rafael
  Cc: zhongqiu.han, hector.yuan, matthias.bgg,
	angelogioacchino.delregno, linux-pm, linux-arm-kernel,
	linux-mediatek, linux-kernel, Haoxiang Li

This series fixes two resource cleanup omissions introduced by commit
d776790a5536 ("cpufreq: mediatek-hw: Fix double devm_remap in hotplug case").

Patch 1 releases the resources when the CPUFreq hardware fails to become
enabled.

Following Zhongqiu's suggestion during review, patch 2 handles the
additional failure path where mtk_cpu_create_freq_table() fails after
the registers have been mapped and the memory region requested.
Thanks to Zhongqiu for pointing out this omission and suggesting a
separate fix.

Changes in v2:
- Keep the original hardware enable failure fix unchanged as patch 1.
- Add patch 2 to clean up on frequency table creation failure, using
  the same Fixes tag.

Haoxiang Li (2):
  cpufreq: mediatek-hw: Release resources when hardware enable fails
  cpufreq: mediatek-hw: Clean up on frequency table creation failure

 drivers/cpufreq/mediatek-cpufreq-hw.c | 31 ++++++++++++++++-----------
 1 file changed, 18 insertions(+), 13 deletions(-)


base-commit: 666539eecdf4db623f5e3c3e55cf9f2dfad24aa4
-- 
2.25.1


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2026-11-19 11:02 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-11-19  5:28 [PATCH v2 0/2] cpufreq: mediatek-hw: Fix initialization resource leaks Haoxiang Li
2026-11-19  5:28 ` [PATCH v2 1/2] cpufreq: mediatek-hw: Release resources when hardware enable fails Haoxiang Li
2026-11-19  5:28 ` [PATCH v2 2/2] cpufreq: mediatek-hw: Clean up on frequency table creation failure Haoxiang Li
2026-11-19 10:23 ` [PATCH v2 0/2] cpufreq: mediatek-hw: Fix initialization resource leaks Zhongqiu Han
2026-11-19 11:02 ` Viresh Kumar

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®