mailing list of musl libc
 help / color / mirror / code / Atom feed
* [PATCH] fix termios custom speed field names
@ 2015-09-13 16:47 Felix Fietkau
  2015-09-13 16:58 ` Rich Felker
  0 siblings, 1 reply; 2+ messages in thread
From: Felix Fietkau @ 2015-09-13 16:47 UTC (permalink / raw)
  To: musl

Using c_ispeed/c_ospeed is necessary for setting custom baud rates not
covered by the existing defines (via BOTHER).
Rename those fields to match glibc/uClibc.

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
---
 arch/aarch64/bits/termios.h    | 4 ++--
 arch/arm/bits/termios.h        | 4 ++--
 arch/i386/bits/termios.h       | 4 ++--
 arch/microblaze/bits/termios.h | 4 ++--
 arch/mips/bits/termios.h       | 4 ++--
 arch/or1k/bits/termios.h       | 4 ++--
 arch/powerpc/bits/termios.h    | 4 ++--
 arch/sh/bits/termios.h         | 4 ++--
 arch/x32/bits/termios.h        | 4 ++--
 arch/x86_64/bits/termios.h     | 4 ++--
 10 files changed, 20 insertions(+), 20 deletions(-)

diff --git a/arch/aarch64/bits/termios.h b/arch/aarch64/bits/termios.h
index 9265d6f..098322a 100644
--- a/arch/aarch64/bits/termios.h
+++ b/arch/aarch64/bits/termios.h
@@ -6,8 +6,8 @@ struct termios
 	tcflag_t c_lflag;
 	cc_t c_line;
 	cc_t c_cc[NCCS];
-	speed_t __c_ispeed;
-	speed_t __c_ospeed;
+	speed_t c_ispeed;
+	speed_t c_ospeed;
 };
 
 #define VINTR     0
diff --git a/arch/arm/bits/termios.h b/arch/arm/bits/termios.h
index f0d81b1..fcd7f9d 100644
--- a/arch/arm/bits/termios.h
+++ b/arch/arm/bits/termios.h
@@ -6,8 +6,8 @@ struct termios
 	tcflag_t c_lflag;
 	cc_t c_line;
 	cc_t c_cc[NCCS];
-	speed_t __c_ispeed;
-	speed_t __c_ospeed;
+	speed_t c_ispeed;
+	speed_t c_ospeed;
 };
 
 #define VINTR     0
diff --git a/arch/i386/bits/termios.h b/arch/i386/bits/termios.h
index f0d81b1..fcd7f9d 100644
--- a/arch/i386/bits/termios.h
+++ b/arch/i386/bits/termios.h
@@ -6,8 +6,8 @@ struct termios
 	tcflag_t c_lflag;
 	cc_t c_line;
 	cc_t c_cc[NCCS];
-	speed_t __c_ispeed;
-	speed_t __c_ospeed;
+	speed_t c_ispeed;
+	speed_t c_ospeed;
 };
 
 #define VINTR     0
diff --git a/arch/microblaze/bits/termios.h b/arch/microblaze/bits/termios.h
index f0d81b1..fcd7f9d 100644
--- a/arch/microblaze/bits/termios.h
+++ b/arch/microblaze/bits/termios.h
@@ -6,8 +6,8 @@ struct termios
 	tcflag_t c_lflag;
 	cc_t c_line;
 	cc_t c_cc[NCCS];
-	speed_t __c_ispeed;
-	speed_t __c_ospeed;
+	speed_t c_ispeed;
+	speed_t c_ospeed;
 };
 
 #define VINTR     0
diff --git a/arch/mips/bits/termios.h b/arch/mips/bits/termios.h
index 487c1d4..8c4ec62 100644
--- a/arch/mips/bits/termios.h
+++ b/arch/mips/bits/termios.h
@@ -6,8 +6,8 @@ struct termios
 	tcflag_t c_lflag;
 	cc_t c_line;
 	cc_t c_cc[NCCS];
-	speed_t __c_ispeed;
-	speed_t __c_ospeed;
+	speed_t c_ispeed;
+	speed_t c_ospeed;
 };
 
 #define VINTR     0
diff --git a/arch/or1k/bits/termios.h b/arch/or1k/bits/termios.h
index da26644..61f5c6c 100644
--- a/arch/or1k/bits/termios.h
+++ b/arch/or1k/bits/termios.h
@@ -5,8 +5,8 @@ struct termios {
 	tcflag_t c_lflag;
 	cc_t c_line;
 	cc_t c_cc[NCCS];
-	speed_t __c_ispeed;
-	speed_t __c_ospeed;
+	speed_t c_ispeed;
+	speed_t c_ospeed;
 };
 
 #define VINTR     0
diff --git a/arch/powerpc/bits/termios.h b/arch/powerpc/bits/termios.h
index 9f8016c..2cd7f1e 100644
--- a/arch/powerpc/bits/termios.h
+++ b/arch/powerpc/bits/termios.h
@@ -8,8 +8,8 @@ struct termios
 	tcflag_t c_lflag;
 	cc_t c_cc[NCCS];
 	cc_t c_line;
-	speed_t __c_ispeed;
-	speed_t __c_ospeed;
+	speed_t c_ispeed;
+	speed_t c_ospeed;
 };
 
 #define VINTR		0
diff --git a/arch/sh/bits/termios.h b/arch/sh/bits/termios.h
index f0d81b1..fcd7f9d 100644
--- a/arch/sh/bits/termios.h
+++ b/arch/sh/bits/termios.h
@@ -6,8 +6,8 @@ struct termios
 	tcflag_t c_lflag;
 	cc_t c_line;
 	cc_t c_cc[NCCS];
-	speed_t __c_ispeed;
-	speed_t __c_ospeed;
+	speed_t c_ispeed;
+	speed_t c_ospeed;
 };
 
 #define VINTR     0
diff --git a/arch/x32/bits/termios.h b/arch/x32/bits/termios.h
index f0d81b1..fcd7f9d 100644
--- a/arch/x32/bits/termios.h
+++ b/arch/x32/bits/termios.h
@@ -6,8 +6,8 @@ struct termios
 	tcflag_t c_lflag;
 	cc_t c_line;
 	cc_t c_cc[NCCS];
-	speed_t __c_ispeed;
-	speed_t __c_ospeed;
+	speed_t c_ispeed;
+	speed_t c_ospeed;
 };
 
 #define VINTR     0
diff --git a/arch/x86_64/bits/termios.h b/arch/x86_64/bits/termios.h
index f0d81b1..fcd7f9d 100644
--- a/arch/x86_64/bits/termios.h
+++ b/arch/x86_64/bits/termios.h
@@ -6,8 +6,8 @@ struct termios
 	tcflag_t c_lflag;
 	cc_t c_line;
 	cc_t c_cc[NCCS];
-	speed_t __c_ispeed;
-	speed_t __c_ospeed;
+	speed_t c_ispeed;
+	speed_t c_ospeed;
 };
 
 #define VINTR     0
-- 
2.2.2



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

* Re: [PATCH] fix termios custom speed field names
  2015-09-13 16:47 [PATCH] fix termios custom speed field names Felix Fietkau
@ 2015-09-13 16:58 ` Rich Felker
  0 siblings, 0 replies; 2+ messages in thread
From: Rich Felker @ 2015-09-13 16:58 UTC (permalink / raw)
  To: musl

On Sun, Sep 13, 2015 at 06:47:38PM +0200, Felix Fietkau wrote:
> Using c_ispeed/c_ospeed is necessary for setting custom baud rates not
> covered by the existing defines (via BOTHER).
> Rename those fields to match glibc/uClibc.

Did you check that they actually work and match the kernel ABI? I seem
to recallthat on most archs, the kernel ignores them. Since c_* is in
the reserved namespace for this header, exposing these names is ok by
the standard, but I wonder if having non-working fields visible breaks
anything...?

Rich


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

end of thread, other threads:[~2015-09-13 16:58 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-09-13 16:47 [PATCH] fix termios custom speed field names Felix Fietkau
2015-09-13 16:58 ` Rich Felker

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/musl/

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).