net: change proto and proto_ops accept type
[linux-2.6-block.git] / net / ipv4 / inet_connection_sock.c
index 3b38610958ee4bc3d9296c9b5e5fce6ab5c97c2c..7734d189c66b80d2c8d259de7796463ed6a473f1 100644 (file)
@@ -661,7 +661,7 @@ static int inet_csk_wait_for_connect(struct sock *sk, long timeo)
 /*
  * This will accept the next outstanding connection.
  */
-struct sock *inet_csk_accept(struct sock *sk, int flags, int *err, bool kern)
+struct sock *inet_csk_accept(struct sock *sk, struct proto_accept_arg *arg)
 {
        struct inet_connection_sock *icsk = inet_csk(sk);
        struct request_sock_queue *queue = &icsk->icsk_accept_queue;
@@ -680,7 +680,7 @@ struct sock *inet_csk_accept(struct sock *sk, int flags, int *err, bool kern)
 
        /* Find already established connection */
        if (reqsk_queue_empty(queue)) {
-               long timeo = sock_rcvtimeo(sk, flags & O_NONBLOCK);
+               long timeo = sock_rcvtimeo(sk, arg->flags & O_NONBLOCK);
 
                /* If this is a non blocking socket don't sleep */
                error = -EAGAIN;
@@ -745,7 +745,7 @@ out:
 out_err:
        newsk = NULL;
        req = NULL;
-       *err = error;
+       arg->err = error;
        goto out;
 }
 EXPORT_SYMBOL(inet_csk_accept);