]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/blob - releases/4.9.172/drm-vc4-fix-compilation-error-reported-by-kbuild-test-bot.patch
4.19-stable patches
[thirdparty/kernel/stable-queue.git] / releases / 4.9.172 / drm-vc4-fix-compilation-error-reported-by-kbuild-test-bot.patch
1 From 462ce5d963f18b71c63f6b7730a35a2ee5273540 Mon Sep 17 00:00:00 2001
2 From: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
3 Date: Wed, 24 Apr 2019 17:06:29 +0200
4 Subject: drm/vc4: Fix compilation error reported by kbuild test bot
5
6 From: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
7
8 commit 462ce5d963f18b71c63f6b7730a35a2ee5273540 upstream.
9
10 A pointer to crtc was missing, resulting in the following build error:
11 drivers/gpu/drm/vc4/vc4_crtc.c:1045:44: sparse: sparse: incorrect type in argument 1 (different base types)
12 drivers/gpu/drm/vc4/vc4_crtc.c:1045:44: sparse: expected struct drm_crtc *crtc
13 drivers/gpu/drm/vc4/vc4_crtc.c:1045:44: sparse: got struct drm_crtc_state *state
14 drivers/gpu/drm/vc4/vc4_crtc.c:1045:39: sparse: sparse: not enough arguments for function vc4_crtc_destroy_state
15
16 Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
17 Reported-by: kbuild test robot <lkp@intel.com>
18 Cc: Eric Anholt <eric@anholt.net>
19 Link: https://patchwork.freedesktop.org/patch/msgid/2b6ed5e6-81b0-4276-8860-870b54ca3262@linux.intel.com
20 Fixes: d08106796a78 ("drm/vc4: Fix memory leak during gpu reset.")
21 Cc: <stable@vger.kernel.org> # v4.6+
22 Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>
23 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
24
25 ---
26 drivers/gpu/drm/vc4/vc4_crtc.c | 2 +-
27 1 file changed, 1 insertion(+), 1 deletion(-)
28
29 --- a/drivers/gpu/drm/vc4/vc4_crtc.c
30 +++ b/drivers/gpu/drm/vc4/vc4_crtc.c
31 @@ -846,7 +846,7 @@ static void
32 vc4_crtc_reset(struct drm_crtc *crtc)
33 {
34 if (crtc->state)
35 - vc4_crtc_destroy_state(crtc->state);
36 + vc4_crtc_destroy_state(crtc, crtc->state);
37
38 crtc->state = kzalloc(sizeof(struct vc4_crtc_state), GFP_KERNEL);
39 if (crtc->state)