linux-man.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] termios.3: SPARC architecture has 4 different Bnnn constants
@ 2021-07-31 14:55 Pali Rohár
  2021-08-01 10:55 ` Alejandro Colomar (man-pages)
                   ` (2 more replies)
  0 siblings, 3 replies; 8+ messages in thread
From: Pali Rohár @ 2021-07-31 14:55 UTC (permalink / raw)
  To: linux-man, Alejandro Colomar, G. Branden Robinson, Michael Kerrisk

SPARC is special, it does not have Bnnn constants for baud rates above
2000000. Instead it defines 4 Bnnn constants with smaller baud rates.

This difference between SPARC and non-SPARC architectures is present in
both glibc API (termios.h) and also kernel ioctl API (asm/termbits.h).

Signed-off-by: Pali Rohár <pali@kernel.org>
---
 man3/termios.3 | 23 +++++++++++++++++++++++
 1 file changed, 23 insertions(+)

diff --git a/man3/termios.3 b/man3/termios.3
index 7b195c95912b..2ff8cc80e9eb 100644
--- a/man3/termios.3
+++ b/man3/termios.3
@@ -952,15 +952,38 @@ to by \fItermios_p\fP to \fIspeed\fP, which must be one of these constants:
 	B1000000
 	B1152000
 	B1500000
 	B2000000
+.ft P
+.fi
+.PP
+On SPARC architecture are additionally supported these constants:
+.PP
+.nf
+.ft B
+	B76800
+	B153600
+	B307200
+	B614400
+.ft P
+.fi
+.PP
+On non-SPARC architectures are additionally supported these constants:
+.PP
+.nf
+.ft B
 	B2500000
 	B3000000
 	B3500000
 	B4000000
 .ft P
 .fi
 .PP
+Due to differences between architectures, portable applications should check
+if particular
+.BI B nnn
+constant is defined prior using it.
+.PP
 The zero baud rate, \fBB0\fP,
 is used to terminate the connection.
 If B0 is specified, the modem control lines shall no longer be asserted.
 Normally, this will disconnect the line.
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2021-09-10 22:18 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-07-31 14:55 [PATCH] termios.3: SPARC architecture has 4 different Bnnn constants Pali Rohár
2021-08-01 10:55 ` Alejandro Colomar (man-pages)
2021-08-01 11:22 ` G. Branden Robinson
2021-08-01 12:13   ` Alejandro Colomar (man-pages)
2021-08-04  6:14     ` G. Branden Robinson
2021-09-10 22:17       ` Alejandro Colomar (man-pages)
2021-08-01 11:35 ` [PATCH v2] " Pali Rohár
2021-08-01 12:16   ` Alejandro Colomar (man-pages)

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).