aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/brcm2708/patches-4.19/950-0615-drm-vc4-firmware-kms-Remove-incorrect-overscan-suppo.patch
blob: 9e365a52759b2b6be121b93e176b5d75ab727ff6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
From 670f61146f51a0fcfc75c9c5920922f94c662f59 Mon Sep 17 00:00:00 2001
From: Dave Stevenson <dave.stevenson@raspberrypi.org>
Date: Fri, 3 May 2019 13:58:03 +0100
Subject: [PATCH 615/725] drm: vc4-firmware-kms: Remove incorrect overscan
 support.

The overscan support was required for the old mailbox API
in order to match up the cursor and frame buffer planes.
With the newer API directly talking to dispmanx there is no
difference, therefore FKMS does not need to make any
adjustments.

Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.org>
---
 drivers/gpu/drm/vc4/vc4_firmware_kms.c | 15 ---------------
 1 file changed, 15 deletions(-)

--- a/drivers/gpu/drm/vc4/vc4_firmware_kms.c
+++ b/drivers/gpu/drm/vc4/vc4_firmware_kms.c
@@ -232,7 +232,6 @@ struct vc4_crtc {
 	void __iomem *regs;
 
 	struct drm_pending_vblank_event *event;
-	u32 overscan[4];
 	bool vblank_enabled;
 	u32 display_number;
 	u32 display_type;
@@ -468,11 +467,6 @@ static void vc4_plane_atomic_update(stru
 		break;
 	}
 
-	if (vc4_crtc) {
-		mb->plane.dst_x += vc4_crtc->overscan[0];
-		mb->plane.dst_y += vc4_crtc->overscan[1];
-	}
-
 	DRM_DEBUG_ATOMIC("[PLANE:%d:%s] plane update %dx%d@%d +dst(%d,%d, %d,%d) +src(%d,%d, %d,%d) 0x%08x/%08x/%08x/%d, alpha %u zpos %u\n",
 			 plane->base.id, plane->name,
 			 mb->plane.width,
@@ -1228,15 +1222,6 @@ static int vc4_fkms_create_screen(struct
 		goto err_destroy_encoder;
 	}
 
-	ret = rpi_firmware_property(vc4->firmware,
-				    RPI_FIRMWARE_FRAMEBUFFER_GET_OVERSCAN,
-				    &vc4_crtc->overscan,
-				    sizeof(vc4_crtc->overscan));
-	if (ret) {
-		DRM_ERROR("Failed to get overscan state: 0x%08x\n", vc4_crtc->overscan[0]);
-		memset(&vc4_crtc->overscan, 0, sizeof(vc4_crtc->overscan));
-	}
-
 	*ret_crtc = vc4_crtc;
 
 	return 0;