tracing, tty: fix warnings caused by branch tracing and tty_kref_get()
authorIngo Molnar <mingo@elte.hu>
Tue, 25 Nov 2008 07:58:11 +0000 (08:58 +0100)
committerIngo Molnar <mingo@elte.hu>
Tue, 25 Nov 2008 07:59:44 +0000 (08:59 +0100)
Stephen Rothwell reported tht this warning started triggering in
linux-next:

  In file included from init/main.c:27:
  include/linux/tty.h: In function ‘tty_kref_get’:
  include/linux/tty.h:330: warning: ‘______f’ is static but declared in inline function ‘tty_kref_get’ which is not static

Which gcc emits for 'extern inline' functions that nevertheless define
static variables. Change it to 'static inline', which is the norm
in the kernel anyway.

Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
include/linux/tty.h

index 3b8121d4e36ff90aff5c8f7fa9fe3865be0baacc..eaec37c9d83d0a8dbbb87f7f46f1e0557ce00394 100644 (file)
@@ -325,7 +325,7 @@ extern struct class *tty_class;
  *     go away
  */
 
-extern inline struct tty_struct *tty_kref_get(struct tty_struct *tty)
+static inline struct tty_struct *tty_kref_get(struct tty_struct *tty)
 {
        if (tty)
                kref_get(&tty->kref);