From be4221d993cc15d3a14ca01181818ba5c41d5ab5 Mon Sep 17 00:00:00 2001 From: Mark Cave-Ayland Date: Wed, 5 Apr 2017 09:02:46 +0100 Subject: [PATCH] cg3: fix up size parameter for memory_region_get_dirty() The code was incorrectly calculating the end address rather than the size of the required region. Signed-off-by: Mark Cave-Ayland Reviewed-by: Gerd Hoffmann --- hw/display/cg3.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/display/cg3.c b/hw/display/cg3.c index 7d436945e9..b42f60e201 100644 --- a/hw/display/cg3.c +++ b/hw/display/cg3.c @@ -114,7 +114,7 @@ static void cg3_update_display(void *opaque) int update = s->full_update; page = y * width; - update |= memory_region_get_dirty(&s->vram_mem, page, page + width, + update |= memory_region_get_dirty(&s->vram_mem, page, width, DIRTY_MEMORY_VGA); if (update) { if (y_start < 0) { -- GitLab