bcm27xx: add support for linux v5.15
[openwrt/staging/chunkeey.git] / target / linux / bcm27xx / patches-5.15 / 950-0173-drm-v3d-Delete-pm_runtime-support.patch
1 From 5154d39501380fa5680aea0fab0c3f3f2337fe1f Mon Sep 17 00:00:00 2001
2 From: Phil Elwell <phil@raspberrypi.org>
3 Date: Wed, 18 Sep 2019 17:22:36 +0100
4 Subject: [PATCH] drm/v3d: Delete pm_runtime support
5
6 The pm_runtime was blocking changelist submission, so delete it as a
7 temporary workaround.
8
9 Signed-off-by: Phil Elwell <phil@raspberrypi.org>
10 ---
11 drivers/gpu/drm/v3d/v3d_gem.c | 5 -----
12 drivers/gpu/drm/v3d/v3d_mmu.c | 11 -----------
13 2 files changed, 16 deletions(-)
14
15 --- a/drivers/gpu/drm/v3d/v3d_gem.c
16 +++ b/drivers/gpu/drm/v3d/v3d_gem.c
17 @@ -485,10 +485,6 @@ v3d_job_init(struct v3d_dev *v3d, struct
18 job->v3d = v3d;
19 job->free = free;
20
21 - ret = pm_runtime_get_sync(v3d->drm.dev);
22 - if (ret < 0)
23 - return ret;
24 -
25 xa_init_flags(&job->deps, XA_FLAGS_ALLOC);
26
27 ret = drm_syncobj_find_fence(file_priv, in_sync, 0, 0, &in_fence);
28 @@ -505,7 +501,6 @@ v3d_job_init(struct v3d_dev *v3d, struct
29 return 0;
30 fail:
31 xa_destroy(&job->deps);
32 - pm_runtime_put_autosuspend(v3d->drm.dev);
33 return ret;
34 }
35
36 --- a/drivers/gpu/drm/v3d/v3d_mmu.c
37 +++ b/drivers/gpu/drm/v3d/v3d_mmu.c
38 @@ -36,14 +36,6 @@ static int v3d_mmu_flush_all(struct v3d_
39 {
40 int ret;
41
42 - /* Keep power on the device on until we're done with this
43 - * call, but skip the flush if the device is off and will be
44 - * reset when powered back on.
45 - */
46 - ret = pm_runtime_get_if_in_use(v3d->dev);
47 - if (ret == 0)
48 - return 0;
49 -
50 /* Make sure that another flush isn't already running when we
51 * start this one.
52 */
53 @@ -71,9 +63,6 @@ static int v3d_mmu_flush_all(struct v3d_
54 if (ret)
55 dev_err(v3d->drm.dev, "MMUC flush wait idle failed\n");
56
57 - pm_runtime_mark_last_busy(v3d->dev);
58 - pm_runtime_put_autosuspend(v3d->dev);
59 -
60 return ret;
61 }
62