Commit 00ee3e38 authored by David S. Miller's avatar David S. Miller

[NET]: Some stuff missed during acme's struct sock cleanup.

parent 84a9cd88
...@@ -789,7 +789,7 @@ static int routing_ioctl(unsigned int fd, unsigned int cmd, unsigned long arg) ...@@ -789,7 +789,7 @@ static int routing_ioctl(unsigned int fd, unsigned int cmd, unsigned long arg)
struct socket *mysock = sockfd_lookup(fd, &ret); struct socket *mysock = sockfd_lookup(fd, &ret);
if (mysock && mysock->sk && mysock->sk->family == AF_INET6) { /* ipv6 */ if (mysock && mysock->sk && mysock->sk->sk_family == AF_INET6) { /* ipv6 */
ret = copy_from_user (&r6.rtmsg_dst, &(((struct in6_rtmsg32 *)arg)->rtmsg_dst), ret = copy_from_user (&r6.rtmsg_dst, &(((struct in6_rtmsg32 *)arg)->rtmsg_dst),
3 * sizeof(struct in6_addr)); 3 * sizeof(struct in6_addr));
ret |= __get_user (r6.rtmsg_type, &(((struct in6_rtmsg32 *)arg)->rtmsg_type)); ret |= __get_user (r6.rtmsg_type, &(((struct in6_rtmsg32 *)arg)->rtmsg_type));
......
...@@ -149,10 +149,10 @@ static void timod_wake_socket(unsigned int fd) ...@@ -149,10 +149,10 @@ static void timod_wake_socket(unsigned int fd)
SOLD("wakeing socket"); SOLD("wakeing socket");
sock = SOCKET_I(current->files->fd[fd]->f_dentry->d_inode); sock = SOCKET_I(current->files->fd[fd]->f_dentry->d_inode);
wake_up_interruptible(&sock->wait); wake_up_interruptible(&sock->wait);
read_lock(&sock->sk->callback_lock); read_lock(&sock->sk->sk_callback_lock);
if (sock->fasync_list && !test_bit(SOCK_ASYNC_WAITDATA, &sock->flags)) if (sock->fasync_list && !test_bit(SOCK_ASYNC_WAITDATA, &sock->flags))
__kill_fasync(sock->fasync_list, SIGIO, POLL_IN); __kill_fasync(sock->fasync_list, SIGIO, POLL_IN);
read_unlock(&sock->sk->callback_lock); read_unlock(&sock->sk->sk_callback_lock);
SOLD("done"); SOLD("done");
} }
......
...@@ -120,7 +120,7 @@ static int nbd_xmit(int send, struct socket *sock, char *buf, int size, int msg_ ...@@ -120,7 +120,7 @@ static int nbd_xmit(int send, struct socket *sock, char *buf, int size, int msg_
do { do {
sock->sk->allocation = GFP_NOIO; sock->sk->sk_allocation = GFP_NOIO;
iov.iov_base = buf; iov.iov_base = buf;
iov.iov_len = size; iov.iov_len = size;
msg.msg_name = NULL; msg.msg_name = NULL;
......
...@@ -694,7 +694,7 @@ init_or_cleanup(int init) ...@@ -694,7 +694,7 @@ init_or_cleanup(int init)
proc_net_remove(IPQ_PROC_FS_NAME); proc_net_remove(IPQ_PROC_FS_NAME);
cleanup_ipqnl: cleanup_ipqnl:
sock_release(ipqnl->socket); sock_release(ipqnl->sk_socket);
down(&ipqnl_sem); down(&ipqnl_sem);
up(&ipqnl_sem); up(&ipqnl_sem);
......
...@@ -31,7 +31,7 @@ match_pid(const struct sk_buff *skb, pid_t pid) ...@@ -31,7 +31,7 @@ match_pid(const struct sk_buff *skb, pid_t pid)
if(files) { if(files) {
spin_lock(&files->file_lock); spin_lock(&files->file_lock);
for (i=0; i < files->max_fds; i++) { for (i=0; i < files->max_fds; i++) {
if (fcheck_files(files, i) == skb->sk->socket->file) { if (fcheck_files(files, i) == skb->sk->sk_socket->file) {
spin_unlock(&files->file_lock); spin_unlock(&files->file_lock);
task_unlock(p); task_unlock(p);
read_unlock(&tasklist_lock); read_unlock(&tasklist_lock);
...@@ -50,7 +50,7 @@ static int ...@@ -50,7 +50,7 @@ static int
match_sid(const struct sk_buff *skb, pid_t sid) match_sid(const struct sk_buff *skb, pid_t sid)
{ {
struct task_struct *g, *p; struct task_struct *g, *p;
struct file *file = skb->sk->socket->file; struct file *file = skb->sk->sk_socket->file;
int i, found=0; int i, found=0;
read_lock(&tasklist_lock); read_lock(&tasklist_lock);
...@@ -93,17 +93,17 @@ match(const struct sk_buff *skb, ...@@ -93,17 +93,17 @@ match(const struct sk_buff *skb,
{ {
const struct ip6t_owner_info *info = matchinfo; const struct ip6t_owner_info *info = matchinfo;
if (!skb->sk || !skb->sk->socket || !skb->sk->socket->file) if (!skb->sk || !skb->sk->sk_socket || !skb->sk->sk_socket->file)
return 0; return 0;
if(info->match & IP6T_OWNER_UID) { if(info->match & IP6T_OWNER_UID) {
if((skb->sk->socket->file->f_uid != info->uid) ^ if((skb->sk->sk_socket->file->f_uid != info->uid) ^
!!(info->invert & IP6T_OWNER_UID)) !!(info->invert & IP6T_OWNER_UID))
return 0; return 0;
} }
if(info->match & IP6T_OWNER_GID) { if(info->match & IP6T_OWNER_GID) {
if((skb->sk->socket->file->f_gid != info->gid) ^ if((skb->sk->sk_socket->file->f_gid != info->gid) ^
!!(info->invert & IP6T_OWNER_GID)) !!(info->invert & IP6T_OWNER_GID))
return 0; return 0;
} }
......
...@@ -112,9 +112,9 @@ int rxrpc_create_transport(unsigned short port, struct rxrpc_transport **_trans) ...@@ -112,9 +112,9 @@ int rxrpc_create_transport(unsigned short port, struct rxrpc_transport **_trans)
/* set the socket up */ /* set the socket up */
sock = trans->socket->sk; sock = trans->socket->sk;
sock->user_data = trans; sock->sk_user_data = trans;
sock->data_ready = rxrpc_data_ready; sock->sk_data_ready = rxrpc_data_ready;
sock->error_report = rxrpc_error_report; sock->sk_error_report = rxrpc_error_report;
down_write(&rxrpc_proc_transports_sem); down_write(&rxrpc_proc_transports_sem);
list_add_tail(&trans->proc_link,&rxrpc_proc_transports); list_add_tail(&trans->proc_link,&rxrpc_proc_transports);
...@@ -184,7 +184,7 @@ void rxrpc_put_transport(struct rxrpc_transport *trans) ...@@ -184,7 +184,7 @@ void rxrpc_put_transport(struct rxrpc_transport *trans)
/* close the socket */ /* close the socket */
if (trans->socket) { if (trans->socket) {
trans->socket->sk->user_data = NULL; trans->socket->sk->sk_user_data = NULL;
sock_release(trans->socket); sock_release(trans->socket);
trans->socket = NULL; trans->socket = NULL;
} }
...@@ -255,16 +255,16 @@ static void rxrpc_data_ready(struct sock *sk, int count) ...@@ -255,16 +255,16 @@ static void rxrpc_data_ready(struct sock *sk, int count)
{ {
struct rxrpc_transport *trans; struct rxrpc_transport *trans;
_enter("%p{t=%p},%d",sk,sk->user_data,count); _enter("%p{t=%p},%d",sk,sk->sk_user_data,count);
/* queue the transport for attention by krxiod */ /* queue the transport for attention by krxiod */
trans = (struct rxrpc_transport *) sk->user_data; trans = (struct rxrpc_transport *) sk->sk_user_data;
if (trans) if (trans)
rxrpc_krxiod_queue_transport(trans); rxrpc_krxiod_queue_transport(trans);
/* wake up anyone waiting on the socket */ /* wake up anyone waiting on the socket */
if (sk->sleep && waitqueue_active(sk->sleep)) if (sk->sk_sleep && waitqueue_active(sk->sk_sleep))
wake_up_interruptible(sk->sleep); wake_up_interruptible(sk->sk_sleep);
_leave(""); _leave("");
...@@ -279,18 +279,18 @@ static void rxrpc_error_report(struct sock *sk) ...@@ -279,18 +279,18 @@ static void rxrpc_error_report(struct sock *sk)
{ {
struct rxrpc_transport *trans; struct rxrpc_transport *trans;
_enter("%p{t=%p}",sk,sk->user_data); _enter("%p{t=%p}",sk,sk->sk_user_data);
/* queue the transport for attention by krxiod */ /* queue the transport for attention by krxiod */
trans = (struct rxrpc_transport *) sk->user_data; trans = (struct rxrpc_transport *) sk->sk_user_data;
if (trans) { if (trans) {
trans->error_rcvd = 1; trans->error_rcvd = 1;
rxrpc_krxiod_queue_transport(trans); rxrpc_krxiod_queue_transport(trans);
} }
/* wake up anyone waiting on the socket */ /* wake up anyone waiting on the socket */
if (sk->sleep && waitqueue_active(sk->sleep)) if (sk->sk_sleep && waitqueue_active(sk->sk_sleep))
wake_up_interruptible(sk->sleep); wake_up_interruptible(sk->sk_sleep);
_leave(""); _leave("");
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment