From 770fe4a07caa37cca50d32fb4c218ea63607e34c Mon Sep 17 00:00:00 2001 From: Nico Huber Date: Fri, 4 Nov 2016 15:50:58 +0100 Subject: [PATCH] gma: Use framebuffer size as pipe source size Now that we are going to use scaling and have framebuffer sizes dif- ferent from the display mode's resolution, it's crucial to put the right size (i.e. the unscaled framebuffer size) into PIPESRC. Change-Id: Ieb4b5c3960490e286d44c982c28f7ff729ecd84b Signed-off-by: Nico Huber Reviewed-on: https://review.coreboot.org/17264 Tested-by: Nico Huber Reviewed-by: Arthur Heymans --- common/hw-gfx-gma-pipe_setup.adb | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/common/hw-gfx-gma-pipe_setup.adb b/common/hw-gfx-gma-pipe_setup.adb index e1960ceb9b..2d13a01599 100644 --- a/common/hw-gfx-gma-pipe_setup.adb +++ b/common/hw-gfx-gma-pipe_setup.adb @@ -339,7 +339,10 @@ package body HW.GFX.GMA.Pipe_Setup is begin pragma Debug (Debug.Put_Line (GNAT.Source_Info.Enclosing_Entity)); - Registers.Write (Controller.PIPESRC, Encode (Mode.V_Visible, Mode.H_Visible)); + Registers.Write + (Register => Controller.PIPESRC, + Value => Encode + (Pos16 (Framebuffer.Height), Pos16 (Framebuffer.Width))); if Config.Has_Plane_Control then Setup_Watermarks (Controller);