From: Jean-Francois Moine <moinejf@free.fr>
To: Krzysztof Mazur <krzysiek@podlesie.net>
Cc: Alan Cox <alan@linux.intel.com>,
gregkh@linuxfoundation.org, linux-kernel@vger.kernel.org
Subject: Re: vt: regression caused by "Fix line garbage in virtual.."
Date: Tue, 20 Nov 2012 09:54:21 +0100 [thread overview]
Message-ID: <20121120095421.1d4dfa5e@armhf> (raw)
In-Reply-To: <20121119211553.GA29907@shrek.podlesie.net>
On Mon, 19 Nov 2012 22:15:53 +0100
Krzysztof Mazur <krzysiek@podlesie.net> wrote:
> That patch fixed the original issue, but I noticed another artifact
> (I tested only v3.7-rc6 after your fix, I didn't check if the same
> problems exists in v3.7).
>
> After:
>
> for ((i = 0; i < 40; i++)); do
> echo "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA"
> done
> echo -e -n "\x0d\x1b[2@"
>
> (also generated by bash during command line editing, this time by CTRL-r
> + something)
>
> the first character on screen (first column and first row) is cleared.
>
>
> I think it's too late for fixing it in 3.7 and it's better, like Alan
> proposed, to just revert it for now.
Thanks for testing. This time, the fix was easy.
But anyway, as it seems that my patch fixes only the Cubox machine and
as we are still using a kernel 3.5 with specific patches, the fix may
be delayed.
--->8 ---
--- a/drivers/tty/vt/vt.c
+++ b/drivers/tty/vt/vt.c
@@ -539,25 +539,25 @@
{
unsigned short *p = (unsigned short *) vc->vc_pos;
- scr_memmovew(p + nr, p, vc->vc_cols - vc->vc_x);
+ scr_memmovew(p + nr, p, (vc->vc_cols - vc->vc_x) * 2);
scr_memsetw(p, vc->vc_video_erase_char, nr * 2);
vc->vc_need_wrap = 0;
if (DO_UPDATE(vc))
do_update_region(vc, (unsigned long) p,
- (vc->vc_cols - vc->vc_x) / 2 + 1);
+ vc->vc_cols - vc->vc_x);
}
static void delete_char(struct vc_data *vc, unsigned int nr)
{
unsigned short *p = (unsigned short *) vc->vc_pos;
- scr_memcpyw(p, p + nr, vc->vc_cols - vc->vc_x - nr);
+ scr_memcpyw(p, p + nr, (vc->vc_cols - vc->vc_x - nr) * 2);
scr_memsetw(p + vc->vc_cols - vc->vc_x - nr, vc->vc_video_erase_char,
nr * 2);
vc->vc_need_wrap = 0;
if (DO_UPDATE(vc))
do_update_region(vc, (unsigned long) p,
- (vc->vc_cols - vc->vc_x) / 2);
+ vc->vc_cols - vc->vc_x);
}
static int softcursor_original;
--
Ken ar c'hentañ | ** Breizh ha Linux atav! **
Jef | http://moinejf.free.fr/
next prev parent reply other threads:[~2012-11-20 8:54 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-11-18 11:05 vt: regression caused by "Fix line garbage in virtual.." Krzysztof Mazur
2012-11-19 11:38 ` Alan Cox
2012-11-19 19:21 ` Jean-Francois Moine
2012-11-19 21:15 ` Krzysztof Mazur
2012-11-20 8:54 ` Jean-Francois Moine [this message]
2012-11-20 15:20 ` Krzysztof Mazur
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=20121120095421.1d4dfa5e@armhf \
--to=moinejf@free.fr \
--cc=alan@linux.intel.com \
--cc=gregkh@linuxfoundation.org \
--cc=krzysiek@podlesie.net \
--cc=linux-kernel@vger.kernel.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