* Re: [Linux-ia64] new problem with memcpy_mck routines
2002-07-19 2:56 [Linux-ia64] new problem with memcpy_mck routines Alex Williamson
@ 2002-07-19 16:37 ` Jesse Barnes
2002-07-24 23:59 ` Chen, Kenneth W
2002-07-26 16:42 ` David Mosberger
2 siblings, 0 replies; 4+ messages in thread
From: Jesse Barnes @ 2002-07-19 16:37 UTC (permalink / raw)
To: linux-ia64
I've run into this too on the console of the McKinley SDV machines. A
Control-L cleans it up, but it's really annoying nonetheless.
Jesse
On Thu, Jul 18, 2002 at 08:56:48PM -0600, Alex Williamson wrote:
>
> Using the latest memcpy_mck (20020622 + Ken's 7/10 patch) I'm seeing
> problems with screen corruption on VGA. Here's the test; on a VGA
> console, start vim (colorized syntax highlighting and all), edit a
> large file (several screens). Scroll down through the file. You'll
> notice the screen gets corrupted, appears to be columns down the screen
> that scroll faster than others. I'm using an HP McKinley system and
> have light switched tested by building w/ the old Itanium routines.
> Other apps like less, nvi, etc... don't seem to trigger this. Thanks,
>
> Alex
>
>
> _______________________________________________
> Linux-IA64 mailing list
> Linux-IA64@linuxia64.org
> http://lists.linuxia64.org/lists/listinfo/linux-ia64
^ permalink raw reply [flat|nested] 4+ messages in thread
* RE: [Linux-ia64] new problem with memcpy_mck routines
2002-07-19 2:56 [Linux-ia64] new problem with memcpy_mck routines Alex Williamson
2002-07-19 16:37 ` Jesse Barnes
@ 2002-07-24 23:59 ` Chen, Kenneth W
2002-07-26 16:42 ` David Mosberger
2 siblings, 0 replies; 4+ messages in thread
From: Chen, Kenneth W @ 2002-07-24 23:59 UTC (permalink / raw)
To: linux-ia64
It turns out that the screen corruption that Jesse and Alex saw was due to a
bug in generic console vga code. The scrup() functions uses memcpy to copy
overlapping memory area. By definition, memcpy() must not be used for
overlapping memory areas. This patch changed that to memmove() which
handles overlapping areas gracefully. This also fixes the same screen
corruption when switching from X server to text mode.
There is nothing wrong with new memcpy function.
--- drivers/char/console.c.orig Wed Jul 24 14:47:20 2002
+++ drivers/char/console.c Wed Jul 24 14:47:55 2002
@@ -259,7 +259,7 @@
return;
d = (unsigned short *) (origin+video_size_row*t);
s = (unsigned short *) (origin+video_size_row*(t+nr));
- scr_memcpyw(d, s, (b-t-nr) * video_size_row);
+ scr_memmovew(d, s, (b-t-nr) * video_size_row);
scr_memsetw(d + (b-t-nr) * video_num_columns, video_erase_char,
video_size_row*nr);
}
One other question, who is the maintainer for the console code? This should
go into the base as it is not ia64 specific and could potentially trigger on
other architectures.
- Ken Chen
-----Original Message-----
From: Jesse Barnes [mailto:jbarnes@sgi.com]
Sent: Friday, July 19, 2002 9:37 AM
To: alex_williamson@hp.com
Cc: IA64 mailinglist; Chen, Kenneth W
Subject: Re: [Linux-ia64] new problem with memcpy_mck routines
I've run into this too on the console of the McKinley SDV machines. A
Control-L cleans it up, but it's really annoying nonetheless.
Jesse
On Thu, Jul 18, 2002 at 08:56:48PM -0600, Alex Williamson wrote:
>
> Using the latest memcpy_mck (20020622 + Ken's 7/10 patch) I'm seeing
> problems with screen corruption on VGA. Here's the test; on a VGA
> console, start vim (colorized syntax highlighting and all), edit a
> large file (several screens). Scroll down through the file. You'll
> notice the screen gets corrupted, appears to be columns down the screen
> that scroll faster than others. I'm using an HP McKinley system and
> have light switched tested by building w/ the old Itanium routines.
> Other apps like less, nvi, etc... don't seem to trigger this. Thanks,
>
> Alex
^ permalink raw reply [flat|nested] 4+ messages in thread
* RE: [Linux-ia64] new problem with memcpy_mck routines
2002-07-19 2:56 [Linux-ia64] new problem with memcpy_mck routines Alex Williamson
2002-07-19 16:37 ` Jesse Barnes
2002-07-24 23:59 ` Chen, Kenneth W
@ 2002-07-26 16:42 ` David Mosberger
2 siblings, 0 replies; 4+ messages in thread
From: David Mosberger @ 2002-07-26 16:42 UTC (permalink / raw)
To: linux-ia64
>>>>> On Wed, 24 Jul 2002 16:59:37 -0700, "Chen, Kenneth W" <kenneth.w.chen@intel.com> said:
Ken> It turns out that the screen corruption that Jesse and Alex saw
Ken> was due to a bug in generic console vga code. The scrup()
Ken> functions uses memcpy to copy overlapping memory area. By
Ken> definition, memcpy() must not be used for overlapping memory
Ken> areas. This patch changed that to memmove() which handles
Ken> overlapping areas gracefully. This also fixes the same screen
Ken> corruption when switching from X server to text mode.
Ken> There is nothing wrong with new memcpy function.
Ah, that's good! Thanks for confirming this.
Ken> One other question, who is the maintainer for the console code?
Ken> This should go into the base as it is not ia64 specific and
Ken> could potentially trigger on other architectures.
Have you tried Martin Mares? He is listed as SVGA maintainer and has
at least on occasion hacked on that file. In any case, I'd definitely
cc lkml so that others can see this report, too.
--david
^ permalink raw reply [flat|nested] 4+ messages in thread