All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/2] drm/vc4: Fix memory leak during gpu reset.
@ 2018-11-12 15:01 ` Maarten Lankhorst
  0 siblings, 0 replies; 28+ messages in thread
From: Maarten Lankhorst @ 2018-11-12 15:01 UTC (permalink / raw)
  To: dri-devel; +Cc: intel-gfx, Maarten Lankhorst, Eric Anholt, stable

__drm_atomic_helper_crtc_destroy_state does not free memory, it only
cleans it up. Fix this by calling the functions own destroy function.

Fixes: 6d6e50039187 ("drm/vc4: Allocate the right amount of space for boot-time CRTC state.")
Cc: Eric Anholt <eric@anholt.net>
Cc: <stable@vger.kernel.org> # v4.6+
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
---
 drivers/gpu/drm/vc4/vc4_crtc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/vc4/vc4_crtc.c b/drivers/gpu/drm/vc4/vc4_crtc.c
index 3ce136ba8791..cd226e63d557 100644
--- a/drivers/gpu/drm/vc4/vc4_crtc.c
+++ b/drivers/gpu/drm/vc4/vc4_crtc.c
@@ -999,7 +999,7 @@ static void
 vc4_crtc_reset(struct drm_crtc *crtc)
 {
 	if (crtc->state)
-		__drm_atomic_helper_crtc_destroy_state(crtc->state);
+		vc4_crtc_destroy_state(crtc->state);
 
 	crtc->state = kzalloc(sizeof(struct vc4_crtc_state), GFP_KERNEL);
 	if (crtc->state)
-- 
2.19.1

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

end of thread, other threads:[~2018-11-21 21:06 UTC | newest]

Thread overview: 28+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-11-12 15:01 [PATCH 1/2] drm/vc4: Fix memory leak during gpu reset Maarten Lankhorst
2018-11-12 15:01 ` Maarten Lankhorst
2018-11-12 15:01 ` [PATCH 2/2] drm/atomic: Create and use __drm_atomic_helper_crtc_reset() everywhere Maarten Lankhorst
2018-11-12 15:36   ` Heiko Stuebner
2018-11-12 15:36     ` Heiko Stuebner
2018-11-12 15:36     ` Heiko Stuebner
     [not found]   ` <20181112150114.18395-2-maarten.lankhorst-VuQAYsv1563Yd54FQh9/CA@public.gmane.org>
2018-11-12 15:11     ` Boris Brezillon
2018-11-12 15:23     ` Li, Sun peng (Leo)
2018-11-12 15:23       ` Li, Sun peng (Leo)
2018-11-12 15:23       ` Li, Sun peng (Leo)
2018-11-12 15:36     ` Thierry Reding
2018-11-12 16:02     ` Wentland, Harry
2018-11-12 16:11     ` Sean Paul
2018-11-12 17:33       ` Maarten Lankhorst
2018-11-12 20:01     ` Liviu Dudau
2018-11-12 20:01       ` Liviu Dudau
2018-11-12 20:01       ` Liviu Dudau
2018-11-18 13:31     ` Rodrigo Siqueira
2018-11-21 18:41     ` Lyude Paul
2018-11-12 18:21   ` [Intel-gfx] " Ville Syrjälä
2018-11-20  7:08   ` CK Hu
2018-11-20  7:08     ` CK Hu
2018-11-20  9:30   ` Philipp Zabel
2018-11-21 21:06   ` Kieran Bingham
2018-11-12 15:40 ` ✗ Fi.CI.CHECKPATCH: warning for series starting with [1/2] drm/vc4: Fix memory leak during gpu reset Patchwork
2018-11-12 15:41 ` ✗ Fi.CI.SPARSE: " Patchwork
2018-11-12 15:56 ` ✓ Fi.CI.BAT: success " Patchwork
2018-11-12 17:26 ` ✓ Fi.CI.IGT: " Patchwork

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.