![]()  | 
  
    L4Re Operating System Framework
    
   Interface and Usage Documentation 
   | 
 
Abstraction for a network request. More...
#include <request_l4virtio.h>
Public Member Functions | |
| Mac_addr | dst_mac () const | 
| Get the Mac address of the destination port.  | |
| Mac_addr | src_mac () const | 
| Get the Mac address of the source port.  | |
Static Public Member Functions | |
| static void | drop_requests (Virtio_net *dev, L4virtio::Svr::Virtqueue *queue) | 
| Drop all requests of a specific queue.   | |
| static std::optional< Virtio_net_request > | get_request (Virtio_net *dev, L4virtio::Svr::Virtqueue *queue) | 
| Construct a request from the next entry of a provided queue.   | |
Abstraction for a network request.
A Virtio_net_request is constructed by the source port, using the static function get_request() as part of Port_iface::get_tx_request().
On destruction, finish() will be called, which, will trigger the client IRQ of the source client.
Definition at line 35 of file request_l4virtio.h.
      
  | 
  inlinestatic | 
Drop all requests of a specific queue.
This function is used for example to drop all requests in the transmission queue of a monitor port, since monitor ports are not allowed to transmit data.
| dev | Port of the provided virtqueue. | 
| queue | Virtqueue to drop all requests of. | 
Definition at line 172 of file request_l4virtio.h.
References L4virtio::Svr::Virtqueue::desc_avail(), L4virtio::Svr::Virtqueue::finish(), L4_UNLIKELY, L4virtio::Svr::Virtqueue::next_avail(), L4virtio::Virtqueue::ready(), and L4virtio::Svr::Request_processor::start().
Referenced by L4virtio_port::drop_requests().
      
  | 
  inlinestatic | 
Construct a request from the next entry of a provided queue.
| dev | Port of the provided virtqueue. | 
| queue | Virtqueue to extract next entry from. | 
Definition at line 199 of file request_l4virtio.h.
References L4_UNLIKELY, L4virtio::Svr::Virtqueue::next_avail(), and L4virtio::Virtqueue::ready().
Referenced by L4virtio_port::get_tx_request().