All of lore.kernel.org
 help / color / mirror / Atom feed
From: tlb1144@gmx.net
To: qemu-devel@nongnu.org
Subject: [Qemu-devel] [Patch] Cirrus_vgabios: New mode 1024x1536
Date: Tue, 03 Aug 2010 23:50:58 +0200	[thread overview]
Message-ID: <20100803215058.157270@gmx.net> (raw)

If "[Patch] Cirrus_vga: More than 1024 lines" for hw/cirrus_vga.c is used, CRTC Mode Control (CR17) bit 2 can be set to double the number of scanlines to 2048.

In vgabios-0.6c the 1024x768 modes can simply be transformed into additonal 1024x1536 modes. It is only necessary to set CR17 bit 2. For testing, I added non-standard VESA/video modes 0x1a0..0x1a3/0xa0..0xa3 with 1024x1536 pixels.

patch for vgabios-0.6c:

diff -r -u a/clext.c b/clext.c
--- a/clext.c	2009-01-24 11:02:00.000000000 +0100
+++ b/clext.c	2010-07-31 22:07:31.000000000 +0200
@@ -254,6 +254,52 @@
 0xffff
 };
 
+/* 1024x1536x8 */
+unsigned short cseq_1024x1536x8[] = {
+0x0300,0x2101,0x0f02,0x0003,0x0e04,0x1107,
+0x760b,0x760c,0x760d,0x760e,
+0x0412,0x0013,0x2017,
+0x341b,0x341c,0x341d,0x341e,
+0xffff
+};
+unsigned short ccrtc_1024x1536x8[] = {
+0x2911,0xa300,0x7f01,0x7f02,0x8603,0x8304,0x9405,0x2406,0xf507,
+0x6009,0x000c,0x000d,
+0x0310,0xff12,0x8013,0x4014,0xff15,0x2416,0xc717,0xff18,
+0x001a,0x221b,0x001d,
+0xffff
+};
+/* 1024x1536x16 */
+unsigned short cseq_1024x1536x16[] = {
+0x0300,0x2101,0x0f02,0x0003,0x0e04,0x1707,
+0x760b,0x760c,0x760d,0x760e,
+0x0412,0x0013,0x2017,
+0x341b,0x341c,0x341d,0x341e,
+0xffff
+};
+unsigned short ccrtc_1024x1536x16[] = {
+0x2911,0xa300,0x7f01,0x7f02,0x8603,0x8304,0x9405,0x2406,0xf507,
+0x6009,0x000c,0x000d,
+0x0310,0xff12,0x0013,0x4014,0xff15,0x2416,0xc717,0xff18,
+0x001a,0x321b,0x001d,
+0xffff
+};
+/* 1024x768x24 */
+unsigned short cseq_1024x1536x24[] = {
+0x0300,0x2101,0x0f02,0x0003,0x0e04,0x1507,
+0x760b,0x760c,0x760d,0x760e,
+0x0412,0x0013,0x2017,
+0x341b,0x341c,0x341d,0x341e,
+0xffff
+};
+unsigned short ccrtc_1024x1536x24[] = {
+0x2911,0xa300,0x7f01,0x7f02,0x8603,0x8304,0x9405,0x2406,0xf507,
+0x6009,0x000c,0x000d,
+0x0310,0xff12,0x8013,0x4014,0xff15,0x2416,0xc717,0xff18,
+0x001a,0x321b,0x001d,
+0xffff
+};
+
 cirrus_mode_t cirrus_modes[] =
 {
  {0x5f,640,480,8,0x00,
@@ -310,6 +356,19 @@
    cseq_1600x1200x8,cgraph_svgacolor,ccrtc_1600x1200x8,8,
    4,0,0,0,0,0,0,0,0},
 
+ {0xA0,1024,1536,8,0x00,
+   cseq_1024x1536x8,cgraph_svgacolor,ccrtc_1024x1536x8,8,
+   4,0,0,0,0,0,0,0,0},
+ {0xA2,1024,1536,16,0xe1,
+   cseq_1024x1536x16,cgraph_svgacolor,ccrtc_1024x1536x16,16,
+   6,5,11,6,5,5,0,0,0},
+ {0xA1,1024,1536,15,0xf0,
+   cseq_1024x1536x16,cgraph_svgacolor,ccrtc_1024x1536x16,16,
+   6,5,10,5,5,5,0,1,15},
+ {0xA3,1024,1536,24,0xe5,
+   cseq_1024x1536x24,cgraph_svgacolor,ccrtc_1024x1536x24,24,
+   6,8,16,8,8,8,0,0,0},
+
  {0xfe,0,0,0,0,cseq_vga,cgraph_vga,ccrtc_vga,0,
    0xff,0,0,0,0,0,0,0,0},
  {0xff,0,0,0,0,0,0,0,0,
@@ -357,6 +416,14 @@
   0x119, 0x69,
 // 1280x1024x16
   0x11a, 0x75,
+// 1024x1536x8
+  0x1a0, 0xA0,
+// 1024x1536x15
+  0x1a1, 0xA1,
+// 1024x1536x16
+  0x1a2, 0xA2,
+// 1024x1536x24
+  0x1a3, 0xA3,
 // invalid
   0xffff,0xffff
 };
diff -r -u a/vbetables-gen.c b/vbetables-gen.c
--- a/vbetables-gen.c	2009-01-25 16:46:08.000000000 +0100
+++ b/vbetables-gen.c	2010-07-31 22:02:37.000000000 +0200
@@ -76,6 +76,14 @@
 { 2560, 1600, 16                     , 0x18a},
 { 2560, 1600, 24                     , 0x18b},
 { 2560, 1600, 32                     , 0x18c},
+
+      /* Portrait mode for testing > 1024 lines */
+{ 1024, 1536, 8                      , 0x1a0},
+{ 1024, 1536, 15                     , 0x1a1},
+{ 1024, 1536, 16                     , 0x1a2},
+{ 1024, 1536, 24                     , 0x1a3},
+{ 1024, 1536, 32                     , 0x1a4},
+
 { 0, },
 };
 

-- 
GRATIS für alle GMX-Mitglieder: Die maxdome Movie-FLAT!
Jetzt freischalten unter http://portal.gmx.net/de/go/maxdome01

                 reply	other threads:[~2010-08-03 21:51 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=20100803215058.157270@gmx.net \
    --to=tlb1144@gmx.net \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.