API definition for VLink. More...
#include <Padico/Puk.h>#include <Padico/PadicoTM.h>#include <Padico/Topology.h>#include <Padico/NetSelector.h>#include <Padico/SysIO.h>#include <sys/types.h>#include <sys/socket.h>#include <sys/stat.h>#include <fcntl.h>#include <unistd.h>#include <poll.h>

Go to the source code of this file.
Data Structures | |
| struct | padico_vlink_driver_s |
| Driver for interface: "VLink". More... | |
| struct | puk_receptacle_VLink_s |
| struct | padico_vlink_messaging_driver_s |
| Driver for interface: 'VLinkMessaging' (connection-less messaging) More... | |
| struct | puk_receptacle_VLinkMessaging_s |
| struct | padico_vpipe_driver_s |
| Driver for interface: 'VPipe'. More... | |
| struct | puk_receptacle_VPipe_s |
| struct | padico_vfile_driver_s |
| Driver for interface: 'VFile'. More... | |
| struct | puk_receptacle_VFile_s |
| struct | vobs_attr_status_s |
| status description for generic I/O More... | |
| struct | vobs_attr_socket_s |
| status description specialized for virtual sockets (vsocks). More... | |
| struct | vobs_attr_binding_s |
| a (local) binding for a socket More... | |
| struct | vobs_attr_listener_s |
| a listener for a socket More... | |
| struct | vobs_attr_remote_s |
| the peer of a connected socket More... | |
| struct | vobs_attr_rbox_s |
| an incoming (read) mailbox More... | |
| struct | vobs_attr_wbox_s |
| an outgoing (write) mailbox More... | |
| struct | vobs_attr_pivot_s |
| a pivot request More... | |
| struct | vobs_secondary_ref_s |
| A reference to a secondary observer watching us (us, the vnode) More... | |
| struct | vobs_attr_observer_s |
| An observer record inside a vnode. More... | |
| struct | vobs_attr_observer_s::vobs_notify_s |
| struct | padico_vnode_observer_s |
| A single vnode R/W observer. More... | |
| struct | vobs_secondary_s |
| A secondary vnode R/W observer, for a group of vnodes. More... | |
| struct | vnode_hfd_s |
| virtual node descriptor specialized for real (kernel) file descriptors. More... | |
| struct | padico_vnode_content_t |
| struct | vnode_assembly_stuff_s |
| struct | padico_vnode_s |
| virtual node descriptor, common to any file type More... | |
Macros | |
| #define | VNODE_EVENT_READ 0x01 |
| #define | VNODE_EVENT_WRITE 0x02 |
| #define | VNODE_EVENT_ERROR 0x04 |
Typedefs | |
| typedef struct padico_vnode_s * | padico_vnode_t |
| typedef struct vlink_assembly_request_s * | vlink_assembly_request_t |
| typedef struct padico_vlink_messaging_driver_s * | padico_vlink_messaging_driver_t |
| typedef void(* | vobs_notifier_func_t) (padico_vnode_t vnode, vobs_attr_t attr, void *key) |
| type of handler function for notifying changes in observed attributes (bottom-up) | |
| typedef void(* | vobs_commit_func_t) (padico_vnode_t vnode, vobs_attr_t attr) |
| type of handler function for committing direct changed attributes (top-down) | |
| typedef struct vobs_secondary_s * | vobs_secondary_t |
Enumerations | |
| enum | vobs_attr_t { vobs_attr_status = 0 , vobs_attr_socket , vobs_attr_remote , vobs_attr_listener , vobs_attr_rbox , vobs_attr_wbox , vobs_attr_pivot , VOBS_ATTR_MAX } |
| enumerates common attributes in vnodes More... | |
| enum | padico_vsock_capabilities_e { padico_vsock_caps_directconnect = 0x01 , padico_vsock_caps_secondaryonly = 0x02 , padico_vsock_caps_clientonly = 0x04 , padico_vsock_caps_serveronly = 0x08 , padico_vsock_caps_clientmustbind = 0x10 , padico_vsock_caps_afpadicoonly = 0x20 } |
| Capabilities of VLink socket drivers. More... | |
Variables | |
| padico_vnode | |
| typdef struct vobs_secondary_ref_vect_s * | vobs_secondary_ref_vect_t |
Detailed Description
API definition for VLink.
Definition in file VLink-API.h.
Macro Definition Documentation
◆ VNODE_EVENT_ERROR
| #define VNODE_EVENT_ERROR 0x04 |
Definition at line 330 of file VLink-API.h.
◆ VNODE_EVENT_READ
| #define VNODE_EVENT_READ 0x01 |
Definition at line 328 of file VLink-API.h.
◆ VNODE_EVENT_WRITE
| #define VNODE_EVENT_WRITE 0x02 |
Definition at line 329 of file VLink-API.h.
Typedef Documentation
◆ padico_vlink_messaging_driver_t
Definition at line 88 of file VLink-API.h.
◆ padico_vnode_t
Definition at line 50 of file VLink-API.h.
◆ vlink_assembly_request_t
Definition at line 51 of file VLink-API.h.
◆ vobs_commit_func_t
| typedef void(* vobs_commit_func_t) (padico_vnode_t vnode, vobs_attr_t attr) |
type of handler function for committing direct changed attributes (top-down)
Definition at line 280 of file VLink-API.h.
◆ vobs_notifier_func_t
| typedef void(* vobs_notifier_func_t) (padico_vnode_t vnode, vobs_attr_t attr, void *key) |
type of handler function for notifying changes in observed attributes (bottom-up)
Definition at line 275 of file VLink-API.h.
◆ vobs_secondary_t
Definition at line 343 of file VLink-API.h.
Enumeration Type Documentation
◆ padico_vsock_capabilities_e
Capabilities of VLink socket drivers.
These attributes are supposed to be put into vnode->socket.capabilities by the driver in the 'create()' phase. They are read by VLink_selector.
- Note
- default capabilities (if none given): driver is able to direct-connect and be used as secondary (secondary is preferred is possible), driver is able to be used as client and server, client is not required to bind before connecting.
- Warning
- some attributes are mutually exclusive: directconnect and secondaryonly clientonly and serveronly directconnect and afpadicoonly afpadicoonly implies secondaryonly.
Definition at line 176 of file VLink-API.h.
◆ vobs_attr_t
enumerates common attributes in vnodes
| Enumerator | |
|---|---|
| vobs_attr_status | |
| vobs_attr_socket | |
| vobs_attr_remote | |
| vobs_attr_listener | |
| vobs_attr_rbox | |
| vobs_attr_wbox | |
| vobs_attr_pivot | |
| VOBS_ATTR_MAX | |
Definition at line 137 of file VLink-API.h.
Function Documentation
◆ padico_vio_dumpvnode()
| padico_rc_t padico_vio_dumpvnode | ( | padico_vnode_t | vnode | ) |
Definition at line 128 of file vio-stat.c.
References vobs_attr_listener_s::backlog, vobs_attr_listener_s::backlog_size, padico_vnode_content_t::binding, padico_vnode_s::binding, vobs_attr_remote_s::can_recv, vobs_attr_remote_s::can_send, padico_vnode_s::content, done, driver, vobs_attr_remote_s::established, vnode_hfd_s::fd, padico_vnode_content_t::hfd, padico_vnode_s::hfd, vnode_hfd_s::io_read, vnode_hfd_s::io_write, vobs_attr_wbox_s::is_owner, padico_vnode_content_t::listener, padico_vnode_s::listener, vobs_attr_status_s::opened, padico_vnode_component_name(), padico_vnode_get_vlink_driver(), vobs_attr_binding_s::primary, vobs_attr_binding_s::primary_len, padico_vnode_content_t::rbox, padico_vnode_s::rbox, rc, vobs_attr_rbox_s::read_buffer, vobs_attr_rbox_s::read_done, vobs_attr_rbox_s::read_posted, vobs_attr_status_s::readable, padico_vnode_content_t::remote, padico_vnode_s::remote, vobs_attr_remote_s::remote_addr, vobs_attr_remote_s::remote_addrlen, vobs_attr_socket_s::so_family, vobs_attr_socket_s::so_options, vobs_attr_socket_s::so_protocol, vobs_attr_socket_s::so_type, padico_vnode_content_t::socket, padico_vnode_s::socket, padico_vnode_s::status, vio_rc_sockaddr(), vnode, padico_vnode_content_t::wbox, padico_vnode_s::wbox, vobs_attr_status_s::writable, vobs_attr_wbox_s::write_buffer, vobs_attr_wbox_s::write_done, and vobs_attr_wbox_s::write_posted.
Referenced by padico_vio_dump_vfd(), and padico_vio_getsockname().
◆ padico_vnode_close()
| int padico_vnode_close | ( | padico_vnode_t | vnode | ) |
Definition at line 298 of file vnode.c.
References vobs_attr_listener_s::backlog, vobs_attr_listener_s::backlog_size, padico_vnode_s::content, done, driver, padico_vnode_content_t::hfd, padico_vnode_content_t::listener, padico_vnode_s::listener, padico_vnode_get_vlink_driver(), padico_vsock_fullshutdown(), rc, padico_vnode_content_t::remote, padico_vnode_content_t::socket, vnode, and vnode_hfd_close().
Referenced by padico_vio_close(), and padico_vio_open().
◆ padico_vnode_read_clear()
| void padico_vnode_read_clear | ( | padico_vnode_t | vnode | ) |
Definition at line 234 of file vnode.c.
References padico_vnode_s::content, NULL, padico_vnode_content_t::rbox, padico_vnode_s::rbox, vobs_attr_rbox_s::read_buffer, vobs_attr_rbox_s::read_done, vobs_attr_rbox_s::read_posted, vnode, vnode_check, vobs_attr_rbox, and vobs_commit().
Referenced by comm_thread(), padico_vio_read(), and vpf_notifier().
◆ padico_vnode_read_post()
| ssize_t padico_vnode_read_post | ( | padico_vnode_t | vnode, |
| void * | buf, | ||
| size_t | count | ||
| ) |
Definition at line 173 of file vnode.c.
References assert(), vobs_attr_rbox_s::cant_interrupt_read, padico_vnode_s::content, done, driver, NULL, vlink_statistics_s::num_read, padico_vnode_get_vlink_driver(), padico_vnode_content_t::rbox, padico_vnode_s::rbox, rc, vobs_attr_rbox_s::read_buffer, vobs_attr_rbox_s::read_done, vobs_attr_rbox_s::read_posted, vobs_attr_rbox_s::tid, vlink_stat, vnode, vnode_activate, vnode_clear_error(), and vnode_set_error().
Referenced by comm_thread(), padico_vio_read(), vlink_fwd_recv_post(), vlink_id_recv_post(), vpf_notifier(), and vpf_recv_post().
◆ padico_vnode_write_clear()
| void padico_vnode_write_clear | ( | padico_vnode_t | vnode | ) |
Definition at line 285 of file vnode.c.
References padico_vnode_s::content, done, vobs_attr_wbox_s::is_owner, NULL, vnode, vnode_check, vobs_attr_wbox, vobs_commit(), padico_vnode_content_t::wbox, padico_vnode_s::wbox, vobs_attr_wbox_s::write_buffer, and vobs_attr_wbox_s::write_posted.
Referenced by padico_vio_write(), and vpf_notifier().
◆ padico_vnode_write_post()
| ssize_t padico_vnode_write_post | ( | padico_vnode_t | vnode, |
| const void * | buf, | ||
| size_t | count | ||
| ) |
Definition at line 245 of file vnode.c.
References padico_vnode_s::content, done, driver, vobs_attr_remote_s::established, vobs_attr_wbox_s::is_owner, vlink_statistics_s::num_write, padico_vnode_get_vlink_driver(), rc, padico_vnode_content_t::remote, padico_vnode_s::remote, vlink_stat, vnode, vnode_activate, vnode_clear_error(), vnode_set_error(), padico_vnode_content_t::wbox, padico_vnode_s::wbox, vobs_attr_wbox_s::write_buffer, vobs_attr_wbox_s::write_done, and vobs_attr_wbox_s::write_posted.
Referenced by comm_thread(), padico_vio_write(), vlink_fwd_send_post(), vlink_id_send_post(), vpf_notifier(), and vpf_send_post().
◆ padico_vsock_active_connect()
| int padico_vsock_active_connect | ( | padico_vnode_t | vnode, |
| const struct sockaddr * | name, | ||
| socklen_t | namelen | ||
| ) |
- Returns
- 0 if success (connected)
- -1 if error (maybe in progress)
Definition at line 205 of file vsock.c.
References vobs_attr_remote_s::can_recv, vobs_attr_remote_s::can_send, padico_vlink_driver_s::connect, vobs_attr_status_s::connecting, done, driver, vobs_attr_remote_s::established, name, namelen, padico_vnode_component_name(), padico_vnode_get_vlink_driver(), rc, padico_vnode_s::remote, vobs_attr_remote_s::remote_addr, vobs_attr_remote_s::remote_addrlen, padico_vnode_s::status, vlink_address_trace, vlink_is_transient_error(), vnode, vnode_activate, vnode_check, vnode_deactivate, and vnode_get_error().
Referenced by padico_vio_connect(), vlink_fwd_connect_handler(), vlink_fwd_gwlisten_handler(), vlink_fwd_listen_handler(), vlink_id_connect(), vlink_selector_connect(), and vpf_connect().
◆ padico_vsock_autobind()
| int padico_vsock_autobind | ( | padico_vnode_t | vnode | ) |
Definition at line 103 of file vsock.c.
References NULL, padico_vsock_bind(), rc, and vnode.
Referenced by padico_vsock_passive_connect(), vlink_fwd_bind(), vlink_fwd_connect_handler(), vlink_id_bind(), vlink_selector_connect(), vlink_selector_create_server(), and vpf_bind().
◆ padico_vsock_bind()
Definition at line 111 of file vsock.c.
References vobs_attr_binding_s::autobind, padico_vnode_s::binding, done, driver, NULL, padico_vnode_component_name(), padico_vnode_get_vlink_driver(), vobs_attr_binding_s::primary, vobs_attr_binding_s::primary_len, rc, vlink_address_trace, vnode, vnode_activate, and vnode_check.
Referenced by padico_vio_bind(), padico_vsock_autobind(), and vlink_selector_bind().
◆ padico_vsock_create()
| int padico_vsock_create | ( | padico_vnode_t | vnode, |
| int | domain, | ||
| int | type, | ||
| int | protocol | ||
| ) |
Turns a vnode into a socket.
- Returns
- -errno (0 if success)
Definition at line 58 of file vsock.c.
References domain, done, driver, padico_vnode_component_name(), padico_vnode_get_vlink_driver(), padico_vsock_init(), rc, type, and vnode.
Referenced by padico_vio_socket(), vlink_fwd_bind(), vlink_fwd_connect(), vlink_fwd_connect_handler(), vlink_fwd_listen_handler(), vlink_id_create(), vlink_selector_connect(), vlink_selector_create(), vlink_selector_create_server(), vpf_create(), and vsock_vopw_listen().
◆ padico_vsock_fullshutdown()
| void padico_vsock_fullshutdown | ( | padico_vnode_t | vnode | ) |
Definition at line 77 of file vsock.c.
References vobs_attr_remote_s::can_recv, vobs_attr_remote_s::can_send, padico_vnode_s::content, done, driver, vobs_attr_status_s::end_of_file, vobs_attr_remote_s::established, padico_vnode_component_name(), padico_vnode_get_vlink_driver(), padico_vnode_content_t::remote, padico_vnode_s::remote, padico_vnode_s::status, and vnode.
Referenced by padico_vio_shutdown(), padico_vnode_close(), vio_pivot_vnode(), vlink_fwd_fullshutdown(), vlink_id_fullshutdown(), vlink_selector_fullshutdown(), and vpf_fullshutdown().
◆ padico_vsock_init()
| void padico_vsock_init | ( | padico_vnode_t | vnode, |
| int | domain, | ||
| int | type, | ||
| int | protocol | ||
| ) |
Definition at line 44 of file vsock.c.
References vobs_attr_socket_s::capabilities, domain, vlink_statistics_s::open_sockets, vobs_attr_socket_s::so_family, vobs_attr_socket_s::so_options, vobs_attr_socket_s::so_protocol, vobs_attr_socket_s::so_type, padico_vnode_s::socket, type, vlink_stat, vnode, and vnode_activate.
Referenced by padico_vsock_create(), vlink_fwd_gw_notifier(), vlink_fwd_notifier(), vlink_id_make_new_vnode(), vlink_ps_callback_acceptor(), vlink_sf_accept_finalizer(), and vpf_make_new_vnode().
◆ padico_vsock_passive_connect()
| int padico_vsock_passive_connect | ( | padico_vnode_t | vnode, |
| int | backlog_size, | ||
| const struct padico_vaddr_s * | src_addr | ||
| ) |
- Precondition
- vnode locked
Definition at line 156 of file vsock.c.
References vobs_attr_listener_s::backlog, vobs_attr_listener_s::backlog_size, padico_vnode_content_t::binding, padico_vnode_s::binding, padico_vnode_s::content, done, driver, listener, padico_vnode_s::listener, padico_vnode_component_name(), padico_vnode_get_vlink_driver(), padico_vsock_autobind(), vobs_attr_binding_s::primary, vobs_attr_binding_s::primary_len, rc, padico_vnode_content_t::socket, vobs_attr_listener_s::src_addr, vlink_address_trace, vnode, vnode_activate, vnode_clear_error(), and vnode_set_error().
Referenced by padico_vio_listen(), vlink_fwd_connect_handler(), vlink_fwd_listen(), vlink_id_listen(), vlink_selector_create_server(), vlink_selector_listen(), and vpf_listen().
◆ padico_vsock_recvfrom()
| ssize_t padico_vsock_recvfrom | ( | padico_vnode_t | vnode, |
| void * | buf, | ||
| size_t | len, | ||
| int | flags, | ||
| struct sockaddr * | from, | ||
| int * | fromlen | ||
| ) |
Definition at line 332 of file vsock.c.
References vobs_attr_rbox_s::cant_interrupt_read, padico_vnode_s::content, done, vobs_attr_rbox_s::from, vobs_attr_rbox_s::fromlen, len, NULL, padico_vnode_content_t::rbox, padico_vnode_s::rbox, rc, vobs_attr_rbox_s::read_buffer, vobs_attr_rbox_s::read_done, vobs_attr_rbox_s::read_posted, vnode, vnode_activate, vnode_set_error(), vobs_wait(), and vsock_madio_recvfrom().
◆ padico_vsock_sendto()
| ssize_t padico_vsock_sendto | ( | padico_vnode_t | vnode, |
| const void * | buf, | ||
| size_t | len, | ||
| int | flags, | ||
| const struct sockaddr * | to, | ||
| int | tolen | ||
| ) |
Definition at line 295 of file vsock.c.
References __puk_abi_wrap__errno, padico_vnode_s::content, done, vnode_hfd_s::fd, padico_vnode_s::hfd, len, NULL, padico_topo_host_getbyinaddr(), padico_topo_host_getnode(), PUK_ABI_FSYS_WRAP, rc, remote_node, vnode, vnode_set_error(), vsock_madio_sendto(), and padico_vnode_content_t::wbox.
Referenced by padico_vio_sendto().
◆ puk_component_get_driver_VFile()
|
inlinestatic |
Definition at line 111 of file VLink-API.h.
◆ puk_component_get_driver_VLink()
|
inlinestatic |
Definition at line 79 of file VLink-API.h.
Referenced by vnode_instantiate().
◆ puk_component_get_driver_VLinkMessaging()
|
inlinestatic |
Definition at line 89 of file VLink-API.h.
◆ puk_component_get_driver_VPipe()
|
inlinestatic |
Definition at line 97 of file VLink-API.h.
Referenced by padico_vio_pipe().
◆ puk_component_get_facet_VFile()
|
inlinestatic |
Definition at line 111 of file VLink-API.h.
◆ puk_component_get_facet_VLink()
|
inlinestatic |
Definition at line 79 of file VLink-API.h.
◆ puk_component_get_facet_VLinkMessaging()
|
inlinestatic |
Definition at line 89 of file VLink-API.h.
◆ puk_component_get_facet_VPipe()
|
inlinestatic |
Definition at line 97 of file VLink-API.h.
◆ puk_component_indirect_VFile()
|
inlinestatic |
Definition at line 111 of file VLink-API.h.
◆ puk_component_indirect_VLink()
|
inlinestatic |
Definition at line 79 of file VLink-API.h.
◆ puk_component_indirect_VLinkMessaging()
|
inlinestatic |
Definition at line 89 of file VLink-API.h.
◆ puk_component_indirect_VPipe()
|
inlinestatic |
Definition at line 97 of file VLink-API.h.
◆ puk_context_indirect_VFile()
|
inlinestatic |
Definition at line 111 of file VLink-API.h.
◆ puk_context_indirect_VLink()
|
inlinestatic |
Definition at line 79 of file VLink-API.h.
◆ puk_context_indirect_VLinkMessaging()
|
inlinestatic |
Definition at line 89 of file VLink-API.h.
◆ puk_context_indirect_VPipe()
|
inlinestatic |
Definition at line 97 of file VLink-API.h.
◆ puk_iface_VFile()
|
inlinestatic |
Definition at line 111 of file VLink-API.h.
◆ puk_iface_VLink()
|
inlinestatic |
Definition at line 79 of file VLink-API.h.
Referenced by gw_status_new(), ns_inet_default_selector_host(), vlink_fwd_connect_handler(), vlink_fwd_init(), vlink_fwd_listen_handler(), vlink_selector_connect(), and vlink_selector_create().
◆ puk_iface_VLinkMessaging()
|
inlinestatic |
Definition at line 89 of file VLink-API.h.
◆ puk_iface_VPipe()
|
inlinestatic |
Definition at line 97 of file VLink-API.h.
◆ puk_instance_context_indirect_VFile()
|
inlinestatic |
Definition at line 111 of file VLink-API.h.
◆ puk_instance_context_indirect_VLink()
|
inlinestatic |
Definition at line 79 of file VLink-API.h.
Referenced by vlink_id_init(), and vpf_init().
◆ puk_instance_context_indirect_VLinkMessaging()
|
inlinestatic |
Definition at line 89 of file VLink-API.h.
◆ puk_instance_context_indirect_VPipe()
|
inlinestatic |
Definition at line 97 of file VLink-API.h.
◆ puk_instance_indirect_VFile()
|
inlinestatic |
Definition at line 111 of file VLink-API.h.
Referenced by padico_vio_fstat(), padico_vio_fsync(), padico_vio_ftruncate(), padico_vio_lseek(), padico_vio_mmap(), and padico_vio_open().
◆ puk_instance_indirect_VLink()
|
inlinestatic |
Definition at line 79 of file VLink-API.h.
Referenced by padico_vio_inotify_init(), padico_vio_socket(), padico_vnode_instantiate_entry(), vlink_selector_connect(), vlink_selector_create(), vlink_selector_create_server(), and vpipe_pipe().
◆ puk_instance_indirect_VLinkMessaging()
|
inlinestatic |
Definition at line 89 of file VLink-API.h.
◆ puk_instance_indirect_VPipe()
|
inlinestatic |
Definition at line 97 of file VLink-API.h.
◆ puk_receptacle_VFile_null()
|
inlinestatic |
Definition at line 111 of file VLink-API.h.
◆ puk_receptacle_VLink_null()
|
inlinestatic |
Definition at line 79 of file VLink-API.h.
◆ puk_receptacle_VLinkMessaging_null()
|
inlinestatic |
Definition at line 89 of file VLink-API.h.
◆ puk_receptacle_VPipe_null()
|
inlinestatic |
Definition at line 97 of file VLink-API.h.
◆ vlink_is_transient_error()
Definition at line 567 of file VLink-API.h.
References done.
Referenced by padico_vsock_active_connect(), vnode_is_fatal_error(), and vnode_is_transient_error().
◆ vnode_clear_error()
|
inlinestatic |
Definition at line 582 of file VLink-API.h.
References vnode, and vnode_set_error().
Referenced by padico_vio_getsockopt(), padico_vnode_read_post(), padico_vnode_write_post(), and padico_vsock_passive_connect().
◆ vnode_condwait()
|
inlinestatic |
Definition at line 439 of file VLink-API.h.
References cond, done, padico_vnode_s::lock_ptr, NULL, and vnode.
Referenced by vobs_wait().
◆ vnode_get_error()
|
inlinestatic |
Definition at line 578 of file VLink-API.h.
References vobs_attr_status_s::error, padico_vnode_s::status, and vnode.
Referenced by padico_vio_bind(), padico_vio_connect(), padico_vio_fcntl(), padico_vio_fstat(), padico_vio_ftruncate(), padico_vio_getsockopt(), padico_vio_listen(), padico_vio_lseek(), padico_vio_mmap(), padico_vio_write(), padico_vsock_active_connect(), vnode_hfd_callback_reader(), vnode_hfd_callback_writer(), vnode_is_fatal_error(), vnode_is_transient_error(), and vsock_vopw_connect().
◆ vnode_is_fatal_error()
|
inlinestatic |
Definition at line 586 of file VLink-API.h.
References done, vlink_is_transient_error(), vnode, and vnode_get_error().
Referenced by fdsets_from_vobs_secondary(), and vobs_secondary_update().
◆ vnode_is_transient_error()
|
inlinestatic |
Definition at line 591 of file VLink-API.h.
References done, vlink_is_transient_error(), vnode, and vnode_get_error().
◆ vnode_lock()
|
inlinestatic |
Definition at line 407 of file VLink-API.h.
References assert(), done, padico_vnode_s::lock_ptr, and vnode.
Referenced by padico_vio_accept(), padico_vio_bind(), padico_vio_close(), padico_vio_connect(), padico_vio_fcntl(), padico_vio_fstat(), padico_vio_fsync(), padico_vio_ftruncate(), padico_vio_getpeername(), padico_vio_getsockname(), padico_vio_inotify_add_watch(), padico_vio_inotify_rm_watch(), padico_vio_interrupt(), padico_vio_listen(), padico_vio_lseek(), padico_vio_mmap(), padico_vio_read(), padico_vio_sendto(), padico_vio_shutdown(), padico_vio_write(), padico_vsock_acceptor_finalize(), vio_init_vnode(), vio_pivot_vnode(), vlink_fwd_gw_notifier(), vlink_fwd_notifier(), vlink_ps_callback_acceptor(), vlink_selector_close(), vlink_selector_connect(), vlink_selector_create_server(), vlink_selector_fullshutdown(), vlink_selector_server_notifier(), vlink_sf_accept_finalizer(), vlink_sf_connect_finalizer(), vlink_sf_fullshutdown(), vnode_hfd_callback_reader(), vnode_hfd_callback_writer(), vnode_hfd_read_post(), vnode_hfd_write_post(), vobs_secondary_destroy(), vobs_secondary_from_fdsets(), vobs_secondary_from_pollfd(), vobs_signal(), vopw_acceptor(), vopw_control_event_listener(), vopw_deferred_req_worker(), vopw_lock_acquire(), vopw_psp_handler(), vpipe_close(), vpipe_write(), vsock_madio_sendto(), and vsock_vopw_listen().
◆ vnode_set_error()
|
inlinestatic |
Definition at line 574 of file VLink-API.h.
References done, vobs_attr_status_s::error, padico_vnode_s::status, and vnode.
Referenced by padico_vnode_read_post(), padico_vnode_write_post(), padico_vsock_acceptor_finalize(), padico_vsock_connector_finalize(), padico_vsock_passive_connect(), padico_vsock_recvfrom(), padico_vsock_sendto(), vfile_fstat(), vfile_fsync(), vfile_ftruncate(), vfile_lseek(), vfile_mmap(), vlink_fwd_gw_notifier(), vlink_fwd_notifier(), vlink_ps_bind(), vlink_ps_callback_acceptor(), vlink_ps_connect(), vlink_selector_connect(), vlink_sf_accept_finalizer(), vlink_sf_bind(), vlink_sf_connect(), vlink_sf_create(), vlink_sf_fullshutdown(), vlink_sf_listen(), vlink_sysio_reader_worker(), vlink_sysio_writer_worker(), vnode_clear_error(), vnode_hfd_fcntl(), vopw_control_event_listener(), vopw_data_check(), vopw_data_send(), vopw_psp_callback_CONNREFUSED(), vpf_recv_post(), vpf_send_post(), vpipe_pipe(), vpipe_write(), vsock_vopw_bind(), vsock_vopw_connect(), and vsock_vopw_listen().
◆ vnode_trylock()
|
inlinestatic |
Definition at line 426 of file VLink-API.h.
References assert(), done, padico_vnode_s::lock_ptr, and vnode.
◆ vnode_unlock()
|
inlinestatic |
Definition at line 416 of file VLink-API.h.
References assert(), done, padico_vnode_s::lock_ptr, NULL, and vnode.
Referenced by padico_vio_accept(), padico_vio_bind(), padico_vio_connect(), padico_vio_fcntl(), padico_vio_fstat(), padico_vio_fsync(), padico_vio_ftruncate(), padico_vio_getpeername(), padico_vio_getsockname(), padico_vio_inotify_add_watch(), padico_vio_inotify_rm_watch(), padico_vio_interrupt(), padico_vio_listen(), padico_vio_lseek(), padico_vio_mmap(), padico_vio_read(), padico_vio_sendto(), padico_vio_shutdown(), padico_vio_write(), padico_vsock_acceptor_finalize(), vio_init_vnode(), vio_pivot_vnode(), vlink_fwd_gw_notifier(), vlink_fwd_notifier(), vlink_ps_callback_acceptor(), vlink_selector_close(), vlink_selector_connect(), vlink_selector_create_server(), vlink_selector_fullshutdown(), vlink_selector_server_notifier(), vlink_sf_accept_finalizer(), vlink_sf_connect_finalizer(), vlink_sf_fullshutdown(), vnode_hfd_callback_reader(), vnode_hfd_callback_writer(), vnode_hfd_close(), vnode_hfd_read_post(), vnode_hfd_write_post(), vobs_secondary_destroy(), vobs_secondary_from_fdsets(), vobs_secondary_from_pollfd(), vobs_signal(), vopw_acceptor(), vopw_control_event_listener(), vopw_deferred_req_worker(), vopw_lock_acquire(), vopw_psp_handler(), vpipe_close(), vpipe_write(), vsock_madio_sendto(), and vsock_vopw_listen().
◆ vobs_commit()
|
inlinestatic |
Definition at line 533 of file VLink-API.h.
References vobs_attr_observer_s::commit, done, NULL, padico_vnode_s::observer, and vnode.
Referenced by padico_vio_setsockopt(), padico_vnode_read_clear(), padico_vnode_write_clear(), vlink_fwd_commit(), vlink_id_commit(), and vpf_commit().
◆ vobs_secondary_destroy()
| void vobs_secondary_destroy | ( | struct vobs_secondary_s * | obs | ) |
Referenced by padico_vio_poll(), and padico_vio_select().
◆ vobs_secondary_init()
| void vobs_secondary_init | ( | vobs_secondary_t | obs, |
| int | size | ||
| ) |
Definition at line 89 of file vobs.c.
References assert(), done, vobs_secondary_s::lock, vobs_secondary_s::n_obs, NULL, vobs_secondary_s::observers, size, and vobs_secondary_s::waiting.
Referenced by padico_vio_poll(), and padico_vio_select().
◆ vobs_secondary_lock()
|
inlinestatic |
Definition at line 460 of file VLink-API.h.
References done, and vobs_secondary_s::lock.
Referenced by padico_vio_poll(), padico_vio_select(), and vobs_secondary_destroy().
◆ vobs_secondary_timedwait()
| int vobs_secondary_timedwait | ( | vobs_secondary_t | obs, |
| const struct timespec * | timeout | ||
| ) |
Definition at line 80 of file vobs.c.
References done, vobs_secondary_s::lock, rc, timeout, and vobs_secondary_s::waiting.
Referenced by padico_vio_poll(), and padico_vio_select().
◆ vobs_secondary_unlock()
|
inlinestatic |
Definition at line 464 of file VLink-API.h.
References done, and vobs_secondary_s::lock.
Referenced by padico_vio_poll(), padico_vio_select(), and vobs_secondary_destroy().
◆ vobs_secondary_update()
| int vobs_secondary_update | ( | vobs_secondary_t | obs | ) |
Definition at line 123 of file vobs.c.
References done, padico_vnode_observer_s::event, i, vobs_secondary_s::n_obs, vobs_secondary_s::observers, ready, padico_vnode_observer_s::revent, padico_vnode_observer_s::vnode, vnode, VNODE_EVENT_ERROR, VNODE_EVENT_READ, VNODE_EVENT_WRITE, vnode_is_fatal_error(), vnode_read_poll(), and vnode_write_poll().
Referenced by padico_vio_poll(), and padico_vio_select().
◆ vobs_secondary_wait()
| void vobs_secondary_wait | ( | vobs_secondary_t | obs | ) |
Definition at line 73 of file vobs.c.
References done, vobs_secondary_s::lock, and vobs_secondary_s::waiting.
Referenced by padico_vio_poll(), and padico_vio_select().
◆ vobs_set_commit()
|
inlinestatic |
Definition at line 527 of file VLink-API.h.
References assert(), vobs_attr_observer_s::commit, NULL, padico_vnode_s::observer, and vnode.
Referenced by vlink_fwd_init(), vlink_id_init(), and vpf_init().
◆ vobs_signal()
|
inlinestatic |
signal an event to the observer.
We assume we hold the lock on vnode, but the notifier runs with mutex unlocked to prevent deadlocks when multiple locks are involved.
Definition at line 475 of file VLink-API.h.
References assert(), done, vobs_attr_observer_s::vobs_notify_s::func, vobs_attr_observer_s::notifier, notify, NULL, padico_vnode_s::observer, s, vobs_attr_observer_s::secondary, vnode, vnode_lock(), vnode_unlock(), and vobs_attr_observer_s::wait_event.
Referenced by padico_vsock_acceptor_finalize(), padico_vsock_connector_finalize(), vlink_fwd_notifier(), vlink_id_notifier(), vlink_ps_reader_worker(), vlink_ps_send_post(), vlink_selector_connect(), vlink_selector_server_notifier(), vlink_sysio_reader_worker(), vlink_sysio_writer_worker(), vnode_hfd_callback_reader(), vnode_hfd_callback_writer(), vopw_data_process(), vopw_data_send(), vopw_deferred_req_worker(), vopw_psp_callback_CONNREFUSED(), vopw_psp_callback_OKTOSEND(), vopw_psp_callback_PACKET(), vopw_psp_callback_RENDEZVOUS(), vpf_notifier(), vpf_recv_post(), vpipe_write(), vsock_madio_sendto(), vsock_vopw_recv_post(), and vsock_vopw_send_post().
◆ vobs_subscribe()
|
inlinestatic |
Definition at line 515 of file VLink-API.h.
References assert(), vobs_attr_observer_s::vobs_notify_s::func, key, vobs_attr_observer_s::vobs_notify_s::key, vobs_attr_observer_s::notifier, NULL, padico_vnode_s::observer, and vnode.
Referenced by gw_status_new(), vlink_fwd_connect_handler(), vlink_fwd_gw_notifier(), vlink_fwd_init(), vlink_fwd_listen_handler(), vlink_fwd_notifier(), vlink_id_init(), vlink_selector_connect(), vlink_selector_create_server(), vlink_selector_listen(), and vpf_init().
◆ vobs_unsubscribe()
|
inlinestatic |
Definition at line 522 of file VLink-API.h.
References vobs_attr_observer_s::vobs_notify_s::func, vobs_attr_observer_s::notifier, NULL, padico_vnode_s::observer, and vnode.
Referenced by vlink_selector_client_notifier(), and vlink_selector_fullshutdown().
◆ vobs_wait()
|
inlinestatic |
Definition at line 506 of file VLink-API.h.
References assert(), done, padico_vnode_s::observer, vnode, vnode_condwait(), and vobs_attr_observer_s::wait_event.
Referenced by padico_vio_accept(), padico_vio_close(), padico_vio_connect(), padico_vio_read(), padico_vio_write(), padico_vsock_recvfrom(), vlink_sf_accept_finalizer(), and vnode_hfd_read_post().
Variable Documentation
◆ padico_vnode
| padico_vnode |
Definition at line 217 of file VLink-API.h.
Referenced by vlink_selector_connect().
◆ vobs_secondary_ref_vect_t
| typdef struct vobs_secondary_ref_vect_s* vobs_secondary_ref_vect_t |
Definition at line 289 of file VLink-API.h.