]> git.ipfire.org Git - thirdparty/util-linux.git/blob - sys-utils/cytune.8
man pages: add "AVAILABILITY" section
[thirdparty/util-linux.git] / sys-utils / cytune.8
1 .\" cytune.8 --
2 .\" Created: Sat Mar 4 17:44:53 1995 by faith@cs.unc.edu
3 .\" Update: Sat Mar 4 18:22:24 1995 by faith@cs.unc.edu
4 .\" Update: Sun Mar 5 06:40:12 1995 by njs@scifi.emi.net
5 .\" Copyright 1995 Rickard E. Faith (faith@cs.unc.edu)
6 .\"
7 .\" Permission is granted to make and distribute verbatim copies of this
8 .\" manual provided the copyright notice and this permission notice are
9 .\" preserved on all copies.
10 .\"
11 .\" Permission is granted to copy and distribute modified versions of this
12 .\" manual under the conditions for verbatim copying, provided that the
13 .\" entire resulting derived work is distributed under the terms of a
14 .\" permission notice identical to this one
15 .\"
16 .\" Since the Linux kernel and libraries are constantly changing, this
17 .\" manual page may be incorrect or out-of-date. The author(s) assume no
18 .\" responsibility for errors or omissions, or for damages resulting from
19 .\" the use of the information contained herein. The author(s) may not
20 .\" have taken the same level of care in the production of this manual,
21 .\" which is licensed free of charge, as they might when working
22 .\" professionally.
23 .\"
24 .\" Formatted or processed versions of this manual, if unaccompanied by
25 .\" the source, must acknowledge the copyright and authors of this work.
26 .\" "
27 .TH CYTUNE 8 " 4 Mar 1995" "" "Linux Programmer's Manual"
28 .SH NAME
29 cytune \- Tune Cyclades driver parameters
30 .SH SYNOPSIS
31 .BI "cytune [-q [-i " interval "]] ([-s " value "]|[-S " value "]) [-g|G] "
32 .BI ([-t " timeout" ]|[-T " timeout" ]) " tty" " [" tty " ...]"
33 .SH DESCRIPTION
34 .B cytune
35 queries and modifies the interruption threshold for the Cyclades driver.
36 Each serial line on a Cyclades card has a 12-byte FIFO for input (and
37 another 12-byte FIFO for output). The "threshold" specifies how many input
38 characters must be present in the FIFO before an interruption is raised.
39 When a Cyclades tty is opened, this threshold is set to a default value
40 based on baud rate:
41 .sp
42 .RS
43 Baud Threshold
44 .sp
45 50-4800 10
46 .br
47 9600 8
48 .br
49 19200 4
50 .br
51 38400 2
52 .br
53 57600-150000 1
54 .RE
55 .PP
56 If the threshold is set too low, the large number of interruptions can load
57 the machine and decrease overall system throughput. If the threshold is set too high, the
58 FIFO buffer can overflow, and characters will be lost. Slower machines,
59 however, may not be able to deal with the interrupt load, and will require
60 that the threshold be adjusted upwards.
61 .PP
62 If the cyclades driver was compiled with
63 .B ENABLE_MONITORING
64 defined, the cytune command can be used with the
65 .B \-q
66 option to report interrupts over the monitoring interval and
67 characters transferred over the monitoring interval. It will also report
68 the state of the FIFO. The maximum number of characters in the FIFO when
69 an interrupt occurred, the instantaneous count of characters in the FIFO,
70 and how many characters are now in the FIFO are reported. This output might
71 look like this:
72 .sp
73 .RS
74 /dev/cubC0: 830 ints, 9130 chars; fifo: 11 threshold, 11 max, 11 now
75 .br
76 166.259866 interrupts/second, 1828.858521 characters/second
77 .RE
78 .PP
79 This output indicates that for this monitoring period, the interrupts were
80 always being handled within one character time, because
81 .B max
82 never rose above
83 .BR threshold .
84 This is good, and you can probably run this way, provided that a large
85 number of samples come out this way. You will lose characters if you
86 overrun the FIFO, as the Cyclades hardware does not seem to support
87 the RTS RS-232 signal line for hardware flow control from the
88 DCE to the DTE.
89 .PP
90 In query mode
91 .B cytune
92 will produce a summary report when ended with
93 a SIGINT or when the threshold or timeout is changed.
94 .PP
95 There may be a responsiveness vs. throughput tradeoff. The Cyclades card,
96 at the higher speeds, is capable of putting a very high interrupt load on the
97 system. This will reduce the amount of CPU time available for other tasks
98 on your system. However, the time it takes to respond to a single character
99 may be increased if you increase the threshold. This might be noticed by
100 monitoring
101 .BR ping (8)
102 times on a SLIP link controlled by a Cyclades card. If your SLIP link is
103 generally used for interactive work such as
104 .BR telnet (1),
105 you may want to leave the threshold low, so that characters are responded
106 to as quickly as possible. If your SLIP link is generally used for file
107 transfer, WWW, and the like, setting the FIFO to a high value is likely to
108 reduce the load on your system while not significantly affecting
109 throughput. Alternatively, see the
110 .B \-t
111 or
112 .B \-T
113 options to adjust the time that the cyclades waits before flushing its
114 buffer. Units are 5ms.
115 .PP
116 If you are running a mouse on a Cyclades port, it is likely that you would
117 want to maintain the threshold and timeout at a low value.
118 .PP
119 .SH OPTIONS
120 .TP
121 .BI \-s " value"
122 Set the current threshold to
123 .I value
124 characters. Note that if the
125 .I tty
126 is not being held open by another process, the threshold will be reset on
127 the next open. Only values between 1 and 12, inclusive, are permitted.
128 .TP
129 .BI \-t " value"
130 Set the current flush timeout to
131 .I value
132 units. Note that if the
133 .I tty
134 is not being held open by another process, the threshold will be reset on
135 the next open. Only values between 0 and 255, inclusive, are permitted.
136 Setting
137 .I value
138 to zero forces the default, currently 0x20 (160ms), but soon to be 0x02
139 (10ms). Units are 5 ms.
140 .TP
141 .B \-g
142 Get the current threshold and timeout.
143 .TP
144 .BI \-T " value"
145 Set the default flush timeout to
146 .I value
147 units. When the
148 .I tty
149 is next opened, this value will be used instead of the default. If
150 .I value
151 is zero, then the the value will default to 0x20 (160ms), soon to be 0x02
152 (10ms).
153 .TP
154 .B \-G
155 Get the default threshold and flush timeout values.
156 .TP
157 .B \-q
158 Gather statistics about the
159 .IR tty .
160 The results are only valid if the Cyclades driver has been compiled with
161 .B ENABLE_MONITORING
162 defined. This is probably not the default.
163 .TP
164 .BI \-i " interval"
165 Statistics will be gathered every
166 .I interval
167 seconds.
168 .SH BUGS
169 If you run two copies of
170 .B cytune
171 at the same time to report statistics about the same port,
172 the 'ints', 'chars', and 'max' value will be reset
173 and not reported correctly.
174 .B cytune
175 should prevent this, but does not.
176 .\" .SH AUTHOR
177 .\" Nick Simicich (njs@scifi.emi.net), with modifications by
178 .\" Rik Faith (faith@cs.unc.edu)
179 .SH FILES
180 .I /dev/ttyC[0-8]
181 .br
182 .I /dev/cubC[0-8]
183 .SH "SEE ALSO"
184 .BR setserial (8)
185 .SH AVAILABILITY
186 The cytune command is part of the util-linux-ng package and is available from
187 ftp://ftp.kernel.org/pub/linux/utils/util-linux-ng/.