7cdc61becd
vga: fix region calculation
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.22 (GNU/Linux)
iQIcBAABAgAGBQJapl2MAAoJEEy22O7T6HE49uEP/1CDmBqVzijc+2hjygDNb5Fr
bMyzosvXaKQKsV7W01eB7QzrQInfpmR1SppkKJVLvMd/26WbxZJr9NO583uDAFdF
9XVq6Ihvr7agd1Vd7e0jieGi4v3KHXJTCLQ2f1sjfal0oj5w4mrl50QvRKqfbVyp
dL7Hj/3ru0pY9qZ6tBYyb27NHijf0HjVstd7q8RRqlbT02D4yu3a4djxBP412T+v
YVPJPJLensgkfm5+h2j9Gcyg913BKZwlYPvWHoUKFPVvpK3zpE0wIfeTPlXcJe1W
sBy0/AMyJDG/MzZVLhglVq5aCJ3XH7qwqR26UQGlfMLfYsjC5SSZd4AplLBgXlIw
1Zoszjxutv1brQkHIXebEx+7GNAot+xhd1PEDzmoHN9RUH3xGK8zl0hgU9bUpbBf
pYsqImoEeb1bahTq39lW3ZgKw2h3eodBULihKz87ht08kFodMIODt6BD7c3V/CqP
hqEUZO62nQZ3PkWwQkkiCWru5czA80rBvcIsnUJHwCvkSC0YvaduDJ0wFWBeRkyW
yGZzxK9hnMaej1q/WlC/8IkSOOIfHfyMuGDH1e9Ua79XLuglzQnrzn+t1tG1Q3sx
4sdHeCPlqSFjFM1cJYuWW8UaTJIEbj7CQBAYBeh+StRHlZBWXygrEOxB49pwEkXO
eT3YLOSjjk1rD2VMaSoB
=IZPD
-----END PGP SIGNATURE-----
Merge remote-tracking branch 'remotes/kraxel/tags/vga-20180312-pull-request' into staging
7cdc61becd
vga: fix region calculation
# gpg: Signature made Mon 12 Mar 2018 10:59:24 GMT
# gpg: using RSA key 4CB6D8EED3E87138
# gpg: Good signature from "Gerd Hoffmann (work) <kraxel@redhat.com>"
# gpg: aka "Gerd Hoffmann <gerd@kraxel.org>"
# gpg: aka "Gerd Hoffmann (private) <kraxel@gmail.com>"
# Primary key fingerprint: A032 8CFF B93A 17A7 9901 FE7D 4CB6 D8EE D3E8 7138
* remotes/kraxel/tags/vga-20180312-pull-request:
vga: fix region calculation
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
This commit is contained in:
commit
fb5fff1588
@ -1483,6 +1483,8 @@ static void vga_draw_graphic(VGACommonState *s, int full_update)
|
||||
|
||||
region_start = (s->start_addr * 4);
|
||||
region_end = region_start + (ram_addr_t)s->line_offset * height;
|
||||
region_end += width * s->get_bpp(s) / 8; /* scanline length */
|
||||
region_end -= s->line_offset;
|
||||
if (region_end > s->vbe_size) {
|
||||
/* wraps around (can happen with cirrus vbe modes) */
|
||||
region_start = 0;
|
||||
|
Loading…
Reference in New Issue
Block a user