Lines Matching refs:rwnd
445 * Figure out the value of window scale opton. Note that the rwnd is
456 uint32_t rwnd = tcp->tcp_rwnd;
458 for (i = 0; rwnd > TCP_MAXWIN && i < TCP_MAX_WINSHIFT;
459 i++, rwnd >>= 1)
2935 * We do not allow the receive window to shrink. After setting rwnd,
2949 * XXX - Should allow a lower rwnd than tcp_recv_hiwat_minmss * mss if the
2953 tcp_rwnd_set(tcp_t *tcp, uint32_t rwnd)
2968 rwnd = MAX(rwnd, tcps->tcps_recv_hiwat_minmss * mss);
2975 sth_hiwat = tcp_fuse_set_rcv_hiwat(tcp, rwnd);
2987 if ((tcp->tcp_rcv_ws > 0) && rwnd > tcp->tcp_cwnd_max)
2988 tcp->tcp_cwnd_max = rwnd;
3012 if (rwnd < old_max_rwnd && tcp->tcp_state > TCPS_SYN_SENT) {
3014 rwnd = MSS_ROUNDUP(old_max_rwnd, mss);
3022 if (rwnd > max_transmittable_rwnd) {
3023 rwnd = max_transmittable_rwnd -
3025 if (rwnd < mss)
3026 rwnd = max_transmittable_rwnd;
3032 tcp->tcp_rwnd = old_max_rwnd = rwnd;
3036 MIN(tcps->tcps_local_dacks_max, rwnd / mss / 2);
3044 MIN(tcps->tcps_deferred_acks_max, rwnd / mss / 2);
3051 * Increment the current rwnd by the amount the maximum grew (we
3055 tcp->tcp_rwnd += rwnd - old_max_rwnd;
3056 connp->conn_rcvbuf = rwnd;
3064 if ((tcp->tcp_rcv_ws > 0) && rwnd > tcp->tcp_cwnd_max)
3065 tcp->tcp_cwnd_max = rwnd;
3068 return (rwnd);
3070 tcp_set_recv_threshold(tcp, rwnd >> 3);
3072 (void) proto_set_rx_hiwat(connp->conn_rq, connp, rwnd);
3073 return (rwnd);
4222 * Just make sure our rwnd is at least rcvbuf * MSS large, and round up