public inbox for linux-arm-kernel@lists.infradead.org
 help / color / mirror / Atom feed
* [PATCH V2 0/2] Fix two memory leaks in rproc_attach()
@ 2025-04-26  6:53 Xiaolei Wang
  2025-04-26  6:53 ` [PATCH V2 1/2] remoteproc: imx_rproc: release carveout under imx_rproc after rproc_attach() fails Xiaolei Wang
  2025-04-26  6:53 ` [PATCH V2 2/2] remoteproc: core: release rproc->clean_table " Xiaolei Wang
  0 siblings, 2 replies; 13+ messages in thread
From: Xiaolei Wang @ 2025-04-26  6:53 UTC (permalink / raw)
  To: andersson, mathieu.poirier, shawnguo, s.hauer, kernel, festevam,
	xiaolei.wang
  Cc: linux-remoteproc, imx, linux-arm-kernel, linux-kernel

In the rproc_attach() function, if rproc_handle_resources() returns
failure, if the rproc->ops->unprepare callback function is not set,
the resources allocated by rproc_prepare_device() cannot be released,
and rproc->clean_table should also be released

patch1 adds rproc->ops->unprepare callback function to imx_rproc
patch2 releases rproc->clean_table

Changes in v2:
    Updated the commit log of these two patches
    Link to v1: https://patchwork.kernel.org/project/linux-remoteproc/patch/20250424122252.2777363-1-xiaolei.wang@windriver.com/
                https://patchwork.kernel.org/project/linux-remoteproc/patch/20250424122252.2777363-2-xiaolei.wang@windriver.com/

Xiaolei Wang (2):
  remoteproc: imx_rproc: release carveout under imx_rproc after
    rproc_attach() fails
  remoteproc: core: release rproc->clean_table after rproc_attach()
    fails

 drivers/remoteproc/imx_rproc.c       | 14 ++++++++++++++
 drivers/remoteproc/remoteproc_core.c |  1 +
 2 files changed, 15 insertions(+)

-- 
2.25.1



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

end of thread, other threads:[~2025-04-29 22:50 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-04-26  6:53 [PATCH V2 0/2] Fix two memory leaks in rproc_attach() Xiaolei Wang
2025-04-26  6:53 ` [PATCH V2 1/2] remoteproc: imx_rproc: release carveout under imx_rproc after rproc_attach() fails Xiaolei Wang
2025-04-26 13:18   ` Peng Fan
2025-04-26 13:46     ` xiaolei wang
2025-04-26 20:14       ` Mathieu Poirier
2025-04-27  0:11         ` xiaolei wang
2025-04-27  2:30           ` Peng Fan
2025-04-28 16:49   ` Mathieu Poirier
2025-04-29  2:19     ` Xiaolei Wang
2025-04-26  6:53 ` [PATCH V2 2/2] remoteproc: core: release rproc->clean_table " Xiaolei Wang
2025-04-29  2:20   ` Xiaolei Wang
2025-04-29 17:30     ` Mathieu Poirier
2025-04-29 22:47       ` xiaolei wang

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