My ltmodem patch

dnell <[email protected]> Wed, 2 Nov 2011 07:44:31 +0200
Newsgroups gmane.linux.linmodem
Message-ID <[email protected]>
------a8P4fDEW-Nx2KzBI2wtgo5AgI:1320035971
Content-Type: text/plain; charset=US-ASCII

Hi to all.  Some long time I use Lucent modem and ltmodem-*
packages with Linux. In common they work, but... When I had
compare the modem performance with Windows, it is significantly
better than with Linux. With both systems the modem report
nearly same "connection speed" (for example 48000 bits per
second), but the resulting speed of (tcp/ip) network transfers
with Linux are significantly less (for example, it is about 4
KByte per second (what corresponds 3600 Kbit per second) but
usually ever less and about 3KB per second) than with Windows
(which are 5 KBytes per second and the better "responsiveness").
I explore the problem and found the cause. It is (for now) in
open source v8250 module (but the problem are from long past
time). I think, that the driver and the module are really too
big, and ever the driver contains some surplus code and data...
In short, I correct the v8250.c file and the network performance
of my Linux system become significantly better. In common the
download speed as reported by the downloader go up about 1.5
times. In other cases, I think as the modem compression take
significant effect, the speed go up ever more, about 3 - 4
times.


For now, I use Linux 2.6.35 kernel and modified
ltmodem-20100102. The patch are here (the most of it are some my
comments, which may be yet some errorneous, but... :-) Excuse
me). There are one line of real code.

------a8P4fDEW-Nx2KzBI2wtgo5AgI:1320035971
Content-Type: text/plain; name="patch"
Content-Disposition: attachment
Content-Transfer-Encoding: base64

KioqIGx0bW9kZW0tMjAxMDAxMDIvdjgyNTAuYwlXZWQgRmViICAzIDAzOjA3OjQ4IDIwMTAKLS0t
IGx0bW9kZW0tMjAxMDAxMDItcWxtb2RpZi92ODI1MC5jCVN1biBPY3QgMjMgMDE6MDc6MDcgMjAx
MQoqKioqKioqKioqKioqKioKKioqIDE4NiwxOTAgKioqKgogICNlbmRpZgogIAl1bnNpZ25lZCBj
aGFyIGNoLCBsc3IgPSAqc3RhdHVzOwohIAlpbnQgbWF4X2NvdW50ID0gMjU2OwogIAljaGFyIGZs
YWc7CiAgCi0tLSAxODYsMTkwIC0tLS0KICAjZW5kaWYKICAJdW5zaWduZWQgY2hhciBjaCwgbHN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