mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-13 14:24:11 +08:00
net: remove useless parameter of __sock_cmsg_send
The parameter 'msg' has never been used by __sock_cmsg_send, so we can remove it safely. Reported-by: Zeal Robot <zealci@zte.com.cn> Signed-off-by: xu xin <xu.xin16@zte.com.cn> Reviewed-by: Zhang Yunkai <zhang.yunkai@zte.com.cn> Acked-by: Kuniyuki Iwashima <kuniyu@amazon.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
350749b909
commit
233baf9a1b
@ -1901,7 +1901,7 @@ static inline void sockcm_init(struct sockcm_cookie *sockc,
|
||||
*sockc = (struct sockcm_cookie) { .tsflags = sk->sk_tsflags };
|
||||
}
|
||||
|
||||
int __sock_cmsg_send(struct sock *sk, struct msghdr *msg, struct cmsghdr *cmsg,
|
||||
int __sock_cmsg_send(struct sock *sk, struct cmsghdr *cmsg,
|
||||
struct sockcm_cookie *sockc);
|
||||
int sock_cmsg_send(struct sock *sk, struct msghdr *msg,
|
||||
struct sockcm_cookie *sockc);
|
||||
|
@ -2744,7 +2744,7 @@ failure:
|
||||
}
|
||||
EXPORT_SYMBOL(sock_alloc_send_pskb);
|
||||
|
||||
int __sock_cmsg_send(struct sock *sk, struct msghdr *msg, struct cmsghdr *cmsg,
|
||||
int __sock_cmsg_send(struct sock *sk, struct cmsghdr *cmsg,
|
||||
struct sockcm_cookie *sockc)
|
||||
{
|
||||
u32 tsflags;
|
||||
@ -2798,7 +2798,7 @@ int sock_cmsg_send(struct sock *sk, struct msghdr *msg,
|
||||
return -EINVAL;
|
||||
if (cmsg->cmsg_level != SOL_SOCKET)
|
||||
continue;
|
||||
ret = __sock_cmsg_send(sk, msg, cmsg, sockc);
|
||||
ret = __sock_cmsg_send(sk, cmsg, sockc);
|
||||
if (ret)
|
||||
return ret;
|
||||
}
|
||||
|
@ -267,7 +267,7 @@ int ip_cmsg_send(struct sock *sk, struct msghdr *msg, struct ipcm_cookie *ipc,
|
||||
}
|
||||
#endif
|
||||
if (cmsg->cmsg_level == SOL_SOCKET) {
|
||||
err = __sock_cmsg_send(sk, msg, cmsg, &ipc->sockc);
|
||||
err = __sock_cmsg_send(sk, cmsg, &ipc->sockc);
|
||||
if (err)
|
||||
return err;
|
||||
continue;
|
||||
|
@ -771,7 +771,7 @@ int ip6_datagram_send_ctl(struct net *net, struct sock *sk,
|
||||
}
|
||||
|
||||
if (cmsg->cmsg_level == SOL_SOCKET) {
|
||||
err = __sock_cmsg_send(sk, msg, cmsg, &ipc6->sockc);
|
||||
err = __sock_cmsg_send(sk, cmsg, &ipc6->sockc);
|
||||
if (err)
|
||||
return err;
|
||||
continue;
|
||||
|
Loading…
Reference in New Issue
Block a user