Merge git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc-merge
[powerpc.git] / net / ipv4 / tcp.c
index 9ac7a4f..00aa80e 100644 (file)
@@ -1413,7 +1413,7 @@ recv_urg:
  *     closed.
  */
 
-static unsigned char new_state[16] = {
+static const unsigned char new_state[16] = {
   /* current state:        new state:      action:     */
   /* (Invalid)         */ TCP_CLOSE,
   /* TCP_ESTABLISHED   */ TCP_FIN_WAIT1 | TCP_ACTION_FIN,
@@ -1696,8 +1696,8 @@ int tcp_setsockopt(struct sock *sk, int level, int optname, char __user *optval,
        int err = 0;
 
        if (level != SOL_TCP)
-               return tp->af_specific->setsockopt(sk, level, optname,
-                                                  optval, optlen);
+               return icsk->icsk_af_ops->setsockopt(sk, level, optname,
+                                                    optval, optlen);
 
        /* This is a string value all the others are int's */
        if (optname == TCP_CONGESTION) {
@@ -1914,7 +1914,7 @@ void tcp_get_info(struct sock *sk, struct tcp_info *info)
        info->tcpi_last_data_recv = jiffies_to_msecs(now - icsk->icsk_ack.lrcvtime);
        info->tcpi_last_ack_recv = jiffies_to_msecs(now - tp->rcv_tstamp);
 
-       info->tcpi_pmtu = tp->pmtu_cookie;
+       info->tcpi_pmtu = icsk->icsk_pmtu_cookie;
        info->tcpi_rcv_ssthresh = tp->rcv_ssthresh;
        info->tcpi_rtt = jiffies_to_usecs(tp->srtt)>>3;
        info->tcpi_rttvar = jiffies_to_usecs(tp->mdev)>>2;
@@ -1939,8 +1939,8 @@ int tcp_getsockopt(struct sock *sk, int level, int optname, char __user *optval,
        int val, len;
 
        if (level != SOL_TCP)
-               return tp->af_specific->getsockopt(sk, level, optname,
-                                                  optval, optlen);
+               return icsk->icsk_af_ops->getsockopt(sk, level, optname,
+                                                    optval, optlen);
 
        if (get_user(len, optlen))
                return -EFAULT;
@@ -2065,8 +2065,7 @@ void __init tcp_init(void)
                                        sizeof(struct inet_ehash_bucket),
                                        thash_entries,
                                        (num_physpages >= 128 * 1024) ?
-                                               (25 - PAGE_SHIFT) :
-                                               (27 - PAGE_SHIFT),
+                                       13 : 15,
                                        HASH_HIGHMEM,
                                        &tcp_hashinfo.ehash_size,
                                        NULL,
@@ -2082,8 +2081,7 @@ void __init tcp_init(void)
                                        sizeof(struct inet_bind_hashbucket),
                                        tcp_hashinfo.ehash_size,
                                        (num_physpages >= 128 * 1024) ?
-                                               (25 - PAGE_SHIFT) :
-                                               (27 - PAGE_SHIFT),
+                                       13 : 15,
                                        HASH_HIGHMEM,
                                        &tcp_hashinfo.bhash_size,
                                        NULL,