mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
synced 2025-01-01 10:42:11 +00:00
l2tp: remove inline from functions in c sources
Update l2tp to remove the inline keyword from several functions in C sources, since this is now discouraged. Signed-off-by: James Chapman <jchapman@katalix.com> Signed-off-by: Tom Parkin <tparkin@katalix.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
e2b1762cf3
commit
168464c19e
@ -117,12 +117,12 @@ struct l2tp_net {
|
||||
struct hlist_head l2tp_v3_session_htable[16];
|
||||
};
|
||||
|
||||
static inline u32 l2tp_v2_session_key(u16 tunnel_id, u16 session_id)
|
||||
static u32 l2tp_v2_session_key(u16 tunnel_id, u16 session_id)
|
||||
{
|
||||
return ((u32)tunnel_id) << 16 | session_id;
|
||||
}
|
||||
|
||||
static inline unsigned long l2tp_v3_session_hashkey(struct sock *sk, u32 session_id)
|
||||
static unsigned long l2tp_v3_session_hashkey(struct sock *sk, u32 session_id)
|
||||
{
|
||||
return ((unsigned long)sk) + session_id;
|
||||
}
|
||||
@ -135,7 +135,7 @@ static bool l2tp_sk_is_v6(struct sock *sk)
|
||||
}
|
||||
#endif
|
||||
|
||||
static inline struct l2tp_net *l2tp_pernet(const struct net *net)
|
||||
static struct l2tp_net *l2tp_pernet(const struct net *net)
|
||||
{
|
||||
return net_generic(net, l2tp_net_id);
|
||||
}
|
||||
|
@ -37,7 +37,7 @@ static DEFINE_RWLOCK(l2tp_ip_lock);
|
||||
static struct hlist_head l2tp_ip_table;
|
||||
static struct hlist_head l2tp_ip_bind_table;
|
||||
|
||||
static inline struct l2tp_ip_sock *l2tp_ip_sk(const struct sock *sk)
|
||||
static struct l2tp_ip_sock *l2tp_ip_sk(const struct sock *sk)
|
||||
{
|
||||
return (struct l2tp_ip_sock *)sk;
|
||||
}
|
||||
|
@ -43,7 +43,7 @@ static DEFINE_RWLOCK(l2tp_ip6_lock);
|
||||
static struct hlist_head l2tp_ip6_table;
|
||||
static struct hlist_head l2tp_ip6_bind_table;
|
||||
|
||||
static inline struct l2tp_ip6_sock *l2tp_ip6_sk(const struct sock *sk)
|
||||
static struct l2tp_ip6_sock *l2tp_ip6_sk(const struct sock *sk)
|
||||
{
|
||||
return (struct l2tp_ip6_sock *)sk;
|
||||
}
|
||||
|
@ -149,7 +149,7 @@ static struct sock *pppol2tp_session_get_sock(struct l2tp_session *session)
|
||||
|
||||
/* Helpers to obtain tunnel/session contexts from sockets.
|
||||
*/
|
||||
static inline struct l2tp_session *pppol2tp_sock_to_session(struct sock *sk)
|
||||
static struct l2tp_session *pppol2tp_sock_to_session(struct sock *sk)
|
||||
{
|
||||
struct l2tp_session *session;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user