From: Fabrice Bellard <fabrice@bellard.org>
To: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [Bug][Patch] Cirrus-VGA for Malta
Date: Mon, 24 Sep 2007 23:22:30 +0200 [thread overview]
Message-ID: <46F82A96.1030804@bellard.org> (raw)
In-Reply-To: <46F7F9D6.30802@mail.berlios.de>
I realize that the other pixel formats are buggy too, so at least your
patch is consistent with what is already coded !
I guess the problem is in the VGA memory handlers. Otherwise it means
that there is a (Cirrus)VGA configuration register to change the
endianness of the frame buffer. In such case, it must be emulated correctly.
Regards,
Fabrice.
Stefan Weil wrote:
> Hello,
>
> here is a patch which makes VGA usable for Malta MIPS32 in big endian
> mode. I don't know whether other big endian emulations need a
> patch for VGA, too.
>
> Regards
> Stefan
>
>
>
>
> ------------------------------------------------------------------------
>
> Index: hw/vga_template.h
> ===================================================================
> RCS file: /sources/qemu/qemu/hw/vga_template.h,v
> retrieving revision 1.13
> diff -u -b -B -r1.13 vga_template.h
> --- hw/vga_template.h 11 May 2006 21:54:44 -0000 1.13
> +++ hw/vga_template.h 14 Jun 2007 20:10:25 -0000
> @@ -327,6 +327,16 @@
> palette = s1->last_palette;
> width >>= 3;
> for(x = 0; x < width; x++) {
> +#if defined(TARGET_WORDS_BIGENDIAN)
> + ((PIXEL_TYPE *)d)[3] = palette[s[0]];
> + ((PIXEL_TYPE *)d)[2] = palette[s[1]];
> + ((PIXEL_TYPE *)d)[1] = palette[s[2]];
> + ((PIXEL_TYPE *)d)[0] = palette[s[3]];
> + ((PIXEL_TYPE *)d)[7] = palette[s[4]];
> + ((PIXEL_TYPE *)d)[6] = palette[s[5]];
> + ((PIXEL_TYPE *)d)[5] = palette[s[6]];
> + ((PIXEL_TYPE *)d)[4] = palette[s[7]];
> +#else
> ((PIXEL_TYPE *)d)[0] = palette[s[0]];
> ((PIXEL_TYPE *)d)[1] = palette[s[1]];
> ((PIXEL_TYPE *)d)[2] = palette[s[2]];
> @@ -335,6 +345,7 @@
> ((PIXEL_TYPE *)d)[5] = palette[s[5]];
> ((PIXEL_TYPE *)d)[6] = palette[s[6]];
> ((PIXEL_TYPE *)d)[7] = palette[s[7]];
> +#endif
> d += BPP * 8;
> s += 8;
> }
>
next prev parent reply other threads:[~2007-09-24 21:23 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-03-27 7:16 [Qemu-devel] [patch] More PCI ethernet emulations Ben Taylor
2007-03-28 20:56 ` Stefan Weil
2007-04-02 12:32 ` Thiemo Seufer
[not found] ` <461FA372.6060105@mail.berlios.de>
[not found] ` <20070413163917.GB14303@networkno.de>
[not found] ` <461FBD8E.9010202@weilnetz.de>
[not found] ` <20070413182137.GC14303@networkno.de>
2007-09-24 17:54 ` [Qemu-devel] [Bug][Patch] Cirrus-VGA for Malta Stefan Weil
2007-09-24 21:12 ` Fabrice Bellard
2007-09-24 21:22 ` Fabrice Bellard [this message]
2007-09-25 11:28 ` Derek Fawcus
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=46F82A96.1030804@bellard.org \
--to=fabrice@bellard.org \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).