Skip to content
/ linux Public

Commit df29c2b

Browse files
thesamesamSasha Levin
authored andcommitted
sparc: don't reference obsolete termio struct for TC* constants
[ Upstream commit be0bccf ] Similar in nature to commit ab10727 ("powerpc: Fix struct termio related ioctl macros"). glibc-2.42 drops the legacy termio struct, but the ioctls.h header still defines some TC* constants in terms of termio (via sizeof). Hardcode the values instead. This fixes building Python for example, which falls over like: ./Modules/termios.c:1119:16: error: invalid application of 'sizeof' to incomplete type 'struct termio' Link: https://bugs.gentoo.org/961769 Link: https://bugs.gentoo.org/962600 Signed-off-by: Sam James <sam@gentoo.org> Reviewed-by: Andreas Larsson <andreas@gaisler.com> Signed-off-by: Andreas Larsson <andreas@gaisler.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
1 parent 9a84827 commit df29c2b

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

arch/sparc/include/uapi/asm/ioctls.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@
55
#include <asm/ioctl.h>
66

77
/* Big T */
8-
#define TCGETA _IOR('T', 1, struct termio)
9-
#define TCSETA _IOW('T', 2, struct termio)
10-
#define TCSETAW _IOW('T', 3, struct termio)
11-
#define TCSETAF _IOW('T', 4, struct termio)
8+
#define TCGETA 0x40125401 /* _IOR('T', 1, struct termio) */
9+
#define TCSETA 0x80125402 /* _IOW('T', 2, struct termio) */
10+
#define TCSETAW 0x80125403 /* _IOW('T', 3, struct termio) */
11+
#define TCSETAF 0x80125404 /* _IOW('T', 4, struct termio) */
1212
#define TCSBRK _IO('T', 5)
1313
#define TCXONC _IO('T', 6)
1414
#define TCFLSH _IO('T', 7)

0 commit comments

Comments
 (0)