/net/rds/ |
D | af_rds.c | 62 struct rds_sock *rs; in rds_release() local 67 rs = rds_sk_to_rs(sk); in rds_release() 73 rds_clear_recv_queue(rs); in rds_release() 74 rds_cong_remove_socket(rs); in rds_release() 76 rds_remove_bound(rs); in rds_release() 78 rds_send_drop_to(rs, NULL); in rds_release() 79 rds_rdma_drop_keys(rs); in rds_release() 80 rds_notify_queue_get(rs, NULL); in rds_release() 81 rds_notify_msg_zcopy_purge(&rs->rs_zcookie_queue); in rds_release() 84 list_del_init(&rs->rs_item); in rds_release() [all …]
|
D | bind.c | 76 struct rds_sock *rs; in rds_find_bound() local 80 rs = rhashtable_lookup(&bind_hash_table, key, ht_parms); in rds_find_bound() 81 if (rs && (sock_flag(rds_rs_to_sk(rs), SOCK_DEAD) || in rds_find_bound() 82 !refcount_inc_not_zero(&rds_rs_to_sk(rs)->sk_refcnt))) in rds_find_bound() 83 rs = NULL; in rds_find_bound() 87 rdsdebug("returning rs %p for %pI6c:%u\n", rs, addr, in rds_find_bound() 90 return rs; in rds_find_bound() 94 static int rds_add_bound(struct rds_sock *rs, const struct in6_addr *addr, in rds_add_bound() argument 122 memcpy(rs->rs_bound_key, key, sizeof(rs->rs_bound_key)); in rds_add_bound() 123 rs->rs_bound_addr = *addr; in rds_add_bound() [all …]
|
D | recv.c | 87 static void rds_recv_rcvbuf_delta(struct rds_sock *rs, struct sock *sk, in rds_recv_rcvbuf_delta() argument 96 rs->rs_rcv_bytes += delta; in rds_recv_rcvbuf_delta() 103 if (rs->rs_transport->t_type == RDS_TRANS_LOOP) in rds_recv_rcvbuf_delta() 106 now_congested = rs->rs_rcv_bytes > rds_sk_rcvbuf(rs); in rds_recv_rcvbuf_delta() 110 rs, &rs->rs_bound_addr, in rds_recv_rcvbuf_delta() 111 ntohs(rs->rs_bound_port), rs->rs_rcv_bytes, in rds_recv_rcvbuf_delta() 112 rds_sk_rcvbuf(rs), now_congested, delta); in rds_recv_rcvbuf_delta() 115 if (!rs->rs_congested && now_congested) { in rds_recv_rcvbuf_delta() 116 rs->rs_congested = 1; in rds_recv_rcvbuf_delta() 123 else if (rs->rs_congested && (rs->rs_rcv_bytes < (rds_sk_rcvbuf(rs)/2))) { in rds_recv_rcvbuf_delta() [all …]
|
D | send.c | 473 static void rds_send_sndbuf_remove(struct rds_sock *rs, struct rds_message *rm) in rds_send_sndbuf_remove() argument 477 assert_spin_locked(&rs->rs_lock); in rds_send_sndbuf_remove() 479 BUG_ON(rs->rs_snd_bytes < len); in rds_send_sndbuf_remove() 480 rs->rs_snd_bytes -= len; in rds_send_sndbuf_remove() 482 if (rs->rs_snd_bytes == 0) in rds_send_sndbuf_remove() 502 struct rds_sock *rs = NULL; in rds_rdma_send_complete() local 513 rs = rm->m_rs; in rds_rdma_send_complete() 514 sock_hold(rds_rs_to_sk(rs)); in rds_rdma_send_complete() 517 spin_lock(&rs->rs_lock); in rds_rdma_send_complete() 518 list_add_tail(¬ifier->n_list, &rs->rs_notify_queue); in rds_rdma_send_complete() [all …]
|
D | rdma.c | 97 struct rds_sock *rs = mr->r_sock; in rds_destroy_mr() local 104 spin_lock_irqsave(&rs->rs_rdma_lock, flags); in rds_destroy_mr() 106 rb_erase(&mr->r_rb_node, &rs->rs_rdma_keys); in rds_destroy_mr() 109 spin_unlock_irqrestore(&rs->rs_rdma_lock, flags); in rds_destroy_mr() 127 void rds_rdma_drop_keys(struct rds_sock *rs) in rds_rdma_drop_keys() argument 134 spin_lock_irqsave(&rs->rs_rdma_lock, flags); in rds_rdma_drop_keys() 135 while ((node = rb_first(&rs->rs_rdma_keys))) { in rds_rdma_drop_keys() 137 if (mr->r_trans == rs->rs_transport) in rds_rdma_drop_keys() 139 rb_erase(&mr->r_rb_node, &rs->rs_rdma_keys); in rds_rdma_drop_keys() 141 spin_unlock_irqrestore(&rs->rs_rdma_lock, flags); in rds_rdma_drop_keys() [all …]
|
D | cong.c | 266 struct rds_sock *rs; in rds_cong_map_updated() local 269 list_for_each_entry(rs, &rds_cong_monitor, rs_cong_list) { in rds_cong_map_updated() 270 spin_lock(&rs->rs_lock); in rds_cong_map_updated() 271 rs->rs_cong_notify |= (rs->rs_cong_mask & portmask); in rds_cong_map_updated() 272 rs->rs_cong_mask &= ~portmask; in rds_cong_map_updated() 273 spin_unlock(&rs->rs_lock); in rds_cong_map_updated() 274 if (rs->rs_cong_notify) in rds_cong_map_updated() 275 rds_wake_sk_sleep(rs); in rds_cong_map_updated() 338 void rds_cong_add_socket(struct rds_sock *rs) in rds_cong_add_socket() argument 343 if (list_empty(&rs->rs_cong_list)) in rds_cong_add_socket() [all …]
|
D | rds.h | 96 #define RDS_MPATH_HASH(rs, n) (jhash_1word((rs)->rs_bound_port, \ argument 97 (rs)->rs_hash_initval) & ((n) - 1)) 569 struct rds_sock *rs, u32 *key_ret, 665 static inline struct sock *rds_rs_to_sk(struct rds_sock *rs) in rds_rs_to_sk() argument 667 return &rs->rs_sk; in rds_rs_to_sk() 675 static inline int rds_sk_sndbuf(struct rds_sock *rs) in rds_sk_sndbuf() argument 677 return rds_rs_to_sk(rs)->sk_sndbuf / 2; in rds_sk_sndbuf() 679 static inline int rds_sk_rcvbuf(struct rds_sock *rs) in rds_sk_rcvbuf() argument 681 return rds_rs_to_sk(rs)->sk_rcvbuf / 2; in rds_sk_rcvbuf() 724 void rds_sock_addref(struct rds_sock *rs); [all …]
|
D | message.c | 92 static void rds_rm_zerocopy_callback(struct rds_sock *rs, in rds_rm_zerocopy_callback() argument 103 q = &rs->rs_zcookie_queue; in rds_rm_zerocopy_callback() 140 struct rds_sock *rs = rm->m_rs; in rds_message_purge() local 144 rds_rm_zerocopy_callback(rs, rm->data.op_mmp_znotifier); in rds_message_purge() 145 rds_wake_sk_sleep(rs); in rds_message_purge() 148 sock_put(rds_rs_to_sk(rs)); in rds_message_purge()
|
D | ib_mr.h | 121 struct rds_sock *rs, u32 *key_ret,
|
D | ib_rdma.c | 551 struct rds_sock *rs, u32 *key_ret, in rds_ib_get_mr() argument 560 rds_ibdev = rds_ib_get_device(rs->rs_bound_addr.s6_addr32[3]); in rds_ib_get_mr()
|
/net/ipv4/ |
D | tcp_rate.c | 80 struct rate_sample *rs) in tcp_rate_skb_delivered() argument 90 if (!rs->prior_delivered || in tcp_rate_skb_delivered() 92 scb->end_seq, rs->last_end_seq)) { in tcp_rate_skb_delivered() 93 rs->prior_delivered = scb->tx.delivered; in tcp_rate_skb_delivered() 94 rs->prior_mstamp = scb->tx.delivered_mstamp; in tcp_rate_skb_delivered() 95 rs->is_app_limited = scb->tx.is_app_limited; in tcp_rate_skb_delivered() 96 rs->is_retrans = scb->sacked & TCPCB_RETRANS; in tcp_rate_skb_delivered() 97 rs->last_end_seq = scb->end_seq; in tcp_rate_skb_delivered() 102 rs->interval_us = tcp_stamp_us_delta(tp->first_tx_mstamp, in tcp_rate_skb_delivered() 116 bool is_sack_reneg, struct rate_sample *rs) in tcp_rate_gen() argument [all …]
|
D | tcp_bbr.c | 478 struct sock *sk, const struct rate_sample *rs, u32 acked, u32 *new_cwnd) in bbr_set_cwnd_to_recover_or_restore() argument 489 if (rs->losses > 0) in bbr_set_cwnd_to_recover_or_restore() 490 cwnd = max_t(s32, cwnd - rs->losses, 1); in bbr_set_cwnd_to_recover_or_restore() 516 static void bbr_set_cwnd(struct sock *sk, const struct rate_sample *rs, in bbr_set_cwnd() argument 526 if (bbr_set_cwnd_to_recover_or_restore(sk, rs, acked, &cwnd)) in bbr_set_cwnd() 552 const struct rate_sample *rs) in bbr_is_next_cycle_phase() argument 567 inflight = bbr_packets_in_net_at_edt(sk, rs->prior_in_flight); in bbr_is_next_cycle_phase() 577 (rs->losses || /* perhaps pacing_gain*BDP won't fit */ in bbr_is_next_cycle_phase() 599 const struct rate_sample *rs) in bbr_update_cycle_phase() argument 603 if (bbr->mode == BBR_PROBE_BW && bbr_is_next_cycle_phase(sk, rs)) in bbr_update_cycle_phase() [all …]
|
D | tcp_recovery.c | 192 void tcp_rack_update_reo_wnd(struct sock *sk, struct rate_sample *rs) in tcp_rack_update_reo_wnd() argument 198 !rs->prior_delivered) in tcp_rack_update_reo_wnd() 202 if (before(rs->prior_delivered, tp->rack.last_delivered)) in tcp_rack_update_reo_wnd()
|
D | tcp_input.c | 3096 long ca_rtt_us, struct rate_sample *rs) in tcp_ack_update_rtt() argument 3125 rs->rtt_us = ca_rtt_us; /* RTT of last (S)ACKed packet (or -1) */ in tcp_ack_update_rtt() 3145 struct rate_sample rs; in tcp_synack_rtt_meas() local 3151 tcp_ack_update_rtt(sk, FLAG_SYN_ACKED, rtt_us, -1L, rtt_us, &rs); in tcp_synack_rtt_meas() 3504 int flag, const struct rate_sample *rs) in tcp_cong_control() argument 3509 icsk->icsk_ca_ops->cong_control(sk, rs); in tcp_cong_control() 3515 tcp_cwnd_reduction(sk, acked_sacked, rs->losses, flag); in tcp_cong_control() 3777 struct rate_sample rs = { .prior_delivered = 0 }; in tcp_ack() local 3790 sack_state.rate = &rs; in tcp_ack() 3831 rs.prior_in_flight = tcp_packets_in_flight(tp); in tcp_ack() [all …]
|
/net/xfrm/ |
D | xfrm_user.c | 124 struct xfrm_replay_state_esn *rs; in verify_replay() local 129 rs = nla_data(rt); in verify_replay() 131 if (rs->bmp_len > XFRMA_REPLAY_ESN_MAX / sizeof(rs->bmp[0]) / 8) in verify_replay() 134 if (nla_len(rt) < (int)xfrm_replay_state_esn_len(rs) && in verify_replay() 135 nla_len(rt) != sizeof(*rs)) in verify_replay()
|