Message ID | 1361003305-1198-1-git-send-email-ying.xue@windriver.com |
---|---|
State | Accepted, archived |
Delegated to: | David Miller |
Headers | show |
From: Ying Xue <ying.xue@windriver.com> Date: Sat, 16 Feb 2013 16:28:25 +0800 > When SOCK_REFCNT_DEBUG is enabled, below build error is met: > > kernel/sysctl_binary.o: In function `sk_refcnt_debug_release': > include/net/sock.h:1025: multiple definition of `sk_refcnt_debug_release' > kernel/sysctl.o:include/net/sock.h:1025: first defined here > kernel/audit.o: In function `sk_refcnt_debug_release': > include/net/sock.h:1025: multiple definition of `sk_refcnt_debug_release' > kernel/sysctl.o:include/net/sock.h:1025: first defined here > make[1]: *** [kernel/built-in.o] Error 1 > make: *** [kernel] Error 2 > > So we decide to make sk_refcnt_debug_release static to eliminate > the error. > > Signed-off-by: Ying Xue <ying.xue@windriver.com> Applied and queued up for -stable, thanks. -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/include/net/sock.h b/include/net/sock.h index 182ca99..25afaa0 100644 --- a/include/net/sock.h +++ b/include/net/sock.h @@ -1037,7 +1037,7 @@ static inline void sk_refcnt_debug_dec(struct sock *sk) sk->sk_prot->name, sk, atomic_read(&sk->sk_prot->socks)); } -inline void sk_refcnt_debug_release(const struct sock *sk) +static inline void sk_refcnt_debug_release(const struct sock *sk) { if (atomic_read(&sk->sk_refcnt) != 1) printk(KERN_DEBUG "Destruction of the %s socket %p delayed, refcnt=%d\n",
When SOCK_REFCNT_DEBUG is enabled, below build error is met: kernel/sysctl_binary.o: In function `sk_refcnt_debug_release': include/net/sock.h:1025: multiple definition of `sk_refcnt_debug_release' kernel/sysctl.o:include/net/sock.h:1025: first defined here kernel/audit.o: In function `sk_refcnt_debug_release': include/net/sock.h:1025: multiple definition of `sk_refcnt_debug_release' kernel/sysctl.o:include/net/sock.h:1025: first defined here make[1]: *** [kernel/built-in.o] Error 1 make: *** [kernel] Error 2 So we decide to make sk_refcnt_debug_release static to eliminate the error. Signed-off-by: Ying Xue <ying.xue@windriver.com> --- include/net/sock.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)