From: Thomas Graf Date: Wed, 29 Jul 2015 07:45:40 +0000 (+0200) Subject: lwtunnel: Make lwtun_encaps[] static X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=92a99bf3bae7c1267db87bb3e3babda2c6dcc8a7;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git lwtunnel: Make lwtun_encaps[] static Any external user should use the registration API instead of accessing this directly. Cc: Roopa Prabhu Signed-off-by: Thomas Graf Acked-by: Roopa Prabhu Signed-off-by: David S. Miller --- diff --git a/include/net/lwtunnel.h b/include/net/lwtunnel.h index b02039081b04..33bd30963a95 100644 --- a/include/net/lwtunnel.h +++ b/include/net/lwtunnel.h @@ -31,9 +31,6 @@ struct lwtunnel_encap_ops { int (*cmp_encap)(struct lwtunnel_state *a, struct lwtunnel_state *b); }; -extern const struct lwtunnel_encap_ops __rcu * - lwtun_encaps[LWTUNNEL_ENCAP_MAX+1]; - #ifdef CONFIG_LWTUNNEL static inline struct lwtunnel_state * lwtstate_get(struct lwtunnel_state *lws) diff --git a/net/core/lwtunnel.c b/net/core/lwtunnel.c index 5f7fae70ef68..c240c895b319 100644 --- a/net/core/lwtunnel.c +++ b/net/core/lwtunnel.c @@ -37,7 +37,7 @@ struct lwtunnel_state *lwtunnel_state_alloc(int encap_len) } EXPORT_SYMBOL(lwtunnel_state_alloc); -const struct lwtunnel_encap_ops __rcu * +static const struct lwtunnel_encap_ops __rcu * lwtun_encaps[LWTUNNEL_ENCAP_MAX + 1] __read_mostly; int lwtunnel_encap_add_ops(const struct lwtunnel_encap_ops *ops,