[PATCH 00/15] dmaengine: fix device leaks

Johan Hovold posted 15 patches 2 months, 3 weeks ago
drivers/dma/at_hdmac.c           |  9 ++++++--
drivers/dma/bcm-sba-raid.c       |  6 +++++-
drivers/dma/cv1800b-dmamux.c     | 17 +++++++++-------
drivers/dma/dw/rzn1-dmamux.c     |  4 +++-
drivers/dma/idxd/compat.c        | 23 +++++++++++++++++----
drivers/dma/lpc18xx-dmamux.c     | 19 ++++++++++++-----
drivers/dma/lpc32xx-dmamux.c     | 19 ++++++++++++-----
drivers/dma/sh/rz-dmac.c         | 13 ++++++++++--
drivers/dma/stm32/stm32-dmamux.c | 31 +++++++++++++++++-----------
drivers/dma/ti/dma-crossbar.c    | 35 ++++++++++++++++++--------------
drivers/dma/ti/k3-udma-private.c |  2 +-
11 files changed, 123 insertions(+), 55 deletions(-)
[PATCH 00/15] dmaengine: fix device leaks
Posted by Johan Hovold 2 months, 3 weeks ago
The dmaengine drivers pretty consistently failed to release references
taken when looking up devices using of_find_device_by_node() and similar
helpers.

Included are also two OF node leak fixes and a couple of related
cleanups.

Johan


Johan Hovold (15):
  dmaengine: at_hdmac: fix device leak on of_dma_xlate()
  dmaengine: bcm-sba-raid: fix device leak on probe
  dmaengine: cv1800b-dmamux: fix device leak on route allocation
  dmaengine: dw: dmamux: fix OF node leak on route allocation failure
  dmaengine: idxd: fix device leaks on compat bind and unbind
  dmaengine: lpc18xx-dmamux: fix device leak on route allocation
  dmaengine: lpc32xx-dmamux: fix device leak on route allocation
  dmaengine: sh: rz-dmac: fix device leak on probe failure
  dmaengine: stm32: dmamux: fix device leak on route allocation
  dmaengine: stm32: dmamux: fix OF node leak on route allocation failure
  dmaengine: stm32: dmamux: clean up route allocation error labels
  dmaengine: ti: dma-crossbar: fix device leak on dra7x route allocation
  dmaengine: ti: dma-crossbar: fix device leak on am335x route
    allocation
  dmaengine: ti: dma-crossbar: clean up dra7x route allocation error
    paths
  dmaengine: ti: k3-udma: fix device leak on udma lookup

 drivers/dma/at_hdmac.c           |  9 ++++++--
 drivers/dma/bcm-sba-raid.c       |  6 +++++-
 drivers/dma/cv1800b-dmamux.c     | 17 +++++++++-------
 drivers/dma/dw/rzn1-dmamux.c     |  4 +++-
 drivers/dma/idxd/compat.c        | 23 +++++++++++++++++----
 drivers/dma/lpc18xx-dmamux.c     | 19 ++++++++++++-----
 drivers/dma/lpc32xx-dmamux.c     | 19 ++++++++++++-----
 drivers/dma/sh/rz-dmac.c         | 13 ++++++++++--
 drivers/dma/stm32/stm32-dmamux.c | 31 +++++++++++++++++-----------
 drivers/dma/ti/dma-crossbar.c    | 35 ++++++++++++++++++--------------
 drivers/dma/ti/k3-udma-private.c |  2 +-
 11 files changed, 123 insertions(+), 55 deletions(-)

-- 
2.51.0
Re: [PATCH 00/15] dmaengine: fix device leaks
Posted by Vinod Koul 1 month, 3 weeks ago
On Mon, 17 Nov 2025 17:12:42 +0100, Johan Hovold wrote:
> The dmaengine drivers pretty consistently failed to release references
> taken when looking up devices using of_find_device_by_node() and similar
> helpers.
> 
> Included are also two OF node leak fixes and a couple of related
> cleanups.
> 
> [...]

Applied, thanks!

[01/15] dmaengine: at_hdmac: fix device leak on of_dma_xlate()
        commit: b9074b2d7a230b6e28caa23165e9d8bc0677d333
[02/15] dmaengine: bcm-sba-raid: fix device leak on probe
        commit: 7c3a46ebf15a9796b763a54272407fdbf945bed8
[03/15] dmaengine: cv1800b-dmamux: fix device leak on route allocation
        commit: 7bb7d696e0361bbfc1411462c784998cca0afcbb
[04/15] dmaengine: dw: dmamux: fix OF node leak on route allocation failure
        commit: ec25e60f9f95464aa11411db31d0906b3fb7b9f2
[05/15] dmaengine: idxd: fix device leaks on compat bind and unbind
        commit: 799900f01792cf8b525a44764f065f83fcafd468
[06/15] dmaengine: lpc18xx-dmamux: fix device leak on route allocation
        commit: d4d63059dee7e7cae0c4d9a532ed558bc90efb55
[07/15] dmaengine: lpc32xx-dmamux: fix device leak on route allocation
        commit: d9847e6d1d91462890ba297f7888fa598d47e76e
[08/15] dmaengine: sh: rz-dmac: fix device leak on probe failure
        commit: 9fb490323997dcb6f749cd2660a17a39854600cd
[09/15] dmaengine: stm32: dmamux: fix device leak on route allocation
        commit: dd6e4943889fb354efa3f700e42739da9bddb6ef
[10/15] dmaengine: stm32: dmamux: fix OF node leak on route allocation failure
        commit: b1b590a590af13ded598e70f0b72bc1e515787a1
[11/15] dmaengine: stm32: dmamux: clean up route allocation error labels
        commit: 10bf494fd77b34d0749e098c939f85abf52801d1
[12/15] dmaengine: ti: dma-crossbar: fix device leak on dra7x route allocation
        commit: dc7e44db01fc2498644e3106db3e62a9883a93d5
[13/15] dmaengine: ti: dma-crossbar: fix device leak on am335x route allocation
        commit: 4fc17b1c6d2e04ad13fd6c21cfbac68043ec03f9
[14/15] dmaengine: ti: dma-crossbar: clean up dra7x route allocation error paths
        commit: 646ff780338bd7305c9f2fdeb418fdb01623a71c
[15/15] dmaengine: ti: k3-udma: fix device leak on udma lookup
        commit: 430f7803b69cd5e5694e5dfc884c6628870af36e

Best regards,
-- 
~Vinod
Re: [PATCH 00/15] dmaengine: fix device leaks
Posted by Vinod Koul 2 months, 2 weeks ago
On Mon, 17 Nov 2025 17:12:42 +0100, Johan Hovold wrote:
> The dmaengine drivers pretty consistently failed to release references
> taken when looking up devices using of_find_device_by_node() and similar
> helpers.
> 
> Included are also two OF node leak fixes and a couple of related
> cleanups.
> 
> [...]

Applied, thanks!

[01/15] dmaengine: at_hdmac: fix device leak on of_dma_xlate()
        commit: 9324a4dfc4b82ba6ac71d007763b3a34a72ebd70
[02/15] dmaengine: bcm-sba-raid: fix device leak on probe
        commit: 8d5ac0087d5d325bda6c03fe0aecce348b8054d5
[03/15] dmaengine: cv1800b-dmamux: fix device leak on route allocation
        commit: 1941fa42d218cb26eca6cf8ce7443ed4f3849c5a
[04/15] dmaengine: dw: dmamux: fix OF node leak on route allocation failure
        commit: 43cc76e43f8e0be64358945edd6c14f7a9fc39a8
[05/15] dmaengine: idxd: fix device leaks on compat bind and unbind
        commit: 91b3d5a62deaa9f41d272ae0eea10508553f990d
[06/15] dmaengine: lpc18xx-dmamux: fix device leak on route allocation
        commit: 216b4a61613715b254e52bd3079aa44ad8f21734
[07/15] dmaengine: lpc32xx-dmamux: fix device leak on route allocation
        commit: 8805fc665732f93e7db8fca86fa251a0c793a82b
[08/15] dmaengine: sh: rz-dmac: fix device leak on probe failure
        commit: f7e468e72ba4bd81d0dd8d8462c90dfd00791d6b
[09/15] dmaengine: stm32: dmamux: fix device leak on route allocation
        commit: cd624421eddae7bde7dc17b54968891a47b6fce7
[10/15] dmaengine: stm32: dmamux: fix OF node leak on route allocation failure
        commit: f9091986ac4181ca6457e8b2f88fdd37e18e35c4
[11/15] dmaengine: stm32: dmamux: clean up route allocation error labels
        commit: d2e17bfa4a0d57d2bbd2dfccbeaa39351abb0248
[12/15] dmaengine: ti: dma-crossbar: fix device leak on dra7x route allocation
        commit: f6ad296520f0827455f579a786ae5fb1c444a702
[13/15] dmaengine: ti: dma-crossbar: fix device leak on am335x route allocation
        commit: 430f93d80cad5f96cbfeefbf4a9240212230ba82
[14/15] dmaengine: ti: dma-crossbar: clean up dra7x route allocation error paths
        commit: da0bcd6d207d3756ff44ec2185a814728fe641b0
[15/15] dmaengine: ti: k3-udma: fix device leak on udma lookup
        commit: e5bee109658abc4edc8d57c8545c79f130df1b87

Best regards,
-- 
~Vinod