16 #include <l4/cxx/utils>
41 L4::Type_info::Demand_t<1> >
61 out_notify, in_notify, to);
72 bool fail_state()
const
74 auto cfg_status = cxx::access_once(&status);
84 out_notify, in_notify, to);
91 cxx::write_now(&cmd, command);
94 out_notify->trigger();
106 while (cxx::access_once(&cmd));
212 register_ds_t, device_config_t,
213 device_notification_irq_t>
Rpcs;
L4::Cap related definitions.
l4_cap_idx_t cap() const noexcept
Return capability selector.
C++ interface for capabilities.
Capability type for RPC interfaces (see L4::Cap<T>).
Helper class to create an L4Re interface class that is derived from a single base class.
IPC interface for virtio over L4 IPC.
long register_ds(L4::Ipc::Cap< L4Re::Dataspace > ds_cap, l4_uint64_t base, l4_umword_t offset, l4_umword_t size)
Register a shared data space with VIRTIO host.
long device_notification_irq(unsigned index, L4::Ipc::Out< L4::Cap< L4::Triggerable > > irq)
Get the notification interrupt corresponding to the given index.
long config_queue(unsigned queue)
Trigger queue configuration of the given queue.
long device_config(L4::Ipc::Out< L4::Cap< L4Re::Dataspace > > config_ds, l4_addr_t *ds_offset)
Get the dataspace with the L4virtio configuration page.
long register_iface(L4::Ipc::Cap< L4::Triggerable > guest_irq, L4::Ipc::Out< L4::Cap< L4::Triggerable > > host_irq, L4::Ipc::Out< L4::Cap< L4Re::Dataspace > > config_ds)
Register client to the L4-VIRTIO device.
long set_status(unsigned status)
Write the VIRTIO status register.
unsigned long l4_umword_t
Unsigned machine word.
unsigned long l4_addr_t
Address type.
unsigned long long l4_uint64_t
Unsigned 64bit value.
@ L4_EBUSY
Object currently busy, try later.
l4_msgtag_t l4_ipc_receive(l4_cap_idx_t object, l4_utcb_t *utcb, l4_timeout_t timeout) L4_NOTHROW
Wait for a message from a specific source.
l4_umword_t l4_ipc_error(l4_msgtag_t tag, l4_utcb_t *utcb) L4_NOTHROW
Get the error code for an object invocation.
@ L4_IPC_RETIMEOUT
Timeout during receive operation.
#define L4_IPC_TIMEOUT_0
Timeout constants.
l4_timeout_t l4_timeout(l4_timeout_s snd, l4_timeout_s rcv) L4_NOTHROW
Combine send and receive timeout in a timeout.
l4_utcb_t * l4_utcb(void) L4_NOTHROW L4_PURE
Get the UTCB address.
l4virtio_config_queue_t * l4virtio_config_queues(l4virtio_config_hdr_t const *cfg)
Get the pointer to the first queue config.
void * l4virtio_device_config(l4virtio_config_hdr_t const *cfg)
Get the pointer to the device configuration.
@ L4VIRTIO_STATUS_FAILED
Driver detected fatal error.
@ L4VIRTIO_STATUS_DEVICE_NEEDS_RESET
Device detected fatal error.
@ L4VIRTIO_CMD_SET_STATUS
Set the status register.
@ L4VIRTIO_CMD_CFG_QUEUE
Configure a queue.
#define L4_INLINE_RPC(res, name, args, attr...)
Define an inline RPC call (type and callable).
L4-VIRTIO Transport C++ API.
Mark an argument as a output value in an RPC signature.
Standard list of RPCs of an interface.
Basic timeout specification.
L4-VIRTIO config header, provided in shared data space.
Queue configuration entry.