Merge rsync://bughost.org/repos/ieee80211-delta/
[powerpc.git] / include / net / inet_connection_sock.h
index 4d7e708..b0c9906 100644 (file)
@@ -94,7 +94,7 @@ static inline void *inet_csk_ca(const struct sock *sk)
 
 extern struct sock *inet_csk_clone(struct sock *sk,
                                   const struct request_sock *req,
-                                  const unsigned int __nocast priority);
+                                  const gfp_t priority);
 
 enum inet_csk_ack_state_t {
        ICSK_ACK_SCHED  = 1,
@@ -147,7 +147,7 @@ static inline void inet_csk_clear_xmit_timer(struct sock *sk, const int what)
        }
 #ifdef INET_CSK_DEBUG
        else {
-               pr_debug(inet_csk_timer_bug_msg);
+               pr_debug("%s", inet_csk_timer_bug_msg);
        }
 #endif
 }
@@ -180,7 +180,7 @@ static inline void inet_csk_reset_xmit_timer(struct sock *sk, const int what,
        }
 #ifdef INET_CSK_DEBUG
        else {
-               pr_debug(inet_csk_timer_bug_msg);
+               pr_debug("%s", inet_csk_timer_bug_msg);
        }
 #endif
 }
@@ -260,6 +260,16 @@ extern void inet_csk_reqsk_queue_prune(struct sock *parent,
                                       const unsigned long max_rto);
 
 extern void inet_csk_destroy_sock(struct sock *sk);
+
+/*
+ * LISTEN is a special case for poll..
+ */
+static inline unsigned int inet_csk_listen_poll(const struct sock *sk)
+{
+       return !reqsk_queue_empty(&inet_csk(sk)->icsk_accept_queue) ?
+                       (POLLIN | POLLRDNORM) : 0;
+}
+
 extern int  inet_csk_listen_start(struct sock *sk, const int nr_table_entries);
 extern void inet_csk_listen_stop(struct sock *sk);