]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - net/socket.c
Merge branch 'omap-clock-fixes' of git://git.pwsan.com/linux-2.6
[linux-2.6-omap-h63xx.git] / net / socket.c
index 0b14b79c03aff9503f4c56f80b4a6e5850737ca8..791d71a36a93dfec5166fe05e2e0cb394cfa904b 100644 (file)
@@ -493,8 +493,7 @@ static struct socket *sock_alloc(void)
        inode->i_uid = current_fsuid();
        inode->i_gid = current_fsgid();
 
-       get_cpu_var(sockets_in_use)++;
-       put_cpu_var(sockets_in_use);
+       percpu_add(sockets_in_use, 1);
        return sock;
 }
 
@@ -536,8 +535,7 @@ void sock_release(struct socket *sock)
        if (sock->fasync_list)
                printk(KERN_ERR "sock_release: fasync list not empty!\n");
 
-       get_cpu_var(sockets_in_use)--;
-       put_cpu_var(sockets_in_use);
+       percpu_sub(sockets_in_use, 1);
        if (!sock->file) {
                iput(SOCK_INODE(sock));
                return;
@@ -1536,8 +1534,6 @@ SYSCALL_DEFINE4(accept4, int, fd, struct sockaddr __user *, upeer_sockaddr,
        fd_install(newfd, newfile);
        err = newfd;
 
-       security_socket_post_accept(sock, newsock);
-
 out_put:
        fput_light(sock->file, fput_needed);
 out: