linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Hollis Blanchard <hollis@austin.ibm.com>
To: linuxppc-dev@lists.linuxppc.org
Subject: VGA console endian bug
Date: Thu, 9 Aug 2001 11:52:33 -0500	[thread overview]
Message-ID: <20010809115233.D23147@austin.ibm.com> (raw)


These two patches came from Daniel Berlin on July 9. They completely resolve
the VGA console backwards-endian problem for me on PPC. If they have Geert's
seal of approval ;) can they be committed?

-Hollis

--- linuxppc_2_4_devel/include/asm-ppc/vga.h.old	Thu Aug  9 11:49:23 2001
+++ linuxppc_2_4_devel/include/asm-ppc/vga.h	Thu Aug  9 11:49:42 2001
@@ -37,6 +37,9 @@

 #define VT_BUF_HAVE_MEMCPYW
 #define scr_memcpyw	memcpy
+#define VT_BUF_HAVE_MEMCPYF
+#define scr_memcpyw_to memcpy
+#define scr_memcpyw_from memcpy

 #endif /* !CONFIG_VGA_CONSOLE && !CONFIG_MDA_CONSOLE */

--- linuxppc_2_4_devel/drivers/video/fbcon.c.old	Thu Aug  9 11:45:10 2001
+++ linuxppc_2_4_devel/drivers/video/fbcon.c	Thu Aug  9 11:46:23 2001
@@ -2028,13 +2028,13 @@
 	if (!conp->vc_can_do_color)
 	    *p++ ^= 0x0800;
 	else if (conp->vc_hi_font_mask == 0x100) {
-	    u16 a = *p;
+	    u16 a = scr_read(p);
 	    a = ((a) & 0x11ff) | (((a) & 0xe000) >> 4) | (((a) & 0x0e00) << 4);
-	    *p++ = a;
+	    scr_write(a, p++);
 	} else {
-	    u16 a = *p;
+	    u16 a = scr_read(p);
 	    a = ((a) & 0x88ff) | (((a) & 0x7000) >> 4) | (((a) & 0x0700) << 4);
-	    *p++ = a;
+	    scr_write(a, p++);
 	}
 	if (p == (u16 *)softback_end)
 	    p = (u16 *)softback_buf;

** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/

             reply	other threads:[~2001-08-09 16:52 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-08-09 16:52 Hollis Blanchard [this message]
2001-08-10  8:41 ` VGA console endian bug Geert Uytterhoeven
2001-08-10 21:13   ` Hollis Blanchard
2001-08-11  8:33     ` Geert Uytterhoeven
2001-08-11  8:45       ` Olaf Hering
2001-08-11  9:05         ` Olaf Hering
2001-08-11  9:52           ` Geert Uytterhoeven
2001-08-11 10:14             ` Olaf Hering

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=20010809115233.D23147@austin.ibm.com \
    --to=hollis@austin.ibm.com \
    --cc=linuxppc-dev@lists.linuxppc.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).