Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 32f71106 authored by Lucas Stach's avatar Lucas Stach Committed by Greg Kroah-Hartman
Browse files

staging: drm/imx: don't drop crtc offsets when doing pageflip



CRTC offsets are only set with the initial modeset, any
subseqent pageflips assume them to be kept the same, so
we need to remember the current state until another modeset
changes it.

Signed-off-by: default avatarPhilipp Zabel <p.zabel@pengutronix.de>
Signed-off-by: default avatarLucas Stach <l.stach@pengutronix.de>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent bc2b067a
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -218,7 +218,8 @@ static irqreturn_t ipu_irq_handler(int irq, void *dev_id)

	if (ipu_crtc->newfb) {
		ipu_crtc->newfb = NULL;
		ipu_plane_set_base(ipu_crtc->plane[0], ipu_crtc->base.fb, 0, 0);
		ipu_plane_set_base(ipu_crtc->plane[0], ipu_crtc->base.fb,
				ipu_crtc->plane[0]->x, ipu_crtc->plane[0]->y);
		ipu_crtc_handle_pageflip(ipu_crtc);
	}

+4 −0
Original line number Diff line number Diff line
@@ -83,6 +83,10 @@ int ipu_plane_set_base(struct ipu_plane *ipu_plane, struct drm_framebuffer *fb,
	ipu_cpmem_set_buffer(cpmem, 0, eba);
	ipu_cpmem_set_buffer(cpmem, 1, eba);

	/* cache offsets for subsequent pageflips */
	ipu_plane->x = x;
	ipu_plane->y = y;

	return 0;
}