Lines Matching full:transport
133 /* Transport used for host->guest communication */
135 /* Transport used for guest->host communication */
137 /* Transport used for DGRAM communication */
139 /* Transport used for local communication */
408 if (!vsk->transport) in vsock_deassign_transport()
411 vsk->transport->destruct(vsk); in vsock_deassign_transport()
412 module_put(vsk->transport->module); in vsock_deassign_transport()
413 vsk->transport = NULL; in vsock_deassign_transport()
416 /* Assign a transport to a socket and call the .init transport callback.
421 * The vsk->remote_addr is used to decide which transport to use:
423 * g2h is not loaded, will use local transport;
424 * - remote CID <= VMADDR_CID_HOST will use guest->host transport;
425 * - remote CID > VMADDR_CID_HOST will use host->guest transport;
450 if (vsk->transport) { in vsock_assign_transport()
451 if (vsk->transport == new_transport) in vsock_assign_transport()
454 /* transport->release() must be called with sock lock acquired. in vsock_assign_transport()
458 * which is not assigned to any transport. in vsock_assign_transport()
460 vsk->transport->release(vsk); in vsock_assign_transport()
464 /* We increase the module refcnt to prevent the transport unloading in vsock_assign_transport()
476 vsk->transport = new_transport; in vsock_assign_transport()
535 if (!vsk->transport) in vsock_send_shutdown()
538 return vsk->transport->shutdown(vsk, mode); in vsock_send_shutdown()
648 return vsk->transport->dgram_bind(vsk, addr); in __vsock_bind_dgram()
769 if (vsk->transport) in __vsock_release()
770 vsk->transport->release(vsk); in __vsock_release()
825 return vsk->transport->stream_has_data(vsk); in vsock_stream_has_data()
831 return vsk->transport->stream_has_space(vsk); in vsock_stream_has_space()
1000 const struct vsock_transport *transport = vsk->transport; in vsock_poll() local
1011 if (transport && transport->stream_is_active(vsk) && in vsock_poll()
1014 int ret = transport->notify_poll_in( in vsock_poll()
1035 if (transport && sk->sk_state == TCP_ESTABLISHED) { in vsock_poll()
1038 int ret = transport->notify_poll_out( in vsock_poll()
1076 const struct vsock_transport *transport; in vsock_dgram_sendmsg() local
1085 transport = vsk->transport; in vsock_dgram_sendmsg()
1105 remote_addr->svm_cid = transport->get_local_cid(); in vsock_dgram_sendmsg()
1115 remote_addr->svm_cid = transport->get_local_cid(); in vsock_dgram_sendmsg()
1129 if (!transport->dgram_allow(remote_addr->svm_cid, in vsock_dgram_sendmsg()
1135 err = transport->dgram_enqueue(vsk, remote_addr, msg, len); in vsock_dgram_sendmsg()
1170 if (!vsk->transport->dgram_allow(remote_addr->svm_cid, in vsock_dgram_connect()
1189 return vsk->transport->dgram_dequeue(vsk, msg, len, flags); in vsock_dgram_recvmsg()
1213 const struct vsock_transport *transport = vsk->transport; in vsock_transport_cancel_pkt() local
1215 if (!transport->cancel_pkt) in vsock_transport_cancel_pkt()
1218 return transport->cancel_pkt(vsk); in vsock_transport_cancel_pkt()
1251 const struct vsock_transport *transport; in vsock_stream_connect() local
1294 transport = vsk->transport; in vsock_stream_connect()
1299 if (!transport || in vsock_stream_connect()
1300 !transport->stream_allow(remote_addr->svm_cid, in vsock_stream_connect()
1312 err = transport->connect(vsk); in vsock_stream_connect()
1501 const struct vsock_transport *transport, in vsock_update_buffer_size() argument
1511 transport && transport->notify_buffer_size) in vsock_update_buffer_size()
1512 transport->notify_buffer_size(vsk, &val); in vsock_update_buffer_size()
1526 const struct vsock_transport *transport; in vsock_stream_setsockopt() local
1547 transport = vsk->transport; in vsock_stream_setsockopt()
1554 vsock_update_buffer_size(vsk, transport, val); in vsock_stream_setsockopt()
1560 vsock_update_buffer_size(vsk, transport, vsk->buffer_size); in vsock_stream_setsockopt()
1566 vsock_update_buffer_size(vsk, transport, vsk->buffer_size); in vsock_stream_setsockopt()
1674 const struct vsock_transport *transport; in vsock_stream_sendmsg() local
1683 transport = vsk->transport; in vsock_stream_sendmsg()
1705 if (!transport || sk->sk_state != TCP_ESTABLISHED || in vsock_stream_sendmsg()
1719 err = transport->notify_send_init(vsk, &send_data); in vsock_stream_sendmsg()
1739 err = transport->notify_send_pre_block(vsk, &send_data); in vsock_stream_sendmsg()
1773 err = transport->notify_send_pre_enqueue(vsk, &send_data); in vsock_stream_sendmsg()
1783 written = transport->stream_enqueue( in vsock_stream_sendmsg()
1793 err = transport->notify_send_post_enqueue( in vsock_stream_sendmsg()
1815 const struct vsock_transport *transport; in vsock_stream_recvmsg() local
1826 transport = vsk->transport; in vsock_stream_recvmsg()
1831 if (!transport || sk->sk_state != TCP_ESTABLISHED) { in vsock_stream_recvmsg()
1874 if (target >= transport->stream_rcvhiwat(vsk)) { in vsock_stream_recvmsg()
1881 err = transport->notify_recv_init(vsk, target, &recv_data); in vsock_stream_recvmsg()
1906 err = transport->notify_recv_pre_block( in vsock_stream_recvmsg()
1940 err = transport->notify_recv_pre_dequeue( in vsock_stream_recvmsg()
1945 read = transport->stream_dequeue( in vsock_stream_recvmsg()
1955 err = transport->notify_recv_post_dequeue( in vsock_stream_recvmsg()
2156 return vsk->transport; in vsock_core_get_transport()