drm: vc4-firmware-kms: Remove incorrect overscan support.
authorDave Stevenson <dave.stevenson@raspberrypi.org>
Fri, 3 May 2019 12:58:03 +0000 (13:58 +0100)
committerpopcornmix <popcornmix@gmail.com>
Thu, 13 Jun 2019 10:54:31 +0000 (11:54 +0100)
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

index 30d1a50..2ca0f8e 100644 (file)
@@ -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(struct drm_plane *plane,
                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 device *dev, struct drm_device *drm,
                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;