00a65a9b111806ebf5dbef89c3ff6a31bdf0e264
[openwrt/staging/ldir.git] /
1 From 76534156ad6e835ad89135210d565dd5f58e91ab Mon Sep 17 00:00:00 2001
2 From: Dave Stevenson <dave.stevenson@raspberrypi.com>
3 Date: Tue, 11 Feb 2020 15:36:59 +0000
4 Subject: [PATCH] drm/vc4: The check for assigned HVS channels is not
5 applicable firmware_kms
6
7 Channel assignments is only in full KMS, so skip the check
8 if in firmware kms mode.
9
10 Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
11 ---
12 drivers/gpu/drm/vc4/vc4_kms.c | 3 ++-
13 1 file changed, 2 insertions(+), 1 deletion(-)
14
15 --- a/drivers/gpu/drm/vc4/vc4_kms.c
16 +++ b/drivers/gpu/drm/vc4/vc4_kms.c
17 @@ -579,6 +579,7 @@ static int
18 vc4_atomic_check(struct drm_device *dev, struct drm_atomic_state *state)
19 {
20 unsigned long unassigned_channels = GENMASK(NUM_CHANNELS - 1, 0);
21 + struct vc4_dev *vc4 = to_vc4_dev(state->dev);
22 struct drm_crtc_state *crtc_state;
23 struct drm_crtc *crtc;
24 int i, ret;
25 @@ -590,7 +591,7 @@ vc4_atomic_check(struct drm_device *dev,
26 bool is_assigned = false;
27 unsigned int channel;
28
29 - if (!crtc_state->active)
30 + if (!crtc_state->active || vc4->firmware_kms)
31 continue;
32
33 /*