Linux-ARM-Kernel Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v3 0/6] drm/rockchip: Fix error handling and resource leaks in Rockchip DRM drivers
@ 2026-05-09  8:33 Jiaqi
  2026-05-09  8:33 ` [PATCH v3 1/6] drm/rockchip: Fix of_node reference leak in rockchip_drm_encoder_set_crtc_endpoint_id() Jiaqi
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: Jiaqi @ 2026-05-09  8:33 UTC (permalink / raw)
  To: dri-devel
  Cc: Sandy Huang, Heiko Stuebner, David Airlie, Daniel Vetter,
	Philipp Zabel, linux-arm-kernel, linux-rockchip, linux-kernel

This is v3 of the patch series.

Changes in v3:
  - Fixed Content-Transfer-Encoding from base64 to 7bit (was
    incorrectly using Python MIMEText with charset=utf-8)
  - Fixed Message-ID domain to use sender email domain
  - Fixed patch subject format: [PATCH N/6 v2] to [PATCH v3 N/6]

Changes in v2:
  - Patch 3/6: Removed incorrect devm_free_irq() call in error path.
    The IRQ registered via devm_request_irq() is managed by devres
    and must NOT be manually freed.
  - Patch 5/6: Fixed trailing format issue that caused checkpatch ERROR.

This patch series fixes 6 bugs in the Rockchip DRM driver subsystem,
identified through static code analysis and confirmed by technical review.

Summary of fixes:

  Patch 1/6 (Critical): Fix of_node reference leak in
    rockchip_drm_encoder_set_crtc_endpoint_id(). Both success and error
    paths leaked references acquired via of_graph helpers.

  Patch 2/6 (Critical): Fix dangling crtc->state in vop2_crtc_reset().
    kzalloc() failure left crtc->state as a use-after-free pointer.

  Patch 3/6 (High): Fix vop2_create_crtcs() error path cleanup in
    vop2_bind(). Failures returned directly without calling
    vop2_destroy_crtcs(), leaking of_node references. (v2: fixed
    double-free by removing manual devm_free_irq())

  Patch 4/6 (High): Fix vmap address caching in
    rockchip_gem_prime_vmap(). New vmap() results were not saved to
    rk_obj->kvaddr, causing repeated mappings and potential leaks.

  Patch 5/6 (High): Fix leaked vblank event in
    vop_crtc_atomic_disable(). Pending vop->event was warned but never
    sent, causing userspace hangs and vblank reference leaks. (v2:
    fixed checkpatch format error)

  Patch 6/6 (Medium): Check return value of cdn_dp_grf_write() in
    cdn_dp_enable_phy() error path. Ignored return value could leave
    GRF registers in an inconsistent state.

All patches have been verified against checkpatch.pl --strict.

Signed-off-by: Jiaqi <shijiaqi_develop@163.com>



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

end of thread, other threads:[~2026-05-09  8:34 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-05-09  8:33 [PATCH v3 0/6] drm/rockchip: Fix error handling and resource leaks in Rockchip DRM drivers Jiaqi
2026-05-09  8:33 ` [PATCH v3 1/6] drm/rockchip: Fix of_node reference leak in rockchip_drm_encoder_set_crtc_endpoint_id() Jiaqi
2026-05-09  8:33 ` [PATCH v3 2/6] drm/rockchip: Fix dangling crtc->state in vop2_crtc_reset() Jiaqi
2026-05-09  8:33 ` [PATCH v3 3/6] drm/rockchip: Fix vop2_create_crtcs() error path cleanup in vop2_bind() Jiaqi
2026-05-09  8:33 ` [PATCH v3 4/6] drm/rockchip: Fix vmap address caching in rockchip_gem_prime_vmap() Jiaqi
2026-05-09  8:33 ` [PATCH v3 5/6] drm/rockchip: Fix leaked vblank event in vop_crtc_atomic_disable() Jiaqi
2026-05-09  8:34 ` [PATCH v3 6/6] drm/rockchip: Check return value of cdn_dp_grf_write() in error path Jiaqi

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