hurd-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

address@hidden: [patch] fixed serial handling in gnumach]


From: Roland McGrath
Subject: address@hidden: [patch] fixed serial handling in gnumach]
Date: Sun, 28 Oct 2001 23:42:50 -0500 (EST)

Has anybody tried this patch out on their gnumach?  A good test would be to
hook up your test machine's two serial ports with a null modem cable and
see if you can write data to one and read it from the other at high baud rates.

--- Begin Message --- Subject: [patch] fixed serial handling in gnumach Date: Fri, 19 Oct 2001 21:44:28 +0200 User-agent: Mutt/1.2.5i
Hi,

  I finally fixed gnumach so it can handle sustained transfert on serial
port at higher speed. On my PC works great so I'm posting the patch for any
brave guys who want test it on their PC.

  I hope to see the patch applied to the official gnumach soon, so I don't
have to manually apply to any new version of gnumach.

diff -u -r1.3 chario.c
--- device/chario.c     2001/04/29 20:29:29     1.3
+++ device/chario.c     2001/10/19 19:37:20
@@ -55,8 +55,8 @@
  * is greater than largest tthiwat entry.
  */
 short  tthiwat[NSPEEDS] =
-   { 100,100,100,100,100,100,100,200,200,400,400,400,650,650,1300,2000,
-     2000,2000 };
+   { 100,100,100,100,100,100,100,200,200,400,400,400,650,650,1024,1024,
+     1024,1024 };
 short  ttlowat[NSPEEDS] =
    {  30, 30, 30, 30, 30, 30, 30, 50, 50,120,120,120,125,125, 125, 125,
      125,125 };
@@ -122,8 +122,8 @@
   pdma_timeouts[B2400] = _PR(240);
   pdma_timeouts[B4800] = _PR(480);
   pdma_timeouts[B9600] = _PR(960);
-  pdma_timeouts[EXTA]  = _PR(1440); /* >14400 baud */
-  pdma_timeouts[EXTB]  = _PR(1920); /* >19200 baud */
+  pdma_timeouts[B19200]  = _PR(1920); /* >14400 baud */
+  pdma_timeouts[B38400]  = _PR(3840); /* >19200 baud */
   pdma_timeouts[B57600] = _PR(5760);
   pdma_timeouts[B115200] = _PR(11520);
 
@@ -143,13 +143,21 @@
   pdma_water_mark[B1800] = _PR(180);
   pdma_water_mark[B2400] = _PR(240);
   pdma_water_mark[B4800] = _PR(480);
+  pdma_water_mark[B9600] = _PR(960);
+  pdma_water_mark[B19200] = _PR(1920);
+  pdma_water_mark[B38400] = 192;
+  pdma_water_mark[B57600] = 96;
+  pdma_water_mark[B115200] = 64;
+   
+#if 0   
   i = tty_inq_size/2;
   pdma_water_mark[B9600] = i;
   pdma_water_mark[EXTA]  = i; /* >14400 baud */
   pdma_water_mark[EXTB]  = i; /* >19200 baud */
   pdma_water_mark[B57600] = i;
   pdma_water_mark[B115200] = i;
-
+#endif
+   
   return;
 }
 

-- 
Saluti / Regards

Diego Roversi | diegor at maganet.net
              | diegor at tiscalinet.it 

_______________________________________________
Bug-hurd mailing list
address@hidden
http://mail.gnu.org/mailman/listinfo/bug-hurd

--- End Message ---

reply via email to

[Prev in Thread] Current Thread [Next in Thread]