doong@rtc.reston.unisys.com (Tom Doong) (03/07/90)
About a week ago I posted a request on how to increase the serial line buffer size on a Sun. I got many requests to pass on the info I learn, but I got very info on how to do it (actually only 2 suggestions). The first suggestion, and probably the best (if you have source license), is to edit zs_asynch.c and change the value, remake your kernel and reboot. The second suggestion is to use the /etc/remote file like tip does. It turns out that there is a capability called fs (frame size) which tip uses to buffer between file system writes when receiving files. You`d probably need the tip source to see how it does the buffering (I assume that it is relatively fast) so that you don't take CPU cycles from your application. I'm still in search of more answers, if you got 'em. -tom doong
guy@uunet.uu.net (Guy Harris) (03/09/90)
>The first suggestion, and probably the best (if you have source license), >is to edit zs_asynch.c and change the value, remake your kernel and >reboot. Actually, there's more to it than that, since the code that maintains the serial line buffer keeps indices to it in an "unsigned char", and thus doesn't have to do any work to have the index go from 255 to 0; if you change the size, you'll have to modify it to explicitly check for the maximum size and wrap around. >The second suggestion is to use the /etc/remote file like tip does. It >turns out that there is a capability called fs (frame size) which tip uses >to buffer between file system writes when receiving files. You`d probably >need the tip source to see how it does the buffering (I assume that it is >relatively fast) so that you don't take CPU cycles from your application. Uh, that doesn't change the size of the serial line buffer, so I assume the question "how do I increase the size of the serial line buffer" really should have been "how do I achieve XXX", with an implicit (and possibly incorrect) assumption that increasing the size of the serial line buffer is the way to achieve XXX. So, what is the XXX here? (BTW, a quick scan of the "tip" source seems to indicate that it doesn't use "fs" for *anything*; it dutifully gets the value from the "/etc/remote" file, or defaults it to BUFSIZ, and then doesn't use it.)