Skip to content

Commit

Permalink
[NETNS]: Compilation warnings under CONFIG_NET_NS.
Browse files Browse the repository at this point in the history
Recent commits from YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
have been introduced a several compilation warnings
'assignment discards qualifiers from pointer target type'
due to extra const modifier in the inline call parameters of
{dev|sock|twsk}_net_set.

Drop it.

Signed-off-by: Denis V. Lunev <den@openvz.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Denis V. Lunev authored and David S. Miller committed Mar 26, 2008
1 parent 9c2f574 commit f5aa23f
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion include/linux/netdevice.h
Original file line number Diff line number Diff line change
Expand Up @@ -753,7 +753,7 @@ struct net *dev_net(const struct net_device *dev)
}

static inline
void dev_net_set(struct net_device *dev, const struct net *net)
void dev_net_set(struct net_device *dev, struct net *net)
{
#ifdef CONFIG_NET_NS
dev->nd_net = net;
Expand Down
2 changes: 1 addition & 1 deletion include/net/inet_timewait_sock.h
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ struct net *twsk_net(const struct inet_timewait_sock *twsk)
}

static inline
void twsk_net_set(struct inet_timewait_sock *twsk, const struct net *net)
void twsk_net_set(struct inet_timewait_sock *twsk, struct net *net)
{
#ifdef CONFIG_NET_NS
twsk->tw_net = net;
Expand Down
2 changes: 1 addition & 1 deletion include/net/sock.h
Original file line number Diff line number Diff line change
Expand Up @@ -1358,7 +1358,7 @@ struct net *sock_net(const struct sock *sk)
}

static inline
void sock_net_set(struct sock *sk, const struct net *net)
void sock_net_set(struct sock *sk, struct net *net)
{
#ifdef CONFIG_NET_NS
sk->sk_net = net;
Expand Down

0 comments on commit f5aa23f

Please sign in to comment.