[PATCH] Fix Specialix SX corruption
authorMarc Zyngier <maz@misterjones.org>
Mon, 27 Feb 2006 11:08:00 +0000 (12:08 +0100)
committerLinus Torvalds <torvalds@g5.osdl.org>
Mon, 27 Feb 2006 16:18:04 +0000 (08:18 -0800)
commitd904ffd6e0c3ab7631b07c21c9f9234a2e72d1f3
treee872c4fcbbf661cccd40d5c414801544c5ef8a5c
parente95a9ec1bb66e07b138861c743192f06e7b3e4de
[PATCH] Fix Specialix SX corruption

With the latest kernels, I experienced some strange corruption, some
'*****' being randomly inserted in the character flow, like this:

ashes:~#
ashes:~#
a*******shes:~#
ashes:~#
ashes:~#

Further investigation shows that the problem was introduced during
Alan's "TTY layer buffering revamp" patch, the amount of data to be
copied being reduced after buffer allocation.  Moving the count fixup
around solves the problem.

Signed-off-by: Marc Zyngier <maz@misterjones.org>
Approved-by: Rogier Wolff <R.E.Wolff@BitWizard.nl>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
drivers/char/sx.c