mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] Move MODULE_ALIAS_LDISC to tty_ldisc.h
@ 2003-09-05  9:22 Russell King
  0 siblings, 0 replies; only message in thread
From: Russell King @ 2003-09-05  9:22 UTC (permalink / raw)
  To: Linux Kernel List, Rusty Russell, Linus Torvalds

While trying to build bk-curr from yesterday, I encounter the following:

  CC      drivers/input/serio/serport.o
drivers/input/serio/serport.c:27: parse error before numeric constant
drivers/input/serio/serport.c:27: warning: type defaults to `int' in declaration of `MODULE_ALIAS_LDISC'
drivers/input/serio/serport.c:27: warning: function declaration isn't a prototype
drivers/input/serio/serport.c:27: warning: data definition has no type or storage class

This seems to be defined in asm-i386/termios.h:

#define MODULE_ALIAS_LDISC(ldisc) \
        MODULE_ALIAS("tty-ldisc-" __stringify(ldisc))

Why is this defined in the per-architecture asm/ header files rather
than the linux/ header files?  It surely can't be something which is
architecture specific.

Here's a patch which moves it to a more sensible location:

===== include/linux/tty_ldisc.h 1.3 vs edited =====
--- 1.3/include/linux/tty_ldisc.h	Wed Feb 19 02:59:04 2003
+++ edited/include/linux/tty_ldisc.h	Fri Sep  5 10:02:02 2003
@@ -138,4 +138,7 @@
 
 #define LDISC_FLAG_DEFINED	0x00000001
 
+#define MODULE_ALIAS_LDISC(ldisc) \
+	MODULE_ALIAS("tty-ldisc-" __stringify(ldisc))
+
 #endif /* _LINUX_TTY_LDISC_H */
===== include/asm-i386/termios.h 1.4 vs edited =====
--- 1.4/include/asm-i386/termios.h	Thu Sep  4 07:40:16 2003
+++ edited/include/asm-i386/termios.h	Fri Sep  5 10:02:02 2003
@@ -102,8 +102,6 @@
 #define user_termios_to_kernel_termios(k, u) copy_from_user(k, u, sizeof(struct termios))
 #define kernel_termios_to_user_termios(u, k) copy_to_user(u, k, sizeof(struct termios))
 
-#define MODULE_ALIAS_LDISC(ldisc) \
-	MODULE_ALIAS("tty-ldisc-" __stringify(ldisc))
 #endif	/* __KERNEL__ */
 
 #endif	/* _I386_TERMIOS_H */
===== include/asm-sparc/termios.h 1.6 vs edited =====
--- 1.6/include/asm-sparc/termios.h	Thu Sep  4 12:16:09 2003
+++ edited/include/asm-sparc/termios.h	Fri Sep  5 10:03:14 2003
@@ -169,9 +169,6 @@
 	0; \
 })
 
-#define MODULE_ALIAS_LDISC(ldisc) \
-	MODULE_ALIAS("tty-ldisc-" __stringify(ldisc))
-
 #endif	/* __KERNEL__ */
 
 #endif /* _SPARC_TERMIOS_H */
===== include/asm-sparc64/termios.h 1.6 vs edited =====
--- 1.6/include/asm-sparc64/termios.h	Thu Sep  4 12:16:09 2003
+++ edited/include/asm-sparc64/termios.h	Fri Sep  5 10:03:14 2003
@@ -168,9 +168,6 @@
 	0; \
 })
 
-#define MODULE_ALIAS_LDISC(ldisc) \
-	MODULE_ALIAS("tty-ldisc-" __stringify(ldisc))
-
 #endif	/* __KERNEL__ */
 
 #endif /* _SPARC64_TERMIOS_H */


-- 
Russell King (rmk@arm.linux.org.uk)	http://www.arm.linux.org.uk/personal/
Maintainer of:
  2.6 ARM Linux   - http://www.arm.linux.org.uk/
  2.6 PCMCIA      - http://pcmcia.arm.linux.org.uk/
  2.6 Serial core



^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2003-09-05  9:22 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-09-05  9:22 [PATCH] Move MODULE_ALIAS_LDISC to tty_ldisc.h Russell King

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome