mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Russell King <rmk@arm.linux.org.uk>
To: Linux Kernel List <linux-kernel@vger.kernel.org>,
	Rusty Russell <rusty@rustcorp.com.au>,
	Linus Torvalds <torvalds@osdl.org>
Subject: [PATCH] Move MODULE_ALIAS_LDISC to tty_ldisc.h
Date: Fri, 5 Sep 2003 10:22:31 +0100	[thread overview]
Message-ID: <20030905102231.D27623@flint.arm.linux.org.uk> (raw)

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



                 reply	other threads:[~2003-09-05  9:22 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20030905102231.D27623@flint.arm.linux.org.uk \
    --to=rmk@arm.linux.org.uk \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rusty@rustcorp.com.au \
    --cc=torvalds@osdl.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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