Linux Media Controller development
 help / color / mirror / Atom feed
* [PATCH v5 0/4] media: renesas: Add missing media_entity_cleanup()
@ 2026-07-08 17:08 Biren Pandya
  2026-07-08 17:08 ` [PATCH v5 1/4] media: renesas: rcar-csi2: " Biren Pandya
                   ` (3 more replies)
  0 siblings, 4 replies; 6+ messages in thread
From: Biren Pandya @ 2026-07-08 17:08 UTC (permalink / raw)
  To: niklas.soderlund, mchehab, geert+renesas, magnus.damm,
	Laurent Pinchart, Jacopo Mondi, linux-media, linux-renesas-soc,
	linux-kernel
  Cc: Biren Pandya

This patch series addresses missing media_entity_cleanup() calls across
multiple Renesas platform drivers (rcar-csi2, csisp, rcar-vin, and
rzg2l-cru).

While media_entity_cleanup() is currently a no-op when
CONFIG_MEDIA_CONTROLLER is disabled (and even when enabled in modern
kernels, as pads are rarely dynamically allocated anymore), the media
subsystem guidelines strictly require drivers to call it to prevent future
leaks if the core framework behavior changes.

Changes in v5:
- Removed "in most cases" from all commit messages per Jacopo's review.
- Fixed missing empty line before Signed-off-by across the series.
- Patched the error path in rzg2l_cru_media_init() to properly cleanup
  resources on failure per Jacopo's suggestion.
- Collected Reviewed-by tags from Jacopo Mondi for patches 1/4, 2/4,
  and 3/4.

Changes in v4:
- Formatted commit messages to strictly adhere to the 75-character limit
  per line to resolve checkpatch warnings on the mailing list.
- Removed unwrapped long lines from the commit descriptions.

Changes in v3:
- Addressed maintainer feedback from Jacopo Mondi to fix an unused-label
  compilation error in rcar-csi2.c. The teardown inversion is now handled
  cleanly inside the existing error path without requiring a new label.

Changes in v2:
- Introduced dedicated error labels in probe paths where shared error labels
  previously caused media_entity_cleanup() to be skipped or improperly
  called.


Biren Pandya (4):
  media: renesas: rcar-csi2: Add missing media_entity_cleanup()
  media: renesas: csisp: Add missing media_entity_cleanup()
  media: renesas: rcar-core: Add missing media_entity_cleanup()
  media: renesas: rzg2l-core: Add missing media_entity_cleanup()

 drivers/media/platform/renesas/rcar-csi2.c            | 2 ++
 drivers/media/platform/renesas/rcar-isp/csisp.c       | 6 +++++-
 drivers/media/platform/renesas/rcar-vin/rcar-core.c   | 5 ++++-
 drivers/media/platform/renesas/rzg2l-cru/rzg2l-core.c | 5 +++++
 4 files changed, 16 insertions(+), 2 deletions(-)

-- 
2.50.1 (Apple Git-155)


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

end of thread, other threads:[~2026-07-09  7:12 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-07-08 17:08 [PATCH v5 0/4] media: renesas: Add missing media_entity_cleanup() Biren Pandya
2026-07-08 17:08 ` [PATCH v5 1/4] media: renesas: rcar-csi2: " Biren Pandya
2026-07-08 17:08 ` [PATCH v5 2/4] media: renesas: csisp: " Biren Pandya
2026-07-08 17:08 ` [PATCH v5 3/4] media: renesas: rcar-core: " Biren Pandya
2026-07-08 17:08 ` [PATCH v5 4/4] media: renesas: rzg2l-core: " Biren Pandya
2026-07-09  7:05   ` Jacopo Mondi

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