From 1b3a0afc758e70007f822f922f146686012b9fd3 Mon Sep 17 00:00:00 2001 From: Gerd Hoffmann Date: Fri, 20 Oct 2017 08:34:37 +0200 Subject: [PATCH 2/4] vga: drop line_offset variable RH-Author: Gerd Hoffmann Message-id: <20171020083439.32712-3-kraxel@redhat.com> Patchwork-id: 77397 O-Subject: [RHV-7.4 qemu-kvm-rhev PATCH 2/4] vga: drop line_offset variable Bugzilla: 1501300 RH-Acked-by: Stefan Hajnoczi RH-Acked-by: Laurent Vivier RH-Acked-by: Miroslav Rezanina Signed-off-by: Gerd Hoffmann (cherry picked from commit 362f811793ff6cb4d209ab61d76cc4f841bb5e46) Signed-off-by: Miroslav Rezanina --- hw/display/vga.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/hw/display/vga.c b/hw/display/vga.c index 086509d..bb301df 100644 --- a/hw/display/vga.c +++ b/hw/display/vga.c @@ -1456,7 +1456,7 @@ static void vga_draw_graphic(VGACommonState *s, int full_update) { DisplaySurface *surface = qemu_console_surface(s->con); int y1, y, update, linesize, y_start, double_scan, mask, depth; - int width, height, shift_control, line_offset, bwidth, bits; + int width, height, shift_control, bwidth, bits; ram_addr_t page0, page1, page_min, page_max; int disp_width, multi_scan, multi_run; uint8_t *d; @@ -1608,7 +1608,6 @@ static void vga_draw_graphic(VGACommonState *s, int full_update) s->cursor_invalidate(s); } - line_offset = s->line_offset; #if 0 printf("w=%d h=%d v=%d line_offset=%d cr[0x09]=0x%02x cr[0x17]=0x%02x linecmp=%d sr[0x01]=0x%02x\n", width, height, v, line_offset, s->cr[9], s->cr[VGA_CRTC_MODE], @@ -1663,7 +1662,7 @@ static void vga_draw_graphic(VGACommonState *s, int full_update) if (!multi_run) { mask = (s->cr[VGA_CRTC_MODE] & 3) ^ 3; if ((y1 & mask) == mask) - addr1 += line_offset; + addr1 += s->line_offset; y1++; multi_run = multi_scan; } else { -- 1.8.3.1