/kernel/linux/linux-5.10/net/vmw_vsock/ |
D | vmci_transport_notify.c | 15 #define PKT_FIELD(vsk, field_name) (vmci_trans(vsk)->notify.pkt.field_name) argument 17 static bool vmci_transport_notify_waiting_write(struct vsock_sock *vsk) in vmci_transport_notify_waiting_write() argument 23 if (!PKT_FIELD(vsk, peer_waiting_write)) in vmci_transport_notify_waiting_write() 34 if (!PKT_FIELD(vsk, peer_waiting_write_detected)) { in vmci_transport_notify_waiting_write() 35 PKT_FIELD(vsk, peer_waiting_write_detected) = true; in vmci_transport_notify_waiting_write() 36 if (PKT_FIELD(vsk, write_notify_window) < PAGE_SIZE) { in vmci_transport_notify_waiting_write() 37 PKT_FIELD(vsk, write_notify_window) = in vmci_transport_notify_waiting_write() 38 PKT_FIELD(vsk, write_notify_min_window); in vmci_transport_notify_waiting_write() 40 PKT_FIELD(vsk, write_notify_window) -= PAGE_SIZE; in vmci_transport_notify_waiting_write() 41 if (PKT_FIELD(vsk, write_notify_window) < in vmci_transport_notify_waiting_write() [all …]
|
D | vmci_transport_notify_qstate.c | 15 #define PKT_FIELD(vsk, field_name) \ argument 16 (vmci_trans(vsk)->notify.pkt_q_state.field_name) 18 static bool vmci_transport_notify_waiting_write(struct vsock_sock *vsk) in vmci_transport_notify_waiting_write() argument 23 if (!PKT_FIELD(vsk, peer_waiting_write)) in vmci_transport_notify_waiting_write() 33 if (!PKT_FIELD(vsk, peer_waiting_write_detected)) { in vmci_transport_notify_waiting_write() 34 PKT_FIELD(vsk, peer_waiting_write_detected) = true; in vmci_transport_notify_waiting_write() 35 if (PKT_FIELD(vsk, write_notify_window) < PAGE_SIZE) { in vmci_transport_notify_waiting_write() 36 PKT_FIELD(vsk, write_notify_window) = in vmci_transport_notify_waiting_write() 37 PKT_FIELD(vsk, write_notify_min_window); in vmci_transport_notify_waiting_write() 39 PKT_FIELD(vsk, write_notify_window) -= PAGE_SIZE; in vmci_transport_notify_waiting_write() [all …]
|
D | af_vsock.c | 170 #define vsock_connected_sockets_vsk(vsk) \ argument 171 vsock_connected_sockets(&(vsk)->remote_addr, &(vsk)->local_addr) 181 static int vsock_auto_bind(struct vsock_sock *vsk) in vsock_auto_bind() argument 183 struct sock *sk = sk_vsock(vsk); in vsock_auto_bind() 186 if (vsock_addr_bound(&vsk->local_addr)) in vsock_auto_bind() 204 struct vsock_sock *vsk) in __vsock_insert_bound() argument 206 sock_hold(&vsk->sk); in __vsock_insert_bound() 207 list_add(&vsk->bound_table, list); in __vsock_insert_bound() 211 struct vsock_sock *vsk) in __vsock_insert_connected() argument 213 sock_hold(&vsk->sk); in __vsock_insert_connected() [all …]
|
D | virtio_transport_common.c | 30 virtio_transport_get_ops(struct vsock_sock *vsk) in virtio_transport_get_ops() argument 32 const struct vsock_transport *t = vsock_core_get_transport(vsk); in virtio_transport_get_ops() 65 pkt->vsk = info->vsk; in virtio_transport_alloc_pkt() 173 static int virtio_transport_send_pkt_info(struct vsock_sock *vsk, in virtio_transport_send_pkt_info() argument 182 t_ops = virtio_transport_get_ops(vsk); in virtio_transport_send_pkt_info() 187 src_port = vsk->local_addr.svm_port; in virtio_transport_send_pkt_info() 189 dst_cid = vsk->remote_addr.svm_cid; in virtio_transport_send_pkt_info() 190 dst_port = vsk->remote_addr.svm_port; in virtio_transport_send_pkt_info() 196 vvs = vsk->trans; in virtio_transport_send_pkt_info() 272 static int virtio_transport_send_credit_update(struct vsock_sock *vsk, in virtio_transport_send_credit_update() argument [all …]
|
D | vmci_transport.c | 60 static bool vmci_check_transport(struct vsock_sock *vsk); 286 struct vsock_sock *vsk; in vmci_transport_send_control_pkt() local 288 vsk = vsock_sk(sk); in vmci_transport_send_control_pkt() 290 if (!vsock_addr_bound(&vsk->local_addr)) in vmci_transport_send_control_pkt() 293 if (!vsock_addr_bound(&vsk->remote_addr)) in vmci_transport_send_control_pkt() 296 return vmci_transport_alloc_send_control_pkt(&vsk->local_addr, in vmci_transport_send_control_pkt() 297 &vsk->remote_addr, in vmci_transport_send_control_pkt() 319 struct vsock_sock *vsk; in vmci_transport_send_reset() local 324 vsk = vsock_sk(sk); in vmci_transport_send_reset() 326 if (!vsock_addr_bound(&vsk->local_addr)) in vmci_transport_send_reset() [all …]
|
D | hyperv_transport.c | 92 struct vsock_sock *vsk; member 155 static bool hvs_check_transport(struct vsock_sock *vsk); 241 struct vsock_sock *vsk = vsock_sk(sk); in hvs_channel_cb() local 242 struct hvsock *hvs = vsk->trans; in hvs_channel_cb() 252 static void hvs_do_close_lock_held(struct vsock_sock *vsk, in hvs_do_close_lock_held() argument 255 struct sock *sk = sk_vsock(vsk); in hvs_do_close_lock_held() 258 vsk->peer_shutdown = SHUTDOWN_MASK; in hvs_do_close_lock_held() 259 if (vsock_stream_has_data(vsk) <= 0) in hvs_do_close_lock_held() 262 if (vsk->close_work_scheduled && in hvs_do_close_lock_held() 263 (!cancel_timeout || cancel_delayed_work(&vsk->close_work))) { in hvs_do_close_lock_held() [all …]
|
D | diag.c | 17 struct vsock_sock *vsk = vsock_sk(sk); in sk_diag_fill() local 37 rep->vdiag_src_cid = vsk->local_addr.svm_cid; in sk_diag_fill() 38 rep->vdiag_src_port = vsk->local_addr.svm_port; in sk_diag_fill() 39 rep->vdiag_dst_cid = vsk->remote_addr.svm_cid; in sk_diag_fill() 40 rep->vdiag_dst_port = vsk->remote_addr.svm_port; in sk_diag_fill() 51 struct vsock_sock *vsk; in vsock_diag_dump() local 76 list_for_each_entry(vsk, head, bound_table) { in vsock_diag_dump() 77 struct sock *sk = sk_vsock(vsk); in vsock_diag_dump() 106 list_for_each_entry(vsk, head, connected_table) { in vsock_diag_dump() 107 struct sock *sk = sk_vsock(vsk); in vsock_diag_dump() [all …]
|
D | vsock_loopback.c | 44 static int vsock_loopback_cancel_pkt(struct vsock_sock *vsk) in vsock_loopback_cancel_pkt() argument 52 if (pkt->vsk != vsk) in vsock_loopback_cancel_pkt()
|
D | vmci_transport_notify.h | 40 void (*socket_destruct) (struct vsock_sock *vsk);
|
D | virtio_transport.c | 200 virtio_transport_cancel_pkt(struct vsock_sock *vsk) in virtio_transport_cancel_pkt() argument 216 if (pkt->vsk != vsk) in virtio_transport_cancel_pkt()
|
/kernel/linux/linux-5.10/include/linux/ |
D | virtio_vsock.h | 23 struct vsock_sock *vsk; member 45 struct vsock_sock *vsk; member 56 struct vsock_sock *vsk; member 74 virtio_transport_stream_dequeue(struct vsock_sock *vsk, 79 virtio_transport_dgram_dequeue(struct vsock_sock *vsk, 83 s64 virtio_transport_stream_has_data(struct vsock_sock *vsk); 84 s64 virtio_transport_stream_has_space(struct vsock_sock *vsk); 86 int virtio_transport_do_socket_init(struct vsock_sock *vsk, 89 virtio_transport_notify_poll_in(struct vsock_sock *vsk, 93 virtio_transport_notify_poll_out(struct vsock_sock *vsk, [all …]
|
/kernel/linux/linux-5.10/include/net/ |
D | af_vsock.h | 77 s64 vsock_stream_has_data(struct vsock_sock *vsk); 78 s64 vsock_stream_has_space(struct vsock_sock *vsk); 113 int (*cancel_pkt)(struct vsock_sock *vsk); 120 int (*dgram_dequeue)(struct vsock_sock *vsk, struct msghdr *msg, 173 const struct vsock_transport *vsock_core_get_transport(struct vsock_sock *vsk); 178 static inline bool __vsock_in_bound_table(struct vsock_sock *vsk) in __vsock_in_bound_table() argument 180 return !list_empty(&vsk->bound_table); in __vsock_in_bound_table() 184 static inline bool __vsock_in_connected_table(struct vsock_sock *vsk) in __vsock_in_connected_table() argument 186 return !list_empty(&vsk->connected_table); in __vsock_in_connected_table() 193 void vsock_insert_connected(struct vsock_sock *vsk); [all …]
|
/kernel/linux/linux-5.10/drivers/vhost/ |
D | vsock.c | 275 vhost_transport_cancel_pkt(struct vsock_sock *vsk) in vhost_transport_cancel_pkt() argument 286 vsock = vhost_vsock_get(vsk->remote_addr.svm_cid); in vhost_transport_cancel_pkt() 292 if (pkt->vsk != vsk) in vhost_transport_cancel_pkt() 662 struct vsock_sock *vsk = vsock_sk(sk); in vhost_vsock_reset_orphans() local 670 if (vhost_vsock_get(vsk->remote_addr.svm_cid)) in vhost_vsock_reset_orphans() 676 if (vsk->close_work_scheduled) in vhost_vsock_reset_orphans() 680 vsk->peer_shutdown = SHUTDOWN_MASK; in vhost_vsock_reset_orphans()
|